Solved

How can I get the html from an asp.net panel control?

Posted on 2009-04-10
2
295 Views
Last Modified: 2012-05-06
Hello.  I have many different panels in a website where I sometimes need to send the contents of the currently displayed panel in an email.  

I've tried many solutions, some of which work, but all of which so far have unacceptable consequences, so I have some additional requirements.
*The panel "MUST" have textboxes, radio buttons, hiddenfields, and other web user controls that require viewstate.  I tried a solution that dynamically went through and switched each web user control to an equivelent html control, but unfortunately it changed the source panel too!  Which goes to my next requirement.
*After the function is done, the source panel should be unaffected! Or at the very least reverted to the same as it started.  Almost all solutions I've seen so far change the source panel because its a reference type. :(

 
0
Comment
Question by:dguillen
2 Comments
 
LVL 12

Accepted Solution

by:
williamcampbell earned 500 total points
ID: 24116905
Probably need to intercept the Rendering pipe...

Possible Solution here

http://dotnettricks.com/blogs/craigbowesblog/archive/2006/09/09/105.aspx


0
 
LVL 1

Author Closing Comment

by:dguillen
ID: 31568962
Ok, that post describes all of my frustration for the past day, perfect.  It would have been really nice to not have to turn off event validation, but this works fulfilling all of my requirements, thank you.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now