Detatched Dialog how to interact

I am like a bad smell wont go away
Now I am trying to get something intelligent from a Detached Dialog

I see a sample code fragment Scripting > Example Scripts > Script Dialog Example in VB (Soooo passe OMG!) which relies on msg.control to interact. I cannot get anything presently from my mock up see below.
First I tried using Dlg.Control which I have successfully used in a simple dialog setup see related post. This does not work for me.
Upon reading the instructions (I know I know. Desperate times) for the Msg property
I then added various .Msg methods see also below. Nothing.
What am I doing wrong?

function OnClick(clickData) 
{
    DOpus.ClearOutput;
	DOpus.Output("001000 Start");
//  001000
//  001000 Start
//  001000
//
	var Dlg = DOpus.Dlg;
    Dlg.window = clickData.func.sourcetab;
    Dlg.template = "Dialog_1";
    Dlg.detach = true;
    Dlg.Show();
//  002000
//  002000 Msg Loop
//  002000
	DOpus.Output("002000 Msg Loop");
    while (true) {
        var Msg = Dlg.GetMsg();
        if (!Msg.result) break;
        DOpus.Output("   000   Combo_Box_Alpha1 index     =  "& Dlg.Control("Combo_Box_Alpha1").value);
		//
        DOpus.Output("   010 Msg Event =                  = " + Msg.event);
        DOpus.Output("   020   Msg.Control                = " & Msg.Control);
        DOpus.Output("   030   Msg.Dialog                = " & Msg.Dialog);
        DOpus.Output("   040   Msg.Index                = " & Msg.Index);
    }
//  002000
//  002000 Exit Loop
//  002000
	DOpus.Output("002000 Exit Loop");
    DOpus.Output("   010 Return code                  = " + Dlg.result);
	DOpus.Output("   020   Combo_Box_Alpha1 index     = " & Dlg.Control("Combo_Box_Alpha1").value);
    DOpus.Output("009000 End");
}

<resources>
	<resource name="Dialog_1" type="dialog">
		<dialog fontsize="8" height="60" lang="english" standard_buttons="ok,cancel" title="Prepare to Go" width="252">
			<control height="40" name="Combo_Box_Alpha1" type="combo" width="78" x="12" y="24">
				<contents>
					<item text="ComboBox Primary" />
					<item text="ATOTaxInv" />
					<item text="BloodP" />
					<item text="CCP Timesheet" />
					<item text="CCP Payslip" />
					<item text="CCP Exp" />
					<item text="CCP Photos" />
					<item text="COD" />
					<item text="CSA" />
					<item text="Dogs Ellie" />
					<item text="Dogs Kirra" />
					<item text="Dogs Both" />
					<item text="Dogs Tiny" />
					<item text="Dogs Nala" />
					<item text="Dogs" />
					<item text="Daily Telfast" />
					<item text="Dinner" />
					<item text="E" />
					<item text="F" />
					<item text="Gym" />
					<item text="Hint" />
					<item text="House" />
					<item text="Inv" />
					<item text="Ingrid" />
					<item text="J" />
					<item text="Kids" />
					<item text="Luke" />
					<item text="Maxalt 1.0" />
					<item text="mDaily" />
					<item text="Maxalt 0.5" />
					<item text="Maxalt STOCK" />
					<item text="Netbank" />
					<item text="ODempsey" />
					<item text="o1Poster" />
					<item text="o2 Books" />
					<item text="PCCET" />
					<item text="Post RTS" />
					<item text="Quotes" />
					<item text="Research Furnature" />
					<item text="RJ" />
					<item text="RJ Netball" />
					<item text="Research" />
					<item text="StC" />
					<item text="Tomb" />
					<item text="ThumbLHS" />
					<item text="Trading" />
					<item text="u1History" />
					<item text="u2Culture" />
					<item text="vMovies" />
					<item text="Vaya" />
					<item text="Work" />
					<item text="xStorage" />
					<item text="Y" />
					<item text="zxc" />
					<item text="1ThumbF" />
					<item text="2Twice" />
					<item text="3" />
					<item text="0" />
				</contents>
			</control>
			<control halign="left" height="12" name="Suffix" tip="Suffix" type="edit" width="64" x="168" y="24" />
			<control height="40" name="Combo_Box_Beta2" type="combo" width="54" x="102" y="24">
				<contents>
					<item text="ComboSec" />
				</contents>
			</control>
		</dialog>
	</resource>
</resources>

VBScript uses & to concatenate strings but JScript uses +. You seem to have a mix there.

Ah thx @Jon mybad
Notice I am at long last converting this script to JS from VB!

Thanks for the help so far.
Below represents my efforts to extract more meaningful information out of my dialog...unsuccessfully as you can see.
My efforts are based around what I understand to be the relevant object namely the DialogListItem
In particular I am after the entry that is selected from the pulldown menu in the Combo_Box referenced.
When I try using the Control.GetItemByName method I get the error shown.

