Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » SOLVED: Text setText Issue Verification(I have a code snippet of which seems to be generating a fault in the framework and wanted to verify the problem)
SOLVED: Text setText Issue Verification [message #492058] Sat, 17 October 2009 20:11 Go to next message
Ricky Patel is currently offline Ricky PatelFriend
Messages: 33
Registered: July 2009
Member
I came upon this issue because I was creating a Wizard and was attempting to set the text of one of the Text fields in the wizard in the createControl method.

I'm running Windows x64 Vista and eclipse 3.4.2 and I have yet to try it on another platform (seeing that I have none others)

Within the createControl method I have the following code
new Label(composite, SWT.NONE).setText("Username");
username = getUsernameControl(composite); //which will return an already created username control or in this case a brand new username control. I've checked, it doesnt return null
username.setText(tempUsername);


Where tempUsername is a string that can be anything but null. I've run two tests, one where tempUsername = "" and tempUsername = "test".

When tempUsername = "" the program works perfectly fine.
When tempUsername = "test" the program will fault quietly at line 1877 org.eclipse.swt.widgets.Text: OS.SetWindowText (handle, buffer); when attempting to execute the method setText

Anyone else see anything like this or have a clue what I have done wrong? Thought i would ask the masses before opening a bug

[Updated on: Sat, 17 October 2009 20:20]

Report message to a moderator

Re: Text setText Issue Verification [message #492059 is a reply to message #492058] Sat, 17 October 2009 20:17 Go to previous message
Ricky Patel is currently offline Ricky PatelFriend
Messages: 33
Registered: July 2009
Member
Solved... Sorry for the post, the issue was I had a modify listener on the field and the modify listener ran isPageComplete which checked non-instanciated fields at the time.

Again sorry for the post!
Previous Topic:Problem when including combo boxes as subitems in multi column tree.
Next Topic:Draw text on composite
Goto Forum:
  


Current Time: Sat Apr 27 03:33:07 GMT 2024

Powered by FUDForum. Page generated in 0.02744 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top