I am using Visual Web Developer 2005.
Can I use the button PostBackURL to open a second web form in a new window,
instead of replacing the current page?
Thanks
Bill 3 14903
Hi,
one way is to change form's target when posting
<asp:Button ID="Button1" OnClientClick=" form1.target='_ blank'"
runat="server" Text="Button" PostBackUrl="~/Default2.aspx" />
You just might also turn it back after posting, in case other buttons still
continue posting on the same page.
--
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU http://blogs.aspadvice.com/joteke
"bill" <be****@datamti .com> wrote in message
news:uw******** ******@TK2MSFTN GP11.phx.gbl... I am using Visual Web Developer 2005.
Can I use the button PostBackURL to open a second web form in a new window, instead of replacing the current page?
Thanks Bill
I'm pleased to report that I figured it out for my self!
In case anybody else cares, put
<base target="_blank" ></base>
between the <head></head> tags of the source aspx page.
PostBackURL is a good feature.
-Bill
"bill" <be****@datamti .com> wrote in message
news:uw******** ******@TK2MSFTN GP11.phx.gbl... I am using Visual Web Developer 2005.
Can I use the button PostBackURL to open a second web form in a new window, instead of replacing the current page?
Thanks Bill
Thanks Teemu, that is a good way to do it.
-Bill
"Teemu Keiski" <jo****@aspalli ance.com> wrote in message
news:Od******** ******@TK2MSFTN GP09.phx.gbl... Hi,
one way is to change form's target when posting
<asp:Button ID="Button1" OnClientClick=" form1.target='_ blank'" runat="server" Text="Button" PostBackUrl="~/Default2.aspx" />
You just might also turn it back after posting, in case other buttons still continue posting on the same page.
-- Teemu Keiski ASP.NET MVP, AspInsider Finland, EU http://blogs.aspadvice.com/joteke
"bill" <be****@datamti .com> wrote in message news:uw******** ******@TK2MSFTN GP11.phx.gbl...I am using Visual Web Developer 2005.
Can I use the button PostBackURL to open a second web form in a new window, instead of replacing the current page?
Thanks Bill
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: osh |
last post by:
All,
I am having trouble using the PostBackUrl feature in .NET 2.0. I have
several User Controls that are on a MasterPage. The User Controls
contain the form fields for a basic search on available homes and
properties in a given area. I put these form fields into User Controls
because they will be repeated in different ways throughout the site and
it would be nice to only update the fields from one place to make a
site wide change.
|
by: lanem |
last post by:
I want to pop open a new window from my asp.net 2.0 web page. I want it to
pass or submit the current viewstate to the new window. Does anyone know how
to do that? Thanks.
|
by: David Thielen |
last post by:
Hi;
In a page, when the user clicks on a button, I want to validate all the
controls (in the code behind) and then if they are good, leave that page
alone and launch a new window with a new url also.
This is what I think is the best approach - please let me know if there is a
better one:
In my code behind I validate everything.
|
by: sck10 |
last post by:
Hello,
Can you use the PostBackUrl to post to different sites? I have a page
(PostBackURL.aspx' ) on one website (same server) that has a button set to:
PostBackURL="http://zone1.web.com"
When the second page opened, and tried to get a hidden value on the previous
page, I got the following error:
|
by: Chris |
last post by:
Hi,
i created an ImageButton within an ItemTemplate of a datalist (in
shop.aspx). There are two possibilities:
1) when the user is logged and he clicks on an image, he must be
'postbacked' to another file showing that same picture in big size and with
more info..
2) when not logged and clicking on an image, he must be 'postbacked' to the
login page (log.aspx).
| |
by: noneya22 |
last post by:
I'm using asp.net 2.0. I have a page that has a save button and a
cancel button along with a text field. All controls are asp.net
server controls. I have JavaScript that prompts the user if he has
maninpulated data in the text field and then tries to leave the page.
The purpose is to prevent the user from accidentally losing his
changes. This JavaScript code that accomplishes this is based upon
the code found at...
|
by: joseph |
last post by:
Hello
Could you help
i want to use postbackurl to a new window, not replace previous page.
i doing something
onclientscript="form1.target='_blank'" postbackurl="~/default2.aspx" is
not work.
|
by: James R. Davis |
last post by:
I am converting my ASP code to ASP.NET but have run into a hard stop. On
several of my pages I must post data to a different page as a result of a
submit. With ASP.NET, however, it seems that the 'action' clause on a form
is ignored and it always posts to itself.
Now how, guys, do you manage to set up a form to post to PayPal, for
example?
What am I missing here?
|
by: Tony |
last post by:
Hi,
I have two questions:
1) With this code, i never see the alert message. Why? How to see it?
Page.ClientScript.RegisterClientScriptBlock(Me.GetType(), "myscript", _
" alert('you go to stating page.');", True)
response.redirect("start.aspx", false)
|
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 usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
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.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
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 captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
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 launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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 then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
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 the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
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: 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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |