Mark,
 
I ran the example on page 38 of the ooDialog Reference (r7012).
It worked fine - now I understand the use of DlgData and its advantages. 
(Btw, the sample has a typo - no "." on "DlgData" in the "dlg =
.BuildDialog~new..." statement. Also, an "IDC_" missing from resource names
for radio buttons and checkbox.)
 
The code is below.
 
Two problems I met:
(a) The console output (no user inpuit - just show dialog then close it)
was:
D:\ ... >builddlg
'CONTINUE' is not recognized as an internal or external command, operable
program or batch file.
Do Release Build.
Where did the "CONTINUE" error come from? It appears at the same time as the
dialog.
 
(b) How do you get the radio buttons to accept a click? I did this for
ProductView, but I cannot now see (or remember) what I did!!
 
Many thanks,
Oliver
 
 
Code for BuildDialog (the .rc file is called DlgData.rc for very boring
reasons; init and initDialog methods are commented out - appears to make no
difference if they're uncommented):
 
/* Sample use of dlgData from ooDialog Reference 7102 Page 38.  */
 
DlgData.IDC_EDITFIELD_INCLUDE = "C:\sdk\include"
DlgData.IDC_COMBOBOX_PROJECT = "Calculator"
DlgData.IDC_RADIO_DEBUG = 0
DlgData.IDC_RADIO_RELEASE = 1
 
DlgData.IDC_CHECKBOX_CLEAN = 0
dlg = .BuildDialog~new("DlgData.dll", IDD_BUILD_DLG, DlgData., "DlgData.h")
if dlg~initCode <> 0 then do
  say "Error starting dialog. initCode:" dlg~initCode
  return dlg~initCode
end
dlg~execute("NORMAL")  -- icon omitted
 
if DlgData.IDC_CHECKBOX_CLEAN == 1 then say "doClean()"
includePath = DlgData.IDC_EDITFIELD_INCLUDE
if DlgData.IDC_RADIO_RELEASE == 1 then
  --success = doReleaseBuild(includePath)
  say "Do Release Build."
else
 --success = doDebugBuild(includePath)
  say "Do Debug Build."
return success

::requires ooDialog.cls
 
::CLASS BuildDialog SUBCLASS ResDialog
/*
  ::METHOD init
    say "init-01."
    forward class (super) continue
    say "init-02."
 
  ::METHOD initDialog
    say "initDialog."
*/    
 

Attachment: DlgData.h
Description: Binary data

Attachment: DlgData.rc
Description: Binary data

Attachment: DlgData.dll
Description: application/msdownload

------------------------------------------------------------------------------
All of the data generated in your IT infrastructure is seriously valuable.
Why? It contains a definitive record of application performance, security 
threats, fraudulent activity, and more. Splunk takes this data and makes 
sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-d2d-c2
_______________________________________________
Oorexx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-users

Reply via email to