Click here to Skip to main content
15,888,113 members
Home / Discussions / C#
   

C#

 
GeneralRe: Wave files Pin
OriginalGriff5-Aug-10 2:24
mveOriginalGriff5-Aug-10 2:24 
AnswerRe: Wave files Pin
Luc Pattyn5-Aug-10 2:41
sitebuilderLuc Pattyn5-Aug-10 2:41 
GeneralRe: Wave files Pin
V.5-Aug-10 3:07
professionalV.5-Aug-10 3:07 
GeneralRe: Wave files [modified] Pin
Luc Pattyn5-Aug-10 3:29
sitebuilderLuc Pattyn5-Aug-10 3:29 
GeneralRe: Wave files Pin
DaveyM695-Aug-10 3:47
professionalDaveyM695-Aug-10 3:47 
GeneralRe: Wave files Pin
Luc Pattyn5-Aug-10 3:58
sitebuilderLuc Pattyn5-Aug-10 3:58 
GeneralRe: Wave files Pin
V.5-Aug-10 21:04
professionalV.5-Aug-10 21:04 
QuestionSocket Connection Pin
Agweet4-Aug-10 22:46
Agweet4-Aug-10 22:46 
Hi All,

i am trying to create a socket connection to a server and send it a XML string and receive the results.

For some reason it does not work, here is my code:

XML String: <?xml version="1.0" encoding="UTF-8" standalone="yes"? <MemberLookupRequest><Code>XXX</Code><idNumber>XXXXXXXXXXXXX</idNumber></MemberLookupRequest>

and my socket connection code:

try
{
TcpClient socketForServer;
socketForServer = new TcpClient(xxx.xxx.xxx.xxx, 6000);

socketForServer.SendTimeout = 300000;
socketForServer.ReceiveTimeout = 300000;

NetworkStream networkStream = socketForServer.GetStream();
System.IO.StreamReader streamReader =
new System.IO.StreamReader(networkStream);
System.IO.StreamWriter streamWriter =
new System.IO.StreamWriter(networkStream);
string outputString;
// read the data from the host and display it

streamWriter.WriteLine(XML String goes here);

streamWriter.Flush();


outputString = streamReader.ReadToEnd();

networkStream.Close();

return outputString;
}
catch (Exception ex)
{
return ex.Message.ToString();
}


it shows that i am connected to the server but i don't get any results back.

can anyone please help me with this?

thanks in advance!

living life on the flip side
AnswerRe: Socket Connection Pin
freakyit5-Aug-10 1:54
freakyit5-Aug-10 1:54 
AnswerRe: Socket Connection Pin
Ennis Ray Lynch, Jr.5-Aug-10 2:27
Ennis Ray Lynch, Jr.5-Aug-10 2:27 
AnswerRe: Socket Connection Pin
Member 7906565-Aug-10 2:28
Member 7906565-Aug-10 2:28 
GeneralRe: Socket Connection Pin
Agweet5-Aug-10 3:58
Agweet5-Aug-10 3:58 
QuestionHow to Call a Server side Function on the Client side Pin
Vimalsoft(Pty) Ltd4-Aug-10 22:04
professionalVimalsoft(Pty) Ltd4-Aug-10 22:04 
AnswerRe: How to Call a Server side Function on the Client side Pin
Prosanta Kundu online4-Aug-10 22:40
Prosanta Kundu online4-Aug-10 22:40 
GeneralRe: How to Call a Server side Function on the Client side Pin
Vimalsoft(Pty) Ltd4-Aug-10 23:52
professionalVimalsoft(Pty) Ltd4-Aug-10 23:52 
GeneralRe: How to Call a Server side Function on the Client side Pin
Pete O'Hanlon5-Aug-10 0:07
mvePete O'Hanlon5-Aug-10 0:07 
GeneralRe: How to Call a Server side Function on the Client side Pin
Vimalsoft(Pty) Ltd5-Aug-10 0:16
professionalVimalsoft(Pty) Ltd5-Aug-10 0:16 
GeneralRe: How to Call a Server side Function on the Client side Pin
Pete O'Hanlon5-Aug-10 1:31
mvePete O'Hanlon5-Aug-10 1:31 
GeneralRe: How to Call a Server side Function on the Client side Pin
Vimalsoft(Pty) Ltd5-Aug-10 20:16
professionalVimalsoft(Pty) Ltd5-Aug-10 20:16 
GeneralRe: How to Call a Server side Function on the Client side Pin
Vimalsoft(Pty) Ltd6-Aug-10 22:07
professionalVimalsoft(Pty) Ltd6-Aug-10 22:07 
QuestionCant find BannerBitmap property ( win form setup creation ) Pin
Krishna Varadharajan4-Aug-10 21:55
Krishna Varadharajan4-Aug-10 21:55 
AnswerRe: Cant find BannerBitmap property ( win form setup creation ) Pin
freakyit5-Aug-10 1:56
freakyit5-Aug-10 1:56 
AnswerRe: Cant find BannerBitmap property ( win form setup creation ) Pin
GenJerDan5-Aug-10 8:33
GenJerDan5-Aug-10 8:33 
QuestionHow do I include textbox data in SQL query? Pin
Joe Stansfield4-Aug-10 20:44
Joe Stansfield4-Aug-10 20:44 
AnswerRe: How do I include textbox data in SQL query? Pin
JHizzle4-Aug-10 21:55
JHizzle4-Aug-10 21:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.