PDA

View Full Version : How to SET Control



CMS Software
09-30-2009, 12:02 PM
The new release is great. An example on one of the more arcane uses of "Set Control" would be a great help.

I am attempting to get the Edit Data [Multiline] dialog to select ALL the entered text.

My script contains the following two lines:
http://www.lindersoft.com/community_images/ScriptLines.gif

I tried placing the Set Control line first, but then I get an "Undefined Variable" error.

Here is the Advanced tab from the Edit Data screen.
http://www.lindersoft.com/community_images/EditData.gif

The Dialog Label is "GETMAINTSUBS", so I placed that in the Set Control screen as shown here.
http://www.lindersoft.com/community_images/SetControl.gif

The result is shown here with parts of the Subscription Key blanked out. The text is NOT selected. What am I doing wrong?
http://www.lindersoft.com/community_images/Result.gif

What am I doing wrong?

O. D. Williams
CMS, Inc.

linder
10-01-2009, 01:34 AM
Hello,

I have developed a demo for you (see attached). Does this help?

Friedrich

CMS Software
10-01-2009, 03:28 PM
I think I have it now. If we use the Script Functions Define Wizard Dialog to produce an Edit Data [Multi Line] dialog, then the $SB_DIALOGID$ name is $EDITDATA_MULTIEDIT1$. (Where is that documented?) We also have to place a few lines of code in the script to achieve the highlighted text function.

Now, if we use the Custom Wizard Dialog to produce an Edit Data [Multi Line] dialog, then is the name of the edit control assigned by us as shown at #1 in the image below?
http://www.lindersoft.com/community_images/EditCtrlProp1.gif

Assuming that's true, I have a suggestion. It would be so wonderful if another checkbox was positioned to the right of the Multiple checkbox as shown at #2. That second checkbox would say "Select All Text". Now no additional external code is needed to get ALL the text selected in the Edit box! More programmer time saved and less chance for a typographical error in the external code needed to cause text highlighting!

Yes/No???

O. D. Williams
CMS, Inc.

linder
10-02-2009, 03:39 AM
I think I have it now. If we use the Script Functions Define Wizard Dialog to produce an Edit Data [Multi Line] dialog, then the $SB_DIALOGID$ name is $EDITDATA_MULTIEDIT1$. (Where is that documented?)

It's not documented because the above assumption is NOT correct.

$SB_DIALOGID$ is the label that identifies the dialog and $EDITDATA_MULTIEDIT1$ is a control identifier (in your case, it identifies the multiple-line text control in the Edit Data [Multi Line] dialog).

Friedrich

--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910

SetupBuilder is Windows installation -- "point. click. ship"

-- Official Comodo Code Signing and SSL Certificate Partner

linder
10-02-2009, 03:41 AM
It would be so wonderful if another checkbox was positioned to the right of the Multiple checkbox as shown at #2. That second checkbox would say "Select All Text". Now no additional external code is needed to get ALL the text selected in the Edit box! More programmer time saved and less chance for a typographical error in the external code needed to cause text highlighting!

Yes/No???


Yes, that's a good idea. We'll add this to the next build.

Thank you for your suggestion.

Friedrich