none
How To Create A Small Basic Chat Program Using LDClient And LDServer? RRS feed

Answers

  •  sample server program ...  KWS326

     server PC's IP address and portnumber are shown on Graphicswindow.Title (Left Top)  

     sample client program ... XZZ858

    ServerIP="192.168.11.16" '    <--  change this IP address 
    PortNMB = 100                 '  <----- change this   Port Number

    Firstly click Connect_To_Server button.

    write message (left bottom box) and click Send_message button .

    if want to stop , click disconnect button.

    server program should be runned firstly before client program.

    • Marked as answer by [Roshan_Kumar] Wednesday, August 2, 2017 2:55 PM
    Tuesday, August 1, 2017 2:06 PM
    Answerer

All replies

  • Did you look into the folder 'client-server'  in the downloaded LitDev_v1.2.zip ??

    There are:

    client-server\ChatClient.sb
    client-server\ChatServer.sb
    client-server\LDClient.sb
    client-server\LDClientAuto.sb
    client-server\LDServer.sb
    client-server\LDServerAuto.sb

    Tuesday, August 1, 2017 10:36 AM
    Answerer
  • Thanks. I am able to get the files. I am new to small basic. I need to get the data from client and print it in the console. what is the method has to be used in server to receive the data from client. I scanned through the methods but I don't find anything that is used to receive the data. Kindly suggest in the below server program to receive the client data

    connect = LDServer.Start("True")
    File.WriteContents(Program.Directory+"\ChatConnect.txt",connect)
    TextWindow.Title = "Chat Server"
    LDServer.AutoMessages = "True"
    While ("True")
      Program.Delay(10)
    EndWhile

    Tuesday, August 1, 2017 12:30 PM
  •  sample server program ...  KWS326

     server PC's IP address and portnumber are shown on Graphicswindow.Title (Left Top)  

     sample client program ... XZZ858

    ServerIP="192.168.11.16" '    <--  change this IP address 
    PortNMB = 100                 '  <----- change this   Port Number

    Firstly click Connect_To_Server button.

    write message (left bottom box) and click Send_message button .

    if want to stop , click disconnect button.

    server program should be runned firstly before client program.

    • Marked as answer by [Roshan_Kumar] Wednesday, August 2, 2017 2:55 PM
    Tuesday, August 1, 2017 2:06 PM
    Answerer