function OnClick(clickData) 
{
    DOpus.ClearOutput;
	DOpus.Output("001000 Start");
//  001000
//  001000 Start
//  001000
//
	var Dlg = DOpus.Dlg;
    Dlg.window = clickData.func.sourcetab;
    Dlg.template = "Dialog_1";
    Dlg.detach = true;
    Dlg.Show();
//  002000
//  002000 Msg Loop
//  002000
	DOpus.Output("002000 Msg Loop");
	i = 0;
    while (true) 
	{
        DOpus.Output("   000   Iteration ======================================================"+ i);
        var Msg = Dlg.GetMsg();
        if (!Msg.result) break;
        DOpus.Output("   000   Combo_Box_Alpha1 index     =  "+ Dlg.Control("Combo_Box_Alpha1").value);
		//
        DOpus.Output("   010   Msg Event                  = " + Msg.event);
//        DOpus.Output("   020   Msg.Checked                = " + Msg.Checked);
        DOpus.Output("   020   Msg.Data                   = " + Msg.Data);
        DOpus.Output("   020   Msg.Icon                   = " + Msg.Icon);
        DOpus.Output("   020   Msg.Selected               = " + Msg.Selected);
        DOpus.Output("   020   Msg.Subitems               = " + Msg.Subitems);
        DOpus.Output("   020   Msg.Control                = " + Msg.Control);
        DOpus.Output("   030   Msg.Dialog                 = " + Msg.Dialog);
        DOpus.Output("   040   Msg.Index                  = " + Msg.Index);
        DOpus.Output("   040   Msg.Name                   = " + Msg.Name);
//
        Combo_Box_1 = Control.GetItemByName("Combo_Box_Alpha1")
		
    }
//  002000
//  002000 Exit Loop
//  002000
	DOpus.Output("002000 Exit Loop");
    DOpus.Output("   010 Return code                  = " + Dlg.result);
	DOpus.Output("   020   Combo_Box_Alpha1 index     = " + Dlg.Control("Combo_Box_Alpha1").value);
    DOpus.Output("009000 End");
}

This is the error I am getting currently:
image

I have left off more information e.g. the dialog XML for brevity. Happy to add if needed.
Appreciate any hints or suggestions....

Have a look at my SelectByDate command which uses a detached dialog.

I advise you to create variables for your dialog controls before going into the msg loop so that you can interact with them later on easily without always referencing the dialog

var Combo_Box_Alpha1 = dlg.Control("Combo_Box_Alpha1");
while(true) {
var val = Combo_Box_Alpha1.value;
...

You already did it the right way when printing the combo index.
In the end you use Control without referencing the dialog. Docs say

Use the Dialog.Control method to obtain a Control object

So my question above was about getting the text for the selected combo box entry:
"In particular I am after the entry that is selected from the pulldown menu in the Combo_Box referenced"
It seems I have a solution as per below.
It is necessary to dig into the DailogListItem to get its name.
I was looking at the parent Control object.

The hierarchy of objects is as follows

DOpus > Dialog > Control > DialogListItem

function OnClick(clickData)
{
    DOpus.ClearOutput;
	DOpus.Output("001000 Start Rev_003");
//  001000
//  001000 Start
//  001000
//
	var Dlg = DOpus.Dlg;
    Dlg.window = clickData.func.sourcetab;          // Parent Window of the dialog
    Dlg.template = "Dialog_1";                      // GUI Script Dialog defined in Resources
    Dlg.detach = true;
    Dlg.Show();
//  002000
//  002000 Msg Loop
//  002000
	DOpus.Output("002000 Msg Loop");
	Control_Combo_BoxA1 = Dlg.Control("Combo_Box_Alpha1")  // Returns a Control object
	i = 0;
    while (true) 
	{
        DOpus.Output("   000   Iteration ======================================================"+ i);
        var Msg = Dlg.GetMsg();
        if (!Msg.result) break;
        DOpus.Output("   000   Combo_Box_Alpha1 value        =  "+ Dlg.Control("Combo_Box_Alpha1").value);
        DOpus.Output("   005   Control_Combo_Box_Al value    =  "+ Control_Combo_BoxA1.value);
        DOpus.Output("   006   Control_Combo_Box_Al count    =  "+ Control_Combo_BoxA1.count);
		DialogListItem_Combo_BoxA1 = Control_Combo_BoxA1.value;                                            // Returns a DialogListItem
        DOpus.Output("   007   DialogListItem.name           =  "+ DialogListItem_Combo_BoxA1.name);
        DOpus.Output("   008   DialogListItem.index          =  "+ DialogListItem_Combo_BoxA1.index);
		//
        DOpus.Output("   010   Msg Event                  = " + Msg.event);
//        DOpus.Output("   020   Msg.Checked                = " + Msg.Checked);
        DOpus.Output("   020   Msg.Data                   = " + Msg.Data);
        DOpus.Output("   020   Msg.Icon                   = " + Msg.Icon);
        DOpus.Output("   020   Msg.Selected               = " + Msg.Selected);
        DOpus.Output("   020   Msg.Subitems               = " + Msg.Subitems);
        DOpus.Output("   020   Msg.Control                = " + Msg.Control);
        DOpus.Output("   030   Msg.Dialog                 = " + Msg.Dialog);
        DOpus.Output("   040   Msg.Index                  = " + Msg.Index);
        DOpus.Output("   040   Msg.Name                   = " + Msg.Name);
//
//        Combo_Box_1 = Control.GetItemByName("Combo_Box_Alpha1")
		
    }
//  002000
//  002000 Exit Loop
//  002000
	DOpus.Output("002000 Exit Loop");
    DOpus.Output("   010 Return code                     =  " + Dlg.result);
  	DOpus.Output("   020   Combo_Box_Alpha1 index        =  " + Dlg.Control("Combo_Box_Alpha1").value);
    DOpus.Output("   030   Control_Combo_Box_Al value    =  " + Control_Combo_BoxA1.value);
//    DOpus.Output("   040   Control_Combo_Box_Al count    =  " + Control_Combo_BoxA1.count);   // Outside loop not work for some reason?
    DOpus.Output("   040   DialogListItem.name     =  "+ DialogListItem_Combo_BoxA1.name);
    DOpus.Output("   050   DialogListItem.index    =  "+ DialogListItem_Combo_BoxA1.index);
    DOpus.Output("009000 End");
}

This is the Dialog Box that pops up and the debug output for selecting Item4 and clicking ok