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

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




PostPosted: Sat Apr 30, 2005 1:52 pm   Post subject: buttons dont work

I'm working on a program that uses buttons. I have made many of them before but have never had any problems with it. In this program the buttons cannot be clicked. How can I fix it? Here is my code:

code:

import GUI in "%oot/support/lib/GUI"
setscreen ("graphics")

const chatPort : int := 5055
var netStream : int
var netAddress : string

procedure runserver
    netStream := Net.WaitForConnection (chatPort, netAddress)
end runserver

procedure connecttoserver
    put "Enter the address to connect to: " ..
    get netAddress
    netStream := Net.OpenConnection (netAddress, chatPort)
    if netStream <= 0 then
        put "Unable to connect to ", netAddress
    end if
end connecttoserver

procedure main
    var server : int := GUI.CreateButton (282, 260, 135, "run chat server", runserver)
    var connect : int := GUI.CreateButton (252, 160, 35, "connect", connecttoserver)
end main
main
Sponsor
Sponsor
Sponsor
sponsor
Bacchus




PostPosted: Sat Apr 30, 2005 3:55 pm   Post subject: (No subject)

forgot the GUI.ProcessEvent
jrok311




PostPosted: Sat Apr 30, 2005 4:18 pm   Post subject: thanks

o ya, how could i have missed that? Confused thanks
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  [ 3 Posts ]
Jump to:   


Style:  
Search: