I have set two dialogs and try to get the return value from dialog1 (Edit property) and set it into dialog2 (Edit property). I have no success to do it. After I click Button A and B and I will have the variable name=AB
in dialog1. But I can not use that variable %name% to set into the Edit1object of dialog2.
I want AB to show in dialog2.
Please help. And please show me how to post code here

Here is my program:
Dialog>Dialog1
object Dialog1: TForm
Left = 2460
Top = 103
HelpContext = 5000
BorderIcons = [biSystemMenu]
Caption = 'CustomDialog'
ClientHeight = 205
ClientWidth = 586
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -14
Font.Name = 'MS Sans Serif'
Font.Style = []
OldCreateOrder = True
ShowHint = True
OnTaskBar = False
PixelsPerInch = 120
TextHeight = 16
object Edit1: TEdit
Left = 192
Top = 41
Width = 194
Height = 24
TabOrder = 0
Text = 'Edit1'
end
object MSButton1: tMSButton
Left = 134
Top = 96
Width = 75
Height = 25
Caption = 'A'
TabOrder = 1
DoBrowse = False
BrowseStyle = fbOpen
end
object MSButton2: tMSButton
Left = 393
Top = 92
Width = 75
Height = 25
Caption = 'B'
TabOrder = 2
DoBrowse = False
BrowseStyle = fbOpen
end
object MSButton3: tMSButton
Left = 162
Top = 150
Width = 75
Height = 25
Caption = 'OK'
ModalResult = 1
TabOrder = 3
DoBrowse = False
BrowseStyle = fbOpen
end
object MSButton4: tMSButton
Left = 341
Top = 151
Width = 75
Height = 25
Caption = 'CANCEL'
TabOrder = 4
DoBrowse = False
BrowseStyle = fbOpen
end
end
EndDialog>Dialog1
Dialog>Dialog2
object Dialog2: TForm
Left = 2460
Top = 103
HelpContext = 5000
BorderIcons = [biSystemMenu]
Caption = 'CustomDialog'
ClientHeight = 205
ClientWidth = 586
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -14
Font.Name = 'MS Sans Serif'
Font.Style = []
OldCreateOrder = True
ShowHint = True
OnTaskBar = False
PixelsPerInch = 120
TextHeight = 16
object Edit1: TEdit
Left = 208
Top = 62
Width = 177
Height = 24
TabOrder = 8
Text = 'Edit1'
end
object MSButton1: tMSButton
Left = 146
Top = 124
Width = 75
Height = 25
Caption = 'CONFIRM'
ModalResult = 1
TabOrder = 9
DoBrowse = False
BrowseStyle = fbOpen
end
object MSButton2: tMSButton
Left = 389
Top = 127
Width = 75
Height = 25
Caption = 'RESET'
ModalResult = 2
TabOrder = 10
DoBrowse = False
BrowseStyle = fbOpen
end
end
EndDialog>Dialog2
AddDialogHandler>Dialog1,MSButton1,OnClick,clickA
AddDialogHandler>Dialog1,MSButton2,OnClick,clickB
let>signal=0
show>dialog1,s1
if>s1=1
let>name=text
let>text=
let>dialog1.Edit1=text
ResetDialogAction>dialog1
endif
mdl>name
SetDialogProperty>dialog2,Edit1,Text,name
Show>dialog2,s2
SRT>clickA
GetDialogProperty>Dialog1,MSButton1,Caption,nameA
Gosub>signal condition
ConCat>text,nameA
let>dialog1.Edit1=text
ResetDialogAction>dialog1
let>signal=1
END>clickA
SRT>clickB
GetDialogProperty>Dialog1,MSButton2,Caption,nameB
Gosub>signal condition
ConCat>text,nameB
let>dialog1.Edit1=text
ResetDialogAction>dialog1
let>signal=1
END>clickB
SRT>signal condition
if>signal=0
let>text=
endif
END>signal condition