Page 1 of 1

Dialog Object Rules

Posted: Tue Mar 22, 2005 12:39 pm
by zchris
I have a dialog that allows the user to enter the password for a service.

The object rules allow me to enable the next button if text is entered in both the password and confirm-password fields - however I would like to enable the next button only if both passwords actually match. Is it possible to test for this somehow?

Thanks.

PS: Could you also enable the 'old style' copy/paste keyboard shortcuts for the IDE and dialog editor (ctrl-ins/shift-ins/shift-del)? I always try to use them and nothing happens :|

Posted: Tue Mar 22, 2005 2:21 pm
by zchris
Also the dialog has a very small bug - if I open the dialog by double clicking on a text box and then click on an existing rule that specifies a radio button, the checked property won't be displayed.

Posted: Tue Mar 22, 2005 4:55 pm
by sinan
Yes, you can do this. Add two dialog rules, one that disables Next if password.text fields do not match, and one that enables Next if password.text fields match. You should be able to define this in the rules editor.

Thanks for the other reports/suggestions.

Posted: Wed Mar 23, 2005 2:59 am
by zchris
Yes, but how can I compare the two control properties?

Code: Select all

IF (LogonPassword1.Text <> LogonPassword2.Text)  THEN  Next.Enabled := False;
This will only compare if LogonPassword1.Text does not contain the text "LogonPassword2.Text".

Posted: Wed Mar 23, 2005 8:05 am
by sinan
I apologize for the misunderstanding, you are correct.

The only place to exercise this control would be the script for now - and not the dialog rules editor. We will add this flexibility in future updates.

Thank you for the suggestion.

Posted: Tue Oct 31, 2006 11:16 am
by andrereg
Hi,

<Memo>
continuing on this topic, i need to enable the next button based on whether someone has pasted in a license (which might contain line breaks) into a Memo component.

Using the following rule does not seem to work:
IF (MemoLicense.Lines <> ) THEN Next.Enabled := True;
Is there a property other than 'Lines' that i should reference to see if there is any text in the memo control?

<PTShellList>
Also, I've used PTShellList in order to select a file. Is there a property that i can check via the rules editor for that component?

I am using InstallAware v6.0.6 (SP3).

thanks,
drew

Posted: Tue Oct 31, 2006 7:27 pm
by MichaelNesmith
Interesting questions.

1) Try using Memo.Text instead.
2) Let PTShellList write to a variable.

Posted: Thu Nov 02, 2006 11:01 am
by andrereg
In the Dialog "Object Rules" editor, the Memo component doesn't have a "text" property. Perhaps this is part of a new version that i don't have yet?

Both my Memo and my PTShellList write to a property, so i can check whether the user populates them and show the dialog again. I was just wondering about being able to validate them via "Object Rules" themselves.
thanks for the suggestions!

Posted: Fri Nov 03, 2006 8:25 am
by MichaelNesmith
Ah sorry, yes this is currently not available.

Posted: Fri Dec 08, 2006 4:09 pm
by andrereg
Another quick question about "Memo" vs "Edit" control.

with "Edit" control, i can set it to write its result to a property "LICENSE"
and set "[Written Variable Value]" in the Object Behavior dialog (under "Receives Information") so that it can be pre-populated with their existing license if this is an upgrade.

with the "Memo" control, i can allow a user to enter a complex field such as an encrypted license. However, during an upgrade, i want to pre-populate the "Memo" control with the license information that the user already has in their database? (only options i see in "Receives Information" are "ReadMe File" and "License Agreement") -- I've tried setting the "Lines" property to "$LICENSE$" as well, but that doesn't seem to work.

are there any other workarounds that would allow me to get my task completed? I wouldn't care which control was used, as long as it was able to get the job done.
-------------

The reason i can't simply replace this usage with an Edit control is that i need to allow the user to paste in multiple lines of text, as our licenses are emailed out in Base64 text. To get this entered via the "Edit" control, the user has to copy/paste multiple times, as the "paste" operation for the "Edit" control truncates the clipboard values past a NEWLINE.

Example:

sAnTm90dTH3LQ8EXL7gCp
xmlcI7wCnq/Bl9OrOvd+Zj
Vk3FKMEL1UqHiPK9/Oxbv2
3GoXeBL1TZCMI5MYIk6s=

thanks!

Posted: Fri Dec 08, 2006 4:44 pm
by MichaelNesmith
I think the Memo control supports writing to a variable - it has a field for that in the Object Behavior tab. Did you try to assing this field to a variable, and then also to pre-set that variable to the initial value you desire? Try to do that - also set the Lines to the same variable (just one line with the var) and see if that helps. Make sure Receives Information is none, of course.

Posted: Fri Dec 08, 2006 4:52 pm
by andrereg
Clarification:

I am already using the *write* capability of the "Memo" component to write to a variable. My question specifically is about a need to *read* from a variable into a Memo component.

thanks!

Posted: Fri Dec 08, 2006 4:54 pm
by MichaelNesmith
Did you try all steps and none of them pre-initializes the memo? If so, I'll escalate this - seems to be a bug.

Posted: Fri Dec 08, 2006 5:20 pm
by andrereg
Thanks for the reply;

I did put in $LICENSE$ in for Memo.Lines, assigned a value to it with "Set Variable" (just to be sure it wasn't blank) and tested it.

The Memo component loads the pre-populated value just fine.

thanks for your quick reply -- we really enjoy using InstallAware!