HighTechTalks DotNet Forums  

Best practice for outputing XML Data from server

ASP.net Security microsoft.public.dotnet.framework.aspnet.security


Discuss Best practice for outputing XML Data from server in the ASP.net Security forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
NickP
 
Posts: n/a

Default Best practice for outputing XML Data from server - 11-27-2007 , 10:36 AM






Hey there,

I have a web service that returns a load of XML data which I wish to layout
on a web page. I am not 100% certain of the best practice for doing this.
One way I presumed that I could do this was by handling the Page_Load event
of the web form, but unfortunately I do not seem to be able to do this as I
just recieve a compile error,

"Warning 156 sub 'Page_Load' shadows an overloadable member declared in the
base class 'History'. If you want to overload the base method, this method
must be declared 'Overloads'. ...\history.aspx 21 19 ..."

If I overload the function it simply does not get called. I would like the
data to be fetched each time the page is initiated, so I also tried
overriding the LoadViewState method but this does not seem to get called
either.

I think I may layout my XML data using XSLT but am not compeltely decided
yet. Any advice would be most appreciative.

TIA.

Nick.



Reply With Quote
  #2  
Old   
NickP
 
Posts: n/a

Default Re: Best practice for outputing XML Data from server - 11-27-2007 , 11:00 AM






Just an update that I have the data being obtained from the service now
within the OnInit event of the page so now I just have to output it,
although i am not 100% certain on how I would do this. I have done it
JAVAScript fine, but not with asp.net.

I'm guessing the best way that I can do this is to create a user control and
pass the xml to the user control which would then perform an XML
transformation upon the data. How would one achieve this?

TIA.

Nick.

"NickP" <a@a.com> wrote

Quote:
Hey there,

I have a web service that returns a load of XML data which I wish to
layout on a web page. I am not 100% certain of the best practice for
doing this. One way I presumed that I could do this was by handling the
Page_Load event of the web form, but unfortunately I do not seem to be
able to do this as I just recieve a compile error,

"Warning 156 sub 'Page_Load' shadows an overloadable member declared in
the base class 'History'. If you want to overload the base method, this
method must be declared 'Overloads'. ...\history.aspx 21 19 ..."

If I overload the function it simply does not get called. I would like
the data to be fetched each time the page is initiated, so I also tried
overriding the LoadViewState method but this does not seem to get called
either.

I think I may layout my XML data using XSLT but am not compeltely decided
yet. Any advice would be most appreciative.

TIA.

Nick.





Reply With Quote
  #3  
Old   
NickP
 
Posts: n/a

Default Re: Best practice for outputing XML Data from server - 11-27-2007 , 11:31 AM



I think I have it now, I am using the XML control and setting the
TransformSource property to the xsl file, and putting the xml data into
DocumentContent. It is transforming successfully onto my page now, so
that's fantastic

Nick.

"NickP" <a@a.com> wrote

Quote:
Just an update that I have the data being obtained from the service now
within the OnInit event of the page so now I just have to output it,
although i am not 100% certain on how I would do this. I have done it
JAVAScript fine, but not with asp.net.

I'm guessing the best way that I can do this is to create a user control
and pass the xml to the user control which would then perform an XML
transformation upon the data. How would one achieve this?

TIA.

Nick.

"NickP" <a@a.com> wrote in message
news:OcWKnORMIHA.5208 (AT) TK2MSFTNGP04 (DOT) phx.gbl...
Hey there,

I have a web service that returns a load of XML data which I wish to
layout on a web page. I am not 100% certain of the best practice for
doing this. One way I presumed that I could do this was by handling the
Page_Load event of the web form, but unfortunately I do not seem to be
able to do this as I just recieve a compile error,

"Warning 156 sub 'Page_Load' shadows an overloadable member declared in
the base class 'History'. If you want to overload the base method, this
method must be declared 'Overloads'. ...\history.aspx 21 19 ..."

If I overload the function it simply does not get called. I would like
the data to be fetched each time the page is initiated, so I also tried
overriding the LoadViewState method but this does not seem to get called
either.

I think I may layout my XML data using XSLT but am not compeltely decided
yet. Any advice would be most appreciative.

TIA.

Nick.







Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.