Hello,
I have a problem with passing Data between a "classic ASP-Page (VBScript)"
and a ASP.NET 2.0 Page using showModalDialog / window.returnVa lue
-------------------------------------------------------------
Here is the Code-Snippet from the "caller" page:
var rValue="oldValu e";
rValue = showModalDialog (test.aspx?,'Na me','dialogHeig ht:400px;
dialogWidth:800 px;');
alert(rValue);
-----------------------------------------------------------
Here is the Code-Snippet from test.aspx
public partial class _Default : System.Web.UI.P age
{
protected void Page_Load(objec t sender, EventArgs e)
{
TxtPLZ.Attribut es.Add("onClick ","javascript:w indow.returnVal ue='1',window.c lose();");
}
}
Clicking on the TxtLabel closes the window, but alert(rValue); shows alway
"undefined"
What am I doing wrong?
cheers, andreas 4 2125
Try
TxtPLZ.Attribut es.Add("onclick ","window.retur nValue='1';wind ow.close();");
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"Andreas Pfiz" <pf**@solid-it.dewrote in message
news:eQ******** ******@TK2MSFTN GP04.phx.gbl...
Hello,
I have a problem with passing Data between a "classic ASP-Page (VBScript)"
and a ASP.NET 2.0 Page using showModalDialog / window.returnVa lue
-------------------------------------------------------------
Here is the Code-Snippet from the "caller" page:
var rValue="oldValu e";
rValue = showModalDialog (test.aspx?,'Na me','dialogHeig ht:400px;
dialogWidth:800 px;');
alert(rValue);
-----------------------------------------------------------
Here is the Code-Snippet from test.aspx
public partial class _Default : System.Web.UI.P age
{
protected void Page_Load(objec t sender, EventArgs e)
{
TxtPLZ.Attribut es.Add("onClick ","javascript:w indow.returnVal ue='1',window.c lose();");
}
}
Clicking on the TxtLabel closes the window, but alert(rValue); shows alway
"undefined"
What am I doing wrong?
cheers, andreas
Thanks a lot for your answer!
Unfortunately it is the ReturnValue is still "undefined"
"Eliyahu Goldin" <re************ *@monarchmed.co mschrieb im Newsbeitrag
news:eE******** *****@TK2MSFTNG P05.phx.gbl...
Try
TxtPLZ.Attribut es.Add("onclick ","window.retur nValue='1';wind ow.close();");
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"Andreas Pfiz" <pf**@solid-it.dewrote in message
news:eQ******** ******@TK2MSFTN GP04.phx.gbl...
>Hello,
I have a problem with passing Data between a "classic ASP-Page (VBScript)" and a ASP.NET 2.0 Page using showModalDialog / window.returnV alue ------------------------------------------------------------- Here is the Code-Snippet from the "caller" page:
var rValue="oldValu e"; rValue = showModalDialog (test.aspx?,'Na me','dialogHeig ht:400px; dialogWidth:80 0px;'); alert(rValue ); ----------------------------------------------------------- Here is the Code-Snippet from test.aspx
public partial class _Default : System.Web.UI.P age { protected void Page_Load(objec t sender, EventArgs e) {
TxtPLZ.Attribu tes.Add("onClic k","javascript: window.returnVa lue='1',window. close();"); } }
Clicking on the TxtLabel closes the window, but alert(rValue); shows alway "undefined"
What am I doing wrong?
cheers, andreas
What you show here should work. Check other places in the code that can
affect returnValue.
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"Andreas Pfiz" <pf**@solid-it.dewrote in message
news:%2******** ********@TK2MSF TNGP03.phx.gbl. ..
Thanks a lot for your answer!
Unfortunately it is the ReturnValue is still "undefined"
"Eliyahu Goldin" <re************ *@monarchmed.co mschrieb im Newsbeitrag
news:eE******** *****@TK2MSFTNG P05.phx.gbl...
>Try
TxtPLZ.Attribu tes.Add("onclic k","window.retu rnValue='1';win dow.close();");
-- Eliyahu Goldin, Software Developer & Consultant Microsoft MVP [ASP.NET]
"Andreas Pfiz" <pf**@solid-it.dewrote in message news:eQ******* *******@TK2MSFT NGP04.phx.gbl.. .
>>Hello,
I have a problem with passing Data between a "classic ASP-Page (VBScript)" and a ASP.NET 2.0 Page using showModalDialog / window.return Value ------------------------------------------------------------- Here is the Code-Snippet from the "caller" page:
var rValue="oldValu e"; rValue = showModalDialog (test.aspx?,'Na me','dialogHeig ht:400px; dialogWidth:8 00px;'); alert(rValue) ; ----------------------------------------------------------- Here is the Code-Snippet from test.aspx
public partial class _Default : System.Web.UI.P age { protected void Page_Load(objec t sender, EventArgs e) {
TxtPLZ.Attrib utes.Add("onCli ck","javascript :window.returnV alue='1',window .close();"); } }
Clicking on the TxtLabel closes the window, but alert(rValue); shows alway "undefined"
What am I doing wrong?
cheers, andreas
actually there is not much more in my test-environment...m aybe a bug?
"Eliyahu Goldin" <re************ *@monarchmed.co mschrieb im Newsbeitrag
news:%2******** ********@TK2MSF TNGP03.phx.gbl. ..
What you show here should work. Check other places in the code that can
affect returnValue.
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"Andreas Pfiz" <pf**@solid-it.dewrote in message
news:%2******** ********@TK2MSF TNGP03.phx.gbl. ..
>Thanks a lot for your answer!
Unfortunatel y it is the ReturnValue is still "undefined"
"Eliyahu Goldin" <re************ *@monarchmed.co mschrieb im Newsbeitrag news:eE******* ******@TK2MSFTN GP05.phx.gbl...
>>Try
TxtPLZ.Attrib utes.Add("oncli ck","window.ret urnValue='1';wi ndow.close();") ;
-- Eliyahu Goldin, Software Developer & Consultant Microsoft MVP [ASP.NET]
"Andreas Pfiz" <pf**@solid-it.dewrote in message news:eQ****** ********@TK2MSF TNGP04.phx.gbl. .. Hello,
I have a problem with passing Data between a "classic ASP-Page (VBScript) " and a ASP.NET 2.0 Page using showModalDialog / window.retur nValue ------------------------------------------------------------- Here is the Code-Snippet from the "caller" page:
var rValue="oldValu e"; rValue = showModalDialog (test.aspx?,'Na me','dialogHeig ht:400px; dialogWidth: 800px;'); alert(rValue ); ----------------------------------------------------------- Here is the Code-Snippet from test.aspx
public partial class _Default : System.Web.UI.P age { protected void Page_Load(objec t sender, EventArgs e) {
TxtPLZ.Attri butes.Add("onCl ick","javascrip t:window.return Value='1',windo w.close();"); } }
Clicking on the TxtLabel closes the window, but alert(rValue); shows alway "undefined"
What am I doing wrong?
cheers, andreas This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Jim M |
last post by:
I hate to pass data on the query string. Is there a way to pass data to the
serverside vb code using the object in showmodaldialog.
var myObject = new Object();
var retVal = new Object();
myObject.calltype = "Edit"
retVal =
showModalDialog("Test.aspx",myObject,"dialogWidth:700px;dialogHeight:550px;s
tatus:0");
|
by: DavidS |
last post by:
I have parent.aspx web page from which I call a modal dialog (child.aspx via showmodaldialog). I'd like to populate two text boxes, <asp:TextBox id=txt_HN> on the child form with data from the caller.
for parent.aspx.....
<script> block
function UpdH(title,horse)
{
var iParms=new Object();
iParms.Name=horse;
....}
for child.aspx.......
|
by: Tim_k |
last post by:
Hi,
I'm using showModalDialog to open a Window and return a user selected
variable.
Here is the code:
retval=window.showModalDialog(sFrameName,window,sFeatures);
document.getElementById(sControlName).value=retval;
This works fine but I can't figure out to pass a value into the dialogbox
I'm creating. I display different data in the...
|
by: MW de Jager |
last post by:
I want to call ShowModalDialog(...) from my C# code in the code behind page
of my aspx page. I do not want to link this to a button, since I want to
first do some checking myself before I call the showModalDialog. I also
want to receive a result back from the ShowModalDialog when it is closed.
My problems are currently these:
(1) If I...
|
by: Carlos Alejandro Pérez |
last post by:
hi
I need to perform this sequence:
- a webform A calls another webform B. Webform B should be a modal one
- when data is entered in webform B, the user chooses close window
- the data must be captured and processed by webform A, if possible,
*without* clicking on a button to force this.
I know I should use IFrames. Can any1 here give me a...
| |
by: mark |
last post by:
I have a main form, and i have another form i need to call on a button
press,
then id like the result of the child form to pass data back to the parent -
without losing any data previously entered
on the parent - is this possible ? ( my main parent window is starting to
get quite cluttered)
cheers
mark
|
by: ting ting |
last post by:
I am using the ASP.net 2.0 and When I load a page, it will auto pop up the Reminder page by following showModalDialog Javascript. It worked fine for the first time, after I amended some data and saved into database. The Reminder page will be closed.
However, after closing the Reminder and load the page again, it will pop up the Reminder page with...
|
by: David |
last post by:
Hi all,
I am opening a webform with showModalDialog. This appears to pop-up fine,
though I have a problem...
Inside the webform is a treeview control.
When the treeview is populated, I am setting the treenode navigateurl to
javascript:Click('test')
|
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: 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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language...
|
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: 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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
|
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: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |