GabrielBarbu
Posts: 2146
Joined: Thu Jul 09, 2009 11:24 am
Contact: Website

Re: How to validate parameters in custom dialog

Hi Dashut,

Unfortunately, Windows Installer does not allow for this level of control over its inputs. Without some hacking, I am not sure you can set the focus back to the EditBox. Perhaps some custom action could run, list the text inputs on the window, find the password text input and manually set its focus, all this using the win32 API. It's an ugly approach and I wouldn't recommend it as it may not be 100% reliable on all operating systems. And it also might require (a lot of) tweaking if you intend on using it both on a Windows Installer interface and on an Enhanced Interface.

About clearing the password field.
Password fields often show more '*' characters than the password actually has. This might be your case. The password is empty but the '*' characters still show up.
Another reason for this might be that it is possibly a limitation in Windows Installer.
You could try the twin dialog method for refreshing the dialogs after clearing the password field's property. It might just work.

Do let me know how this turned out.

Best regards,
Gabriel
Gabriel Barbu
Advanced Installer Team
http://www.advancedinstaller.com/
Dashut
Posts: 142
Joined: Tue May 04, 2010 4:41 pm

Re: How to validate parameters in custom dialog

I know this works when I'm NOT using the EditBox as "password" mode.
Also, if I return to my dialog, but then press "back" and then "next" again to return to the same user/pass dialog: the password Editbox is CLEAR!
So this means that it "should work", but for some reason it's not working.

About creating a "twin dialog": well, to say the truth: that's too much for something so small. I'm not sure I want to go so far to achieve this.

Do you think this is Windows Installer? or AdvancedInstaller limitation?
Dashut.
GabrielBarbu
Posts: 2146
Joined: Thu Jul 09, 2009 11:24 am
Contact: Website

Re: How to validate parameters in custom dialog

Hello,

I am quite sure it is a Windows Installer limitation, since it pertains to the Windows Installer UI. I also noticed that back+next clears the text , which is why I suggested the twin dialog method.

Best regards,
Gabriel
Gabriel Barbu
Advanced Installer Team
http://www.advancedinstaller.com/

Return to “Common Problems”