Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Jun 9th, 2006, 5:31 PM   #1
Brent
Highly Adaptive Penguin
 
Brent's Avatar
 
Join Date: May 2005
Location: United States
Posts: 251
Rep Power: 4 Brent is on a distinguished road
Chiba Instant Messenger

This is just a simple C++ chat application that I built. it uses WINAPI and WINSOCK. It can be used as both a client or a server. For now its only 2-way, but im planning on making it multi-threaded.
Attached Files
File Type: zip Chiba.zip (28.1 KB, 33 views)
Brent is offline   Reply With Quote
Old Jun 9th, 2006, 5:52 PM   #2
jayme
Professional Programmer
 
jayme's Avatar
 
Join Date: Nov 2005
Location: Canada
Posts: 495
Rep Power: 0 jayme is an unknown quantity at this point
Send a message via MSN to jayme
I find it a little bit hard you have very little knowledge of networks but you're trying to program network programs.

127.0.0.1 is an ip address that just relays the connection you try to make back to your very own(the person who runs the program) computer, which will tell you there's no connection because I don't have the server. That is of course if you're using the addr.txt to grab the ip address of your server. If it's hardcoded then disregard this post, but either way I wasn't able to connect.
__________________

Quote:
Originally Posted by Mohamed Jihad
Durka durka!
Due to incorrect calculations during the middle ages, our calendar actually begins a few years after Jesus' birth. Thus the real 6/6/6 happened a few years back. The world already ended and you missed it.

Download Code::Blocks now!
jayme is offline   Reply With Quote
Old Jun 9th, 2006, 5:56 PM   #3
splinter9x
Hobbyist Programmer
 
splinter9x's Avatar
 
Join Date: Jun 2006
Posts: 137
Rep Power: 0 splinter9x is an unknown quantity at this point
I think you need to include the server in the download file. All you put up for download is the client...
__________________
Visit my Blog
I support WINDOWS...
splinter9x is offline   Reply With Quote
Old Jun 9th, 2006, 6:10 PM   #4
Brent
Highly Adaptive Penguin
 
Brent's Avatar
 
Join Date: May 2005
Location: United States
Posts: 251
Rep Power: 4 Brent is on a distinguished road
as I stated above, this application is both a client and a server.
Brent is offline   Reply With Quote
Old Jun 9th, 2006, 6:11 PM   #5
Brent
Highly Adaptive Penguin
 
Brent's Avatar
 
Join Date: May 2005
Location: United States
Posts: 251
Rep Power: 4 Brent is on a distinguished road
@jayme

replace the IP in addr.txt with your machines IP. It works fine for me



here's how it works:

change the IP in addr.txt
open chiba and under options, click start server

now on a different computer

change the IP to the IP of the server
click connect, and with any luck it should say.."connected to chat server"
Brent is offline   Reply With Quote
Old Jun 9th, 2006, 6:15 PM   #6
jayme
Professional Programmer
 
jayme's Avatar
 
Join Date: Nov 2005
Location: Canada
Posts: 495
Rep Power: 0 jayme is an unknown quantity at this point
Send a message via MSN to jayme
Alright, works fine. Multi-threading might be a bit much for this. Why not use select()ing sockets or windows messages?
__________________

Quote:
Originally Posted by Mohamed Jihad
Durka durka!
Due to incorrect calculations during the middle ages, our calendar actually begins a few years after Jesus' birth. Thus the real 6/6/6 happened a few years back. The world already ended and you missed it.

Download Code::Blocks now!
jayme is offline   Reply With Quote
Old Jun 9th, 2006, 6:22 PM   #7
Brent
Highly Adaptive Penguin
 
Brent's Avatar
 
Join Date: May 2005
Location: United States
Posts: 251
Rep Power: 4 Brent is on a distinguished road
Its already configured to use select(), but still needs some work, although I think windows messages would work alot better considering its using winsock.
Brent is offline   Reply With Quote
Old Jun 9th, 2006, 6:23 PM   #8
splinter9x
Hobbyist Programmer
 
splinter9x's Avatar
 
Join Date: Jun 2006
Posts: 137
Rep Power: 0 splinter9x is an unknown quantity at this point
Still doesn't work for me, even after I changed the IP I still get a error and can't connect...
__________________
Visit my Blog
I support WINDOWS...
splinter9x is offline   Reply With Quote
Old Jun 9th, 2006, 6:23 PM   #9
jayme
Professional Programmer
 
jayme's Avatar
 
Join Date: Nov 2005
Location: Canada
Posts: 495
Rep Power: 0 jayme is an unknown quantity at this point
Send a message via MSN to jayme
I noticed.

Keep this thread up to date. I would like to see how far this goes.

Quote:
Originally Posted by splinter9x
Still doesn't work for me, even after I changed the IP I still get a error and can't connect...
Are you going into the options tab and starting the server before you attempt to connect?
__________________

Quote:
Originally Posted by Mohamed Jihad
Durka durka!
Due to incorrect calculations during the middle ages, our calendar actually begins a few years after Jesus' birth. Thus the real 6/6/6 happened a few years back. The world already ended and you missed it.

Download Code::Blocks now!
jayme is offline   Reply With Quote
Old Jun 9th, 2006, 6:29 PM   #10
Brent
Highly Adaptive Penguin
 
Brent's Avatar
 
Join Date: May 2005
Location: United States
Posts: 251
Rep Power: 4 Brent is on a distinguished road
splinter, change the ip address to the ip of your computer, you can just use localhost
Brent is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 4:25 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC