473,386 Members | 1,886 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

XML Feed Dotnet

Hi Guys,

hopefully someone can help me with an issue. I have recenlty linked to
third party to receive data in XML format which i then want to display
on my site. The provider supplies a large amount of data which i want
to be able to search on the various fields using a web form (drop downs
etc) i then want to display the appropriate results of the search in a
datagrid. i need to search on price (greater than and less than) and
on a free text search

I have the part where i populate the dataset but how do i search within
a dataset ???? is this even possible ?? An idea was to populate my
database table with the data but i would have to do this every time and
therefore this would slow down my application.

any hints, tips or advice greatly appreciated.

Regards,

CG

Mar 1 '06 #1
4 1477
Hi CG,

Once you've got the data in a dataset, use the DataView's RowFilter property
to filter down to the parts you want. You just create an expression that
acts somewhat like a SQL query of the datatable.

dv.RowFilter = "City = 'Berlin'"
http://msdn.microsoft.com/library/de...iltertopic.asp

http://msdn.microsoft.com/library/de...tviewtopic.asp

Ken
Microsoft MVP [ASP.NET]
"csgraham74" <cs********@gmail.com> wrote in message
news:11*********************@e56g2000cwe.googlegro ups.com...
Hi Guys,

hopefully someone can help me with an issue. I have recenlty linked to
third party to receive data in XML format which i then want to display
on my site. The provider supplies a large amount of data which i want
to be able to search on the various fields using a web form (drop downs
etc) i then want to display the appropriate results of the search in a
datagrid. i need to search on price (greater than and less than) and
on a free text search

I have the part where i populate the dataset but how do i search within
a dataset ???? is this even possible ?? An idea was to populate my
database table with the data but i would have to do this every time and
therefore this would slow down my application.

any hints, tips or advice greatly appreciated.

Regards,

CG

Mar 1 '06 #2
Thanks Ken that was helpful,

im currently using the following code to populate my dataset.

If Cache("cch_Dataset") Is Nothing Then
xmlFeed =
DirectCast(WebRequest.Create("http://www.anylink.com"), HttpWebRequest)
xmlData = New DataSet
xmlData.ReadXml(xmlFeed.GetResponse().GetResponseS tream())
Cache("cch_Dataset") = xmlData
Response.Write("<img name=IMAGE
src=http://www.anylink.com//" &
Trim(xmlData.Tables(0).Rows(0).Item("i1") & " width=120 height=76
border=0>"))

Response.Write(Trim(xmlData.Tables(0).Rows(0).Item ("textdetail")))
End If

there is a time lag of between 10 - 15 seconds before the data is
pulled in and displayed on the load event, other sites that use the
same third party dont appear to have any time lag. is this the best
way to do it ????

what other options do i have - i think other sites do it almost
instantly.
Any help appreciated.

Cg
Ken Cox - Microsoft MVP wrote:
Hi CG,

Once you've got the data in a dataset, use the DataView's RowFilter property
to filter down to the parts you want. You just create an expression that
acts somewhat like a SQL query of the datatable.

dv.RowFilter = "City = 'Berlin'"
http://msdn.microsoft.com/library/de...iltertopic.asp

http://msdn.microsoft.com/library/de...tviewtopic.asp

Ken
Microsoft MVP [ASP.NET]
"csgraham74" <cs********@gmail.com> wrote in message
news:11*********************@e56g2000cwe.googlegro ups.com...
Hi Guys,

hopefully someone can help me with an issue. I have recenlty linked to
third party to receive data in XML format which i then want to display
on my site. The provider supplies a large amount of data which i want
to be able to search on the various fields using a web form (drop downs
etc) i then want to display the appropriate results of the search in a
datagrid. i need to search on price (greater than and less than) and
on a free text search

I have the part where i populate the dataset but how do i search within
a dataset ???? is this even possible ?? An idea was to populate my
database table with the data but i would have to do this every time and
therefore this would slow down my application.

any hints, tips or advice greatly appreciated.

Regards,

CG


Mar 6 '06 #3
Hi CG,

That doesn't look like a very efficient way of getting the XML data but it
is hard to tell from the snippet what you're received and from where.

What does the XML look like that you're using?

You might be better off using an XQuery to pick out the part(s) you want.

Ken
Microsoft MVP [ASP.NET]

"csgraham74" <cs********@gmail.com> wrote in message
news:11*********************@j33g2000cwa.googlegro ups.com...
Thanks Ken that was helpful,

im currently using the following code to populate my dataset.

If Cache("cch_Dataset") Is Nothing Then
xmlFeed =
DirectCast(WebRequest.Create("http://www.anylink.com"), HttpWebRequest)
xmlData = New DataSet
xmlData.ReadXml(xmlFeed.GetResponse().GetResponseS tream())
Cache("cch_Dataset") = xmlData
Response.Write("<img name=IMAGE
src=http://www.anylink.com//" &
Trim(xmlData.Tables(0).Rows(0).Item("i1") & " width=120 height=76
border=0>"))

Response.Write(Trim(xmlData.Tables(0).Rows(0).Item ("textdetail")))
End If

there is a time lag of between 10 - 15 seconds before the data is
pulled in and displayed on the load event, other sites that use the
same third party dont appear to have any time lag. is this the best
way to do it ????

what other options do i have - i think other sites do it almost
instantly.
Any help appreciated.

Cg
Ken Cox - Microsoft MVP wrote:
Hi CG,

Once you've got the data in a dataset, use the DataView's RowFilter
property
to filter down to the parts you want. You just create an expression that
acts somewhat like a SQL query of the datatable.

dv.RowFilter = "City = 'Berlin'"
http://msdn.microsoft.com/library/de...iltertopic.asp

http://msdn.microsoft.com/library/de...tviewtopic.asp

Ken
Microsoft MVP [ASP.NET]
"csgraham74" <cs********@gmail.com> wrote in message
news:11*********************@e56g2000cwe.googlegro ups.com...
> Hi Guys,
>
> hopefully someone can help me with an issue. I have recenlty linked to
> third party to receive data in XML format which i then want to display
> on my site. The provider supplies a large amount of data which i want
> to be able to search on the various fields using a web form (drop downs
> etc) i then want to display the appropriate results of the search in a
> datagrid. i need to search on price (greater than and less than) and
> on a free text search
>
> I have the part where i populate the dataset but how do i search within
> a dataset ???? is this even possible ?? An idea was to populate my
> database table with the data but i would have to do this every time and
> therefore this would slow down my application.
>
> any hints, tips or advice greatly appreciated.
>
> Regards,
>
> CG
>

Mar 7 '06 #4
Thanks Ken,

I didnt think it was very efficient either but i have no experinece of
this type transfer.

I was looking into XQuery lat night but didnt get very far with it
mainly due to tiredness.

In terms of a search form do i then write my xQuery code then return
that data and populate my dataset that way?? is the best way to
transfer the data by using the GetResponseStream - is this efficient ??

by the way are there any good tutorials on XQuery ???
thanks for all ur help

C
Ken Cox - Microsoft MVP wrote:
Hi CG,

That doesn't look like a very efficient way of getting the XML data but it
is hard to tell from the snippet what you're received and from where.

What does the XML look like that you're using?

You might be better off using an XQuery to pick out the part(s) you want.

Ken
Microsoft MVP [ASP.NET]

"csgraham74" <cs********@gmail.com> wrote in message
news:11*********************@j33g2000cwa.googlegro ups.com...
Thanks Ken that was helpful,

im currently using the following code to populate my dataset.

If Cache("cch_Dataset") Is Nothing Then
xmlFeed =
DirectCast(WebRequest.Create("http://www.anylink.com"), HttpWebRequest)
xmlData = New DataSet
xmlData.ReadXml(xmlFeed.GetResponse().GetResponseS tream())
Cache("cch_Dataset") = xmlData
Response.Write("<img name=IMAGE
src=http://www.anylink.com//" &
Trim(xmlData.Tables(0).Rows(0).Item("i1") & " width=120 height=76
border=0>"))

Response.Write(Trim(xmlData.Tables(0).Rows(0).Item ("textdetail")))
End If

there is a time lag of between 10 - 15 seconds before the data is
pulled in and displayed on the load event, other sites that use the
same third party dont appear to have any time lag. is this the best
way to do it ????

what other options do i have - i think other sites do it almost
instantly.
Any help appreciated.

Cg
Ken Cox - Microsoft MVP wrote:
Hi CG,

Once you've got the data in a dataset, use the DataView's RowFilter
property
to filter down to the parts you want. You just create an expression that
acts somewhat like a SQL query of the datatable.

dv.RowFilter = "City = 'Berlin'"
http://msdn.microsoft.com/library/de...iltertopic.asp

http://msdn.microsoft.com/library/de...tviewtopic.asp

Ken
Microsoft MVP [ASP.NET]
"csgraham74" <cs********@gmail.com> wrote in message
news:11*********************@e56g2000cwe.googlegro ups.com...
> Hi Guys,
>
> hopefully someone can help me with an issue. I have recenlty linked to
> third party to receive data in XML format which i then want to display
> on my site. The provider supplies a large amount of data which i want
> to be able to search on the various fields using a web form (drop downs
> etc) i then want to display the appropriate results of the search in a
> datagrid. i need to search on price (greater than and less than) and
> on a free text search
>
> I have the part where i populate the dataset but how do i search within
> a dataset ???? is this even possible ?? An idea was to populate my
> database table with the data but i would have to do this every time and
> therefore this would slow down my application.
>
> any hints, tips or advice greatly appreciated.
>
> Regards,
>
> CG
>


Mar 7 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Shaqman | last post by:
Can anybody point me for some samples in displaying RSS (XML) news feed on a asp.net page. Any help will be apreciated
2
by: Brad Sanders | last post by:
Hello All, Thanks to Richard's answer to my last post I understand now what I have to do, but.. How do I put a Line Feed or a Form Feed into a text file? Looking throught the .net help it...
2
by: LIN | last post by:
I am trying to parse a log file which is created by an Apache Web Server - I am not sure what do you use to read the Line Feed - example for most of the other files i use "\n" but i am not sure...
1
by: Sukh | last post by:
Hello anyone, I am printing a pre-printed continue paper on dot-matrix printer using vb.net winform. For printing I am creating custom size paper and selecting the same for printing. Everything...
6
by: affiliateian | last post by:
Total newbie here for this so please be patient. We manually update our XML feed when we publish an article on our website. Can we add a javascript tracking pixel (from phpadsnew) into the XML...
2
by: MDB | last post by:
Hello All, I am very unfimilar with RSS feeds and figure it can not be that difucult however, am having one heck of a time figuring it out. I have been giving a link to an RSS reed that I have...
4
by: Florian Lindner | last post by:
Hello, I'm looking for python RSS feed parser library. Feedparser http://feedparser.org/ does not seem to maintained anymore. What alternatives are recommendable? Thanks, Florian
4
by: Blake Garner | last post by:
I'm looking for suggestions on how to approach generating rss feed ..xml files using python. What modules to people recommend I start with? Thanks! Blake
4
by: David Thielen | last post by:
Hi; This is for a website that is just html pages, no ASP.NET. I want the default page to be a different page if it's a mobile device. I can do this in ASP.NET by looking at the browser size and...
2
jamwil
by: jamwil | last post by:
What's up guys. I'm having some issues... I've created a method as part of my lifestreaming class which takes an rss feed, and puts the data into a database... It's fairly simple... Check...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.