J
John Dalberg
I am trying to send a webpage with datagrids as an email so I use the code
snippet below. In one of my datagrids, I reformat some rows in the
datagrid's Prerender event. The code behind of the page displays the page
and sends the email. The page displays fine however the email has the same
look and everything *except* the changes that were made in the grid's
prerender. I think I am missing something and was wondering why the changes
were lost. I am thinking it's a timing issue. How can I get
Page.RenderControl() to execute the prerender event, wait till it's done
and continue to the next statement.
Code sample:
sw = new StringWriter();
htw = new HtmlTextWriter(sw);
Page.RenderControl(htw);
snippet below. In one of my datagrids, I reformat some rows in the
datagrid's Prerender event. The code behind of the page displays the page
and sends the email. The page displays fine however the email has the same
look and everything *except* the changes that were made in the grid's
prerender. I think I am missing something and was wondering why the changes
were lost. I am thinking it's a timing issue. How can I get
Page.RenderControl() to execute the prerender event, wait till it's done
and continue to the next statement.
Code sample:
sw = new StringWriter();
htw = new HtmlTextWriter(sw);
Page.RenderControl(htw);