Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > add html fragment (and controls) to control tree

Reply
Thread Tools

add html fragment (and controls) to control tree

 
 
Terry V
Guest
Posts: n/a
 
      08-25-2004
Thanks for any help...

I have a user control which includes among other controls an htmlholder.

At runtime I pick up an html fragment from a web service (not mine) that
looks like <form ... /form>. Within the fragment could be any controls but at
the moment I am just working with an html input text and submit.

I take the fragment (process it for some information) and then assign it to
a literalcontrol that is added to the htmlholder.controls collection.

The fragment is rendered just fine and any controls such as hyperlinks
function properly when clicked.

My problem is that when an htmlinput submit is clicked, causing a postback,
I need to inspect the control tree to see the value of the htmlinput text,
and then pass it back to the web service to be processed.

I'm recreating the html fragment on postback during the Page_Init. But the
controls are not in the control tree when I look for them after page_load, in
the pre_render.

I suspect that I should not use the literalcontrol for this process but am
unsure of where to go. Even if I assign the html fragment to another control
that might render it, how do I get the html converted into the controls and
added to the control tree? Am I going to have to read the fragment, check for
tags and add each control as I come across it? Is there something out there
that will that would do this - like an htmltextreader? Or can someone suggest
a good abstraction so I don't have to know what each control is to get it and
it's properties into the control tree?

This should be fun!
--
TIA,
Terry
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Tree fragment between two tags? Jongware XML 2 06-07-2010 03:15 PM
Adding an XML fragment as a child node in a pre-existing Element tree Rajarshi Python 1 02-11-2007 07:18 PM
test for an empty result tree fragment Andy Fish XML 1 02-08-2007 02:49 PM
Fragment Caching w/Menu control not working Ben Fidge ASP .Net 0 07-05-2006 05:12 PM
B tree, B+ tree and B* tree Stub C Programming 3 11-12-2003 01:51 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57