473,406 Members | 2,312 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Getting the entire document from response.

I am writing a module that requires the entire output from a web app
to perform its function. So, basically I need to be able to pull the
entire output stream from the Response object. I've tried attaching a
custom filter to Response.Filter, but the custom filter receives the
stream in separate chunks. I need the entire stream at once in order
to convert it to an XmlDocument. Does anyone know of a way to get the
entire output stream from a web app using a module?

Jun 20 '07 #1
1 1173
On Jun 20, 9:54 am, Josh Naro <joshn...@gmail.comwrote:
I am writing a module that requires the entire output from a web app
to perform its function. So, basically I need to be able to pull the
entire output stream from the Response object. I've tried attaching a
custom filter to Response.Filter, but the custom filter receives the
stream in separate chunks. I need the entire stream at once in order
to convert it to an XmlDocument. Does anyone know of a way to get the
entire output stream from a web app using a module?
Well, I managed to figure this one out myself.

Answer:
1. Create a custom filter that makes use of the singleton pattern.
2. Have the filter store each stream as it comes through in a public
variable (i.e. temp += currentStream).
3. Install the filter on BeginRequest of the application from within
a module.
4. Grab your filter on EndRequest of the application from within the
module.
5. Your singleton filter should now have the entire output of the
application in its temp variable.

Jun 20 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Michael Hill | last post by:
If I had a span tag like: <span id='msg_2'> There is a bunch of text <a href="http://www.someurl.com"> here </a>. And some others <a href="http://www.otherurl.com">here</a>. Good luck! </span>...
5
by: s_m_b | last post by:
function saveState() { document.write (" | <a href = 'myhomepage.asp? view=mhp&amp;action=save&amp;pb="); >> document.write (document.phone.style.display.value); document.write ("'>save view</a>"); };...
4
by: R.Manikandan | last post by:
Hi In my code, one string variable is subjected to contain more amount of characters. If it cross certain limit, the string content in the varabile is automatically getting truncated and i am...
1
by: kamleshsharmadts | last post by:
I am using Ajax with struts in web application. from jsp i am calling a function of ajax.js onclick of a button. code of that call function which calling from jsp given as below:- ...
10
by: Paul H | last post by:
I am trying to get the spec for a database. The trouble is the client frequently blurts out industry jargon, speaks insanely quickly and is easily sidetracked. They are currently using around 30...
11
by: Frank Rizzo | last post by:
I have a WebBrowser control on a .net 2.0 winforms app. I load up a page and want to get the selected entry of a dropdown. I can get the element: HtmlElement stationList =...
2
by: Josh Naro | last post by:
I am writing a module that requires the entire output from a web app to perform its function. So, basically I need to be able to pull the entire output stream from the Response object. I've tried...
1
by: raghuvendra | last post by:
Hi I have a jsp page with 4 columns: namely Category name , Category order, Input field and a submit button. All these are aligned in a row. And Each Category Name has its corresponding Category...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
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,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
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...
0
agi2029
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,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.