|
-
Jun 13th, 2006, 09:44 PM
#1
Thread Starter
Junior Member
How to get info from a website?
im in this game called outwar.and i was wondering if someone could help me code a windows application in C# that can sort the 10 ppl with most money out..
please help me.
-
Jun 14th, 2006, 01:48 PM
#2
Re: How to get info from a website?
Sure. Use Sockets to connect to the remote server, then send an HTTP GET request to retrieve the page you want by supplying a relative URI, then parse the returned data stream using the same socket. Store the page in a string (or whatever) then use regular expressions to extract the relevant information from the raw HTML.
Any questions?
I don't live here any more.
-
Jun 16th, 2006, 02:22 PM
#3
Re: How to get info from a website?
You could also use HttpWebRequest to perform the Get/Post.
Although, how is it more efficient to open up an application to check the scores when you could just login to the website and check it?
-
Jun 16th, 2006, 06:10 PM
#4
Thread Starter
Junior Member
Re: How to get info from a website?
 Originally Posted by mendhak
You could also use HttpWebRequest to perform the Get/Post.
Although, how is it more efficient to open up an application to check the scores when you could just login to the website and check it?
I need a program that can sort the ppl with most money out..
can anyone help code it or code it to me`?
please contact me
-
Jun 17th, 2006, 07:46 AM
#5
Hyperactive Member
Re: How to get info from a website?
Wossname told you how to do it. Try researching all the things you didn't understand in his post.
-
Jun 17th, 2006, 08:05 AM
#6
PowerPoster
Re: How to get info from a website?
or if you want someone to code it for you - there will be a price as well
-
Jun 18th, 2006, 08:30 AM
#7
Re: How to get info from a website?
-
Jun 19th, 2006, 08:18 PM
#8
Thread Starter
Junior Member
Re: How to get info from a website?
I just need like more instructions..i dont want it coded by someone else,then i dont learn it(and whats the point then:P)
but if anyone could like give me some more instructions?
-
Jun 19th, 2006, 08:38 PM
#9
Thread Starter
Junior Member
Re: How to get info from a website?
this is an example from the "how do I"
// Synchronous connect using IPAddress to resolve the
// host name.
public static void Connect(string host, int port)
{
IPAddress[] IPs = Dns.GetHostAddresses(host);
Socket s = new Socket(AddressFamily.InterNetwork,
SocketType.Stream,
ProtocolType.Tcp);
Console.WriteLine("Establishing Connection to {0}", host);
s.Connect(IPs[0], port);
Console.WriteLine("Connection established");
}
how can i get it to work,lol
i get errors all the time..
please help
-
Jun 19th, 2006, 10:14 PM
#10
PowerPoster
Re: How to get info from a website?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|