Thread View: borland.public.jbuilder.java.swing
4 messages
4 total messages
Started by Dominique Descamps
Thu, 13 May 2004 09:39
Problem with JPasswordField in JBuilderX
Author: Dominique Descamps
Date: Thu, 13 May 2004 09:39
Date: Thu, 13 May 2004 09:39
30 lines
1965 bytes
1965 bytes
Good morning, I have an application, using a JPasswordField, that I created using Borland JBuilder8. Now I am continuing developping this applciation using JBuilderX. In order to make this work, I had to add the registry settings concerning the JRE 1.4 environment. Now my application is not able to retrieve the password from the mentioned field anymore using the method "getPassword( )": the result of this method is different each time it is called. I see following possible problems: 1. the component, used in JBuilderX, is not stable. 2. my registry settings are wrong. 3. there is another problem. Could you help me out? 1. Could you tell me where I can find a file, containing a stable JPassWordField component? 2. My settings under "\HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment" are: JavaHome "C:\Program Files\JBuilderX\jdk1.4\jre" MicroVersion "0" RunTimeLib "C:\Program Files\...\client\jvm.dll" Can this be correct? 3. HEEEEELP!!! Best regards Dominique Descamps Software Engineer Alcatel Bell, Belgium
Re: Problem with JPasswordField in JBuilderX
Author: Kevin Dean
Date: Thu, 13 May 2004 12:26
Date: Thu, 13 May 2004 12:26
51 lines
2756 bytes
2756 bytes
If you're running the application from inside JBuilder, the registry settings don't matter. Do that first in order to eliminate the registry as a problem. After that, start stripping out code until you get a minimal test case. You can then upload the test case to borland.public.attachments and someone may be able to take a look at it. -- Check out our latest white papers at http://www.datadevelopment.com/papers/index.html BladeNET Scores With Borland Enterprise Tools Team Development with JBuilder and Borland Enterprise Server Dolphin Data Development Ltd. http://www.datadevelopment.com/ "Dominique Descamps" <dominique.descamps@alcatel.be> wrote in message news:40A34244.D48DC3D@alcatel.be... > Good morning, > I have an application, using a JPasswordField, that I created using > Borland JBuilder8. > Now I am continuing developping this applciation using JBuilderX. In > order to make this work, I had to add the registry settings concerning > the JRE 1.4 environment. > Now my application is not able to retrieve the password from the > mentioned field anymore using the method "getPassword( )": the result of > this method is different each time it is called. > > I see following possible problems: > 1. the component, used in JBuilderX, is not stable. > 2. my registry settings are wrong. > 3. there is another problem. > > Could you help me out? > 1. Could you tell me where I can find a file, containing a stable > JPassWordField component? > 2. My settings under "\HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime > Environment" are: > JavaHome "C:\Program Files\JBuilderX\jdk1.4\jre" > MicroVersion "0" > RunTimeLib "C:\Program Files\...\client\jvm.dll" > Can this be correct? > 3. HEEEEELP!!! > > Best regards > Dominique Descamps > Software Engineer > Alcatel Bell, Belgium >
Re: Problem with JPasswordField in JBuilderX
Author: Kevin Dean
Date: Fri, 14 May 2004 12:25
Date: Fri, 14 May 2004 12:25
51 lines
2734 bytes
2734 bytes
The problem is the way you're using the password field. The getPassword() method returns an array of char; when you call toString() on the result, it gives you the type and address, not a string of the array. To convert it to a string, do the following: String password = new String(passwordField.getPassword()); -- Check out our latest white papers at http://www.datadevelopment.com/papers/index.html BladeNET Scores With Borland Enterprise Tools Team Development with JBuilder and Borland Enterprise Server Dolphin Data Development Ltd. http://www.datadevelopment.com/ "Dominique Descamps" <dominique.descamps@alcatel.be> wrote in message news:40A34244.D48DC3D@alcatel.be... > Good morning, > I have an application, using a JPasswordField, that I created using > Borland JBuilder8. > Now I am continuing developping this applciation using JBuilderX. In > order to make this work, I had to add the registry settings concerning > the JRE 1.4 environment. > Now my application is not able to retrieve the password from the > mentioned field anymore using the method "getPassword( )": the result of > this method is different each time it is called. > > I see following possible problems: > 1. the component, used in JBuilderX, is not stable. > 2. my registry settings are wrong. > 3. there is another problem. > > Could you help me out? > 1. Could you tell me where I can find a file, containing a stable > JPassWordField component? > 2. My settings under "\HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime > Environment" are: > JavaHome "C:\Program Files\JBuilderX\jdk1.4\jre" > MicroVersion "0" > RunTimeLib "C:\Program Files\...\client\jvm.dll" > Can this be correct? > 3. HEEEEELP!!! > > Best regards > Dominique Descamps > Software Engineer > Alcatel Bell, Belgium >
Re: Problem with JPasswordField in JBuilderX
Author: Dominique Descamps
Date: Mon, 17 May 2004 09:39
Date: Mon, 17 May 2004 09:39
59 lines
2960 bytes
2960 bytes
Hello Kevin, Thank you for the help, this was indeed the solution. Best regards Dominique Kevin Dean wrote: > The problem is the way you're using the password field. The getPassword() > method returns an array of char; when you call toString() on the result, it > gives you the type and address, not a string of the array. > > To convert it to a string, do the following: > > String password = new String(passwordField.getPassword()); > > -- > Check out our latest white papers at > http://www.datadevelopment.com/papers/index.html > > BladeNET Scores With Borland Enterprise Tools > Team Development with JBuilder and Borland Enterprise Server > > Dolphin Data Development Ltd. > http://www.datadevelopment.com/ > > "Dominique Descamps" <dominique.descamps@alcatel.be> wrote in message > news:40A34244.D48DC3D@alcatel.be... > > Good morning, > > I have an application, using a JPasswordField, that I created using > > Borland JBuilder8. > > Now I am continuing developping this applciation using JBuilderX. In > > order to make this work, I had to add the registry settings concerning > > the JRE 1.4 environment. > > Now my application is not able to retrieve the password from the > > mentioned field anymore using the method "getPassword( )": the result of > > this method is different each time it is called. > > > > I see following possible problems: > > 1. the component, used in JBuilderX, is not stable. > > 2. my registry settings are wrong. > > 3. there is another problem. > > > > Could you help me out? > > 1. Could you tell me where I can find a file, containing a stable > > JPassWordField component? > > 2. My settings under "\HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime > > Environment" are: > > JavaHome "C:\Program Files\JBuilderX\jdk1.4\jre" > > MicroVersion "0" > > RunTimeLib "C:\Program Files\...\client\jvm.dll" > > Can this be correct? > > 3. HEEEEELP!!! > > > > Best regards > > Dominique Descamps > > Software Engineer > > Alcatel Bell, Belgium > >
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads