Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: TIWEdit Property PasswordPrompt



Permlink Replies: 8 - Last Post: Mar 4, 2018 12:40 AM Last Post By: Juergen Schlaack
Juergen Schlaack

Posts: 9
Registered: 8/29/00
TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Feb 25, 2018 10:42 AM
Hello,

modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Juergen
Chad Hower

Posts: 613
Registered: 3/2/07
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Feb 26, 2018 10:16 AM   in response to: Juergen Schlaack in response to: Juergen Schlaack
On 2/25/2018 2:42 PM, Juergen Schlaack wrote:
modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Where and how are you modifying it?
Juergen Schlaack

Posts: 9
Registered: 8/29/00
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Feb 27, 2018 12:53 AM   in response to: Chad Hower in response to: Chad Hower
Chad Hower wrote:
On 2/25/2018 2:42 PM, Juergen Schlaack wrote:
modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Where and how are you modifying it?

Hi Chad,

here is a example code for this problem:

void __fastcall TIWU_Frm_Login::ControlsInit(void)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncEnter(TObject *Sender, TStringList *EventParams)
{
IWEditPassword->PasswordPrompt = true;
IWEditPassword->BGColor = clWebWHITE;
IWEditPassword->Font->Color = clWebBLACK;
IWEditPassword->Text = L"";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncExit(TObject *Sender, TStringList *EventParams)
{
if(IWEditPassword->Text.IsEmpty() == true)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}
}

Thanks for your help
Juergen
Alexandre Machado

Posts: 1,754
Registered: 8/10/13
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Feb 27, 2018 11:32 PM   in response to: Juergen Schlaack in response to: Juergen Schlaack
Juergen Schlaack wrote:
Chad Hower wrote:
On 2/25/2018 2:42 PM, Juergen Schlaack wrote:
modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Where and how are you modifying it?

Hi Chad,

here is a example code for this problem:

void __fastcall TIWU_Frm_Login::ControlsInit(void)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncEnter(TObject *Sender, TStringList *EventParams)
{
IWEditPassword->PasswordPrompt = true;
IWEditPassword->BGColor = clWebWHITE;
IWEditPassword->Font->Color = clWebBLACK;
IWEditPassword->Text = L"";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncExit(TObject *Sender, TStringList *EventParams)
{
if(IWEditPassword->Text.IsEmpty() == true)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}
}

Thanks for your help
Juergen

Hi, I'll check that and let you know.
Juergen Schlaack

Posts: 9
Registered: 8/29/00
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Feb 28, 2018 12:34 AM   in response to: Alexandre Machado in response to: Alexandre Machado
Alexandre Machado wrote:
Juergen Schlaack wrote:
Chad Hower wrote:
On 2/25/2018 2:42 PM, Juergen Schlaack wrote:
modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Where and how are you modifying it?

Hi Chad,

here is a example code for this problem:

void __fastcall TIWU_Frm_Login::ControlsInit(void)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncEnter(TObject *Sender, TStringList *EventParams)
{
IWEditPassword->PasswordPrompt = true;
IWEditPassword->BGColor = clWebWHITE;
IWEditPassword->Font->Color = clWebBLACK;
IWEditPassword->Text = L"";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncExit(TObject *Sender, TStringList *EventParams)
{
if(IWEditPassword->Text.IsEmpty() == true)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}
}

Thanks for your help
Juergen

Hi, I'll check that and let you know.

Thanks, Juergen
Alexandre Machado

Posts: 1,754
Registered: 8/10/13
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Feb 28, 2018 12:52 AM   in response to: Juergen Schlaack in response to: Juergen Schlaack
Juergen Schlaack wrote:
Chad Hower wrote:
On 2/25/2018 2:42 PM, Juergen Schlaack wrote:
modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Where and how are you modifying it?

Hi Chad,

here is a example code for this problem:

void __fastcall TIWU_Frm_Login::ControlsInit(void)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncEnter(TObject *Sender, TStringList *EventParams)
{
IWEditPassword->PasswordPrompt = true;
IWEditPassword->BGColor = clWebWHITE;
IWEditPassword->Font->Color = clWebBLACK;
IWEditPassword->Text = L"";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncExit(TObject *Sender, TStringList *EventParams)
{
if(IWEditPassword->Text.IsEmpty() == true)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}
}

Thanks for your help
Juergen

Hi Juergen,

now I see what you mean. Everything works in your example, however you can't change a input from type text to password from within an Async event. This is as designed, at least in current version. Why are you using a single control to input password and plain text? IMO this doesn't make much sense and can be prone to security issues (browser autocomplete, etc)
Juergen Schlaack

Posts: 9
Registered: 8/29/00
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 1, 2018 6:43 AM   in response to: Alexandre Machado in response to: Alexandre Machado
Alexandre Machado wrote:
Juergen Schlaack wrote:
Chad Hower wrote:
On 2/25/2018 2:42 PM, Juergen Schlaack wrote:
modifying the property PasswordPrompt at runtime seems not to work at all for INTRAWEB 14.2.6 in C++Builder.

Where and how are you modifying it?

Hi Chad,

here is a example code for this problem:

void __fastcall TIWU_Frm_Login::ControlsInit(void)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncEnter(TObject *Sender, TStringList *EventParams)
{
IWEditPassword->PasswordPrompt = true;
IWEditPassword->BGColor = clWebWHITE;
IWEditPassword->Font->Color = clWebBLACK;
IWEditPassword->Text = L"";
}

void __fastcall TIWU_Frm_Login::IWEditPasswordAsyncExit(TObject *Sender, TStringList *EventParams)
{
if(IWEditPassword->Text.IsEmpty() == true)
{
IWEditPassword->PasswordPrompt = false;
IWEditPassword->BGColor = clWebLIGHTGRAY;
IWEditPassword->Font->Color = clWebGRAY;
IWEditPassword->Text = L"Insert password";
}
}

Thanks for your help
Juergen

Hi Juergen,

now I see what you mean. Everything works in your example, however you can't change a input from type text to password from within an Async event. This is as designed, at least in current version. Why are you using a single control to input password and plain text? IMO this doesn't make much sense and can be prone to security issues (browser autocomplete, etc)

Hi Alexandre,

thanks for your answer.

There are a lot of modern login dialogs now in many applications.Instead of labels for the login and password edit fields there are just a body image and a lock image and the label text is shown in the edit fields, as long as the user didn't type in anything.
This is my reason for this design.

Juergen
Alexandre Machado

Posts: 1,754
Registered: 8/10/13
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 3, 2018 2:35 AM   in response to: Juergen Schlaack in response to: Juergen Schlaack
There are a lot of modern login dialogs now in many applications.Instead of labels for the login and password edit fields there are just a body image and a lock image and the label text is shown in the edit fields, as long as the user didn't type in anything.
This is my reason for this design.

Juergen

Next release will support it. This feature is already committed in our main branch.
Juergen Schlaack

Posts: 9
Registered: 8/29/00
Re: TIWEdit Property PasswordPrompt
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 4, 2018 12:40 AM   in response to: Alexandre Machado in response to: Alexandre Machado
Alexandre Machado wrote:
There are a lot of modern login dialogs now in many applications.Instead of labels for the login and password edit fields there are just a body image and a lock image and the label text is shown in the edit fields, as long as the user didn't type in anything.
This is my reason for this design.

Juergen

Next release will support it. This feature is already committed in our main branch.

Great
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02