All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling
Class. This Class would talk to a collection of Business Objects. The
various aspx pages would make calls to the Controlling Class which would, in
turn, make the necessary calls to the Business Objects. Depending on what
page you are on and the returns from the Business Objects, the Controlling
Class will navigate the user to the correct page.
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the
pages from the Controlling Class. From the Controlling Class I am unable to
Redirect the user to another page, because I can't even get a good reference
to the Response object.
All help is appreciated.
Thanks,
- Matt 8 1638
All -
I have found the answer:
HttpContext.Current.Response.Redirect
HttpContext.Currect will give you a link to the currect page.
Thanks,
- Matt
"Matthew Sajdera" <MS******@Cox.net> wrote in message
news:eb**************@TK2MSFTNGP12.phx.gbl... All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling Class. This Class would talk to a collection of Business Objects. The various aspx pages would make calls to the Controlling Class which would,
in turn, make the necessary calls to the Business Objects. Depending on what page you are on and the returns from the Business Objects, the Controlling Class will navigate the user to the correct page.
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the pages from the Controlling Class. From the Controlling Class I am unable
to Redirect the user to another page, because I can't even get a good
reference to the Response object.
All help is appreciated.
Thanks,
- Matt
All -
I have found the answer:
HttpContext.Current.Response.Redirect
HttpContext.Currect will give you a link to the currect page.
Thanks,
- Matt
"Matthew Sajdera" <MS******@Cox.net> wrote in message
news:eb**************@TK2MSFTNGP12.phx.gbl... All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling Class. This Class would talk to a collection of Business Objects. The various aspx pages would make calls to the Controlling Class which would,
in turn, make the necessary calls to the Business Objects. Depending on what page you are on and the returns from the Business Objects, the Controlling Class will navigate the user to the correct page.
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the pages from the Controlling Class. From the Controlling Class I am unable
to Redirect the user to another page, because I can't even get a good
reference to the Response object.
All help is appreciated.
Thanks,
- Matt
Matthew Sajdera wrote: All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling Class. This Class would talk to a collection of Business Objects. The various aspx pages would make calls to the Controlling Class which would, in turn, make the necessary calls to the Business Objects. Depending on what
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the pages from the Controlling Class. From the Controlling Class I am unable to
The quick answer is to use System.Web.HttpContext.Current.Response, etc.
which gets you a reference to the current HTTP context from any class
loaded in ASP.NET.
Looks like you're looking for a more-pure J2EE kind of MVC layout.
There's an example of a .NET app written to mock J2EE, I haven't looked
at it myself, but may have a design pattern for you to follow: http://www.gotdotnet.com/team/compare/petshop.aspx
--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET
Matthew Sajdera wrote: All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling Class. This Class would talk to a collection of Business Objects. The various aspx pages would make calls to the Controlling Class which would, in turn, make the necessary calls to the Business Objects. Depending on what
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the pages from the Controlling Class. From the Controlling Class I am unable to
The quick answer is to use System.Web.HttpContext.Current.Response, etc.
which gets you a reference to the current HTTP context from any class
loaded in ASP.NET.
Looks like you're looking for a more-pure J2EE kind of MVC layout.
There's an example of a .NET app written to mock J2EE, I haven't looked
at it myself, but may have a design pattern for you to follow: http://www.gotdotnet.com/team/compare/petshop.aspx
--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET
Craig Deelsnyder wrote: Matthew Sajdera wrote:
All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling Class. This Class would talk to a collection of Business Objects. The various aspx pages would make calls to the Controlling Class which would, in turn, make the necessary calls to the Business Objects. Depending on what
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the pages from the Controlling Class. From the Controlling Class I am unable to
The quick answer is to use System.Web.HttpContext.Current.Response, etc. which gets you a reference to the current HTTP context from any class loaded in ASP.NET.
Looks like you're looking for a more-pure J2EE kind of MVC layout. There's an example of a .NET app written to mock J2EE, I haven't looked at it myself, but may have a design pattern for you to follow:
http://www.gotdotnet.com/team/compare/petshop.aspx
I should say that this sample app's purpose was not to mock per se, it
was to create a comparable app for performance testing purposes. It may
or may not be modeled the same way.
--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET
Craig Deelsnyder wrote: Matthew Sajdera wrote:
All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling Class. This Class would talk to a collection of Business Objects. The various aspx pages would make calls to the Controlling Class which would, in turn, make the necessary calls to the Business Objects. Depending on what
Problem I'm having:
I cannot seem to figure out how I get a reference to the context of the pages from the Controlling Class. From the Controlling Class I am unable to
The quick answer is to use System.Web.HttpContext.Current.Response, etc. which gets you a reference to the current HTTP context from any class loaded in ASP.NET.
Looks like you're looking for a more-pure J2EE kind of MVC layout. There's an example of a .NET app written to mock J2EE, I haven't looked at it myself, but may have a design pattern for you to follow:
http://www.gotdotnet.com/team/compare/petshop.aspx
I should say that this sample app's purpose was not to mock per se, it
was to create a comparable app for performance testing purposes. It may
or may not be modeled the same way.
--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Martine |
last post by:
Hi there!
I have a problem with programmatically adding user controls to my
mobile webforms. If I load my usercontrol programmatically (in the
Page_Load), the object is instantiated, I have...
|
by: Paul R |
last post by:
Hi,
I have a Winforms application that access some SQLServer2000 stored
procedures.
I have now written some new Webforms pages to use some of the same stored
procs. The Webforms use the SAME...
|
by: Matthew Sajdera |
last post by:
All -
What I want to do:
I want to abstract the navigation between my aspx pages into a Controlling
Class. This Class would talk to a collection of Business Objects. The
various aspx pages...
|
by: |
last post by:
All the fields in webforms are automatically declared as protected.
If I change them to public, they are converted back to protected.
Why is this happening ?
Thanks
|
by: Billy Horne |
last post by:
Hi - I need to write a basic order page for our web site. It is very
straight-forward, in that we don't need a whole "shopping cart" system.
Instead we just need a list of products displayed with...
| |
by: Simon |
last post by:
Hi,
Just to get started....
I've created a very simple web form, "Simple", using VS and I dropped a
HTML img control on the design view. I referenced a picture and it is
displayed in browser...
|
by: Billy Cormic |
last post by:
Hi,
I am new to asp.net but have done quite a bit of applications
programming. I would like to create a base class webform that other
webforms can inherit from. Let's say Webform1 is the base...
|
by: 3Cooks |
last post by:
I have a windows application written in Visual Basic 6.0 that is going
to be redeveloped in dotNET. We are trying to decide if we should
deploy using Webforms or Winforms and I need advice from...
|
by: Bit byte |
last post by:
Can I use C# (Winforms) to design a website?. I am from C/C++ background
but know nothing about Internet programming.
My understanding of WebForms are that they are similar to WinForms in
that...
|
by: =?Utf-8?B?R3lhbmVuZHJh?= |
last post by:
I am using Ajax control(Update Panel) in my web page(ASP.Net 2.0) and putting
Report Viewer(Sql Server Reporting Services 2005) Control in it.
When I am displaying any report it is coming...
|
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,...
| |
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...
|
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...
|
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...
|
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...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
|
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 ...
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
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...
| |