943,708 Members | Top Members by Rank

Ad:
  • C# Discussion Thread
  • Unsolved
  • Views: 1093
  • C# RSS
Apr 30th, 2008
0

refernce website code

Expand Post »
I am very new to programing and C#. I understand a few of the basics but I am willing to spend many hours to work with and learn making silly programs that are of a little use to me. I am wondering what I would use to get a small amount of information from a web site and work with the data. I also must log into this website to get the information. Could someone point me in the right direction?
For instance if I wanted to get a price for a specific item off Amazon how would I do it?
Reputation Points: 10
Solved Threads: 0
Newbie Poster
constrainer is offline Offline
7 posts
since Apr 2008
Apr 30th, 2008
0

Re: refernce website code

Amazon publishes an API. For that example, I'd use the Amazon API in my project.

"Getting information from a web site" is much too general of a question. Web sites are built to be accessed by human users, in most cases, not applications.

There are exceptions, such as RSS feeds and Web Services.
Team Colleague
Reputation Points: 227
Solved Threads: 37
Made Her Cry
tgreer is offline Offline
1,697 posts
since Dec 2004
May 1st, 2008
0

Re: refernce website code

Oh and I guess Amazon was a bad example. The websites I am trying to get prices from are just basic and don't use API I don't think.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
constrainer is offline Offline
7 posts
since Apr 2008
May 1st, 2008
0

Re: refernce website code

You want to design an application that mimics a human user, fills out an online form, and processes the resultant HTML? Why? That's a bit of a challenge, and not how most eCommerce applications work. Even the sites like PriceGrabber require that their vendors export their pricing data to them or provide it via Web Services.

If you really want to pursue this idea, you might start by doing a web search on "screen scraper".
Team Colleague
Reputation Points: 227
Solved Threads: 37
Made Her Cry
tgreer is offline Offline
1,697 posts
since Dec 2004
May 1st, 2008
0

Re: refernce website code

Thank for the key word. Sorry I guess I am being a bit unclear. A website displays a differing price for a bike each day. I just want to get that price with my application then add some local shipping ect to it. Its the getting from the web page I am clueless on how to go about. I will look up screen scraper now.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
constrainer is offline Offline
7 posts
since Apr 2008
May 1st, 2008
0

Re: refernce website code

Hmm the wiki article is interesting. I am not sure I need to use a screen scraper as that seems far beyond what I am trying to accomplish. Is there any way to parse HTML code online? Could I use a connection string and a data reader to read source code online?
Reputation Points: 10
Solved Threads: 0
Newbie Poster
constrainer is offline Offline
7 posts
since Apr 2008
May 2nd, 2008
0

Re: refernce website code

I still maintain your initial approach is wrong. Parsing each other's HTML is not how eCommerce applications behave. But if you want to doggedly press on, then your next web search should be "C# HTML DOM".
Team Colleague
Reputation Points: 227
Solved Threads: 37
Made Her Cry
tgreer is offline Offline
1,697 posts
since Dec 2004
May 6th, 2008
0

Re: refernce website code

I don't mean to be hard headed I just am ignorant of these things. Couldn't I use javascript to goto the website and view/get/download the source code and use a StreamWriter/Reader to go through and then use an array to pull out the few digits I need?
Last edited by constrainer; May 6th, 2008 at 8:51 pm.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
constrainer is offline Offline
7 posts
since Apr 2008
May 7th, 2008
0

Re: refernce website code

I'd look at the c# webrequest & webresponse objects in System.Net
Reputation Points: 10
Solved Threads: 1
Newbie Poster
ckaneta is offline Offline
6 posts
since May 2006
May 7th, 2008
0

Re: refernce website code

Thanks!
Reputation Points: 10
Solved Threads: 0
Newbie Poster
constrainer is offline Offline
7 posts
since Apr 2008

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C# Forum Timeline: How to get a datarow from a datable in C#?
Next Thread in C# Forum Timeline: Listbox





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC