Hi Guys.
I have a problem, and for some reason I have not been able to find an
answer on the net.
In a nutshell, I have some codes on my page, which I want to change to
an appropriate string (from a hashtable). Since I do not want to pass
this hashtable to a function all the time I encounter it on the page, I
want to do it once, in one function. Just capture HTML before rendering
the page, and then replace codes with my strings.
Any ideas would be appreciated.
Alex 2 1567
The Render event builds the page by assembling the HTML for output to the
browser. The page collects the HTML from each control in the hierarchy for
delivery. When the Render event is overridden, you can write custom HTML to
the browser that changes all or part of the HTML the page has created thus
far.It takes an HtmlTextWriter object as a parameter and uses that to output
HTML to be streamed to the browser. Changes can still be made at this point.
If you have your "codes" in certain controls on the page, it would probably
be a lot easier to modify these based on your Hashtable either in PreRender,
or you can even do it in Page_Load.
Peter
--
Co-founder, Eggheadcafe.com developer portal: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
"gr*****@gmail. com" wrote: Hi Guys. I have a problem, and for some reason I have not been able to find an answer on the net. In a nutshell, I have some codes on my page, which I want to change to an appropriate string (from a hashtable). Since I do not want to pass this hashtable to a function all the time I encounter it on the page, I want to do it once, in one function. Just capture HTML before rendering the page, and then replace codes with my strings. Any ideas would be appreciated. Alex
Thanks, I think I have found the solution. It is partial, but with
amlittle work, it'll be good for all cases.
Thanks for the reply, though :) This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Vince C. |
last post by:
Hi all,
I've created XML documents that are described with a schema. I'm using those
documents to create web pages.
All my web pages contain a fixed header and a variable document part. The
header is the same in each page and is described in an XML document,
"Head.xml". The document part, which is variable in content, is described in...
|
by: Earl Teigrob |
last post by:
PROBLEM:
When a user control is loaded into a PlaceHolder control more than once, the
events do not fire on the first click of a control on the dynamically loaded
user control. In other words, the first time the control is dynamically
loaded, everything works fine. After that, if the control is loaded again
from the page button event handler,...
|
by: Ryan Taylor |
last post by:
Hi.
I have some code that dynamically generates a PDF and spits this content
directly to the web browser. I use HTMLDoc to create the Pdf's from html. So
the user can click on a button "Print PDF" and the current page magically
becomes a PDF file. This worked great until we moved the site to https. Now,
when the button is clicked, I get a...
|
by: Web Team |
last post by:
Hi All,
I'm in the process of writing a eich text editor web custom control.
The actual text/HTML is displayed/editied in a DIV layer, which I have
created like this:
output.Write("<span class=" & EditDivCSSClass & " id=" & Me.ID & " " &
strContentEditable & " wrap>" & _strText & "</span>")
|
by: tshad |
last post by:
Is there a way to dynamically add in User Controls where I would get the
name from a session variable:
If I have the following code:
******************************************************************************
<%@ Page Language="C#" trace="false" debug="true" ContentType="text/html"
ResponseEncoding="iso-8859-1" %>
<!DOCTYPE HTML PUBLIC...
| |
by: Ed Jay |
last post by:
I generate a DHTML page (a medical report) with dynamically generated text
based on user input (answers to questions). The page length changes
dynamically. I desire that when the page is printed and reaches a specific
length, it terminates printing that page, prints a page number, and then
begins to print the next page using the same header...
|
by: Petyr David |
last post by:
Current:
web page has hard coded directories (using checkboxes) user may choose
to search for files matching a pattern they enter in text box. Perl is
used to search for files and to format HTML output.
Desired:
dynamically created group of checkboxes upon opening web page. My
initial idea is to have user run separate Perl script to...
|
by: Merlin1857 |
last post by:
How to search multiple fields using ASP
A major issue for me when I first started writing in VB Script was constructing the ability to search a table using multiple field input from a form and having the sql statement dynamically built according to the input provided by the user. I have used the method described here hundreds of times it is...
|
by: Aaron Fude |
last post by:
Hi,
I have a webpage delivers, let's say, a pdf document. The page is
password protected so itially it shows HTML, but when the user logs in
the page is reloaded with "window.location.reload(true)", but
IExplorer is not smart enough to realize that the content type has
changed and just spits out pdf onto the screen. How does one fix that?
...
|
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
|
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it. ...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...
| |