Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 GUI Help
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
azndragon




PostPosted: Sun Jan 19, 2003 9:24 pm   Post subject: GUI Help

code:
import GUI in "%oot/lib/GUI"
View.Set ("graphics:800;600")

GUI.SetBackgroundColor (gray)
var character_nameTextField : int
var character_name : string
var character_gender : string

var statusscreen1 := GUI.CreateTextBox (500, 100, 200, 450)

procedure character_nameEntered (text : string)
    GUI.SetSelection (character_nameTextField, 0, 0)
    GUI.SetActive (character_nameTextField)
end character_nameEntered

procedure screen1preview
    GUI.ClearText (statusscreen1)
    character_name := GUI.GetText (character_nameTextField)
    GUI.AddText (statusscreen1, character_name)
end screen1preview

var showstatus := GUI.CreateButton (565, 75, 0, "Update", screen1preview)
var nameLabel := GUI.CreateLabelFull (70, 525, "Name", 0, 0, GUI.RIGHT, 0)

character_nameTextField := GUI.CreateTextField (75, 525, 100, "", character_nameEntered)

loop
    exit when GUI.ProcessEvent
end loop


An error happens when I'm trying to run it. I want it so that when you type in your name, and then click "Update", it will display the name in the text box, can anyone help me with this?
Sponsor
Sponsor
Sponsor
sponsor
azndragon




PostPosted: Wed Jan 22, 2003 7:58 pm   Post subject: (No subject)

Um, still no replies, can anyone look into this for me?
Tony




PostPosted: Wed Jan 22, 2003 8:19 pm   Post subject: (No subject)

Confused

I took a look and I can't figure out whats wrong with it. Seems to be an error in GUI module, not your code... I didn't use GUI much myself (I used VB for that Wink) so I can't really tell... maybe someone else knows? Message Dan (though he got exams at the moment)
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
azndragon




PostPosted: Wed Jan 22, 2003 8:40 pm   Post subject: (No subject)

Maybe I have a corrupted version of Turing? Oh well, I'll figure it out later, I have exams also. Just finished my English one today, tomorrow is my business, comp engineering after that, and then science. Busy schedule Crying or Very sad
Tony




PostPosted: Wed Jan 22, 2003 9:02 pm   Post subject: (No subject)

hehe, I wrote my exams in December Very Happy feels great!

though now I got a bunch of unit tests to write and then there's that art portfolio meeting next week... I got to finish up on my drawings and have them done in a week. Work just kinda appeard out of nowhere Mad

stupid english... lots of work, low mark... DAMN, tony pissed Evil or Very Mad
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
azndragon




PostPosted: Wed Jan 22, 2003 9:15 pm   Post subject: (No subject)

Haha, opposite here, doing great in English, even though it should be lower than my science, getting 90 in english, and 87 in science, just need to add the exam marks in later for my final Laughing
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 6 Posts ]
Jump to:   


Style:  
Search: