<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx</link><description>I noticed that the following is an issue thru which people often run: when you show an aspx page (or any server content in general) in a dialog by mean of the javascript ShowModalDialog method, at the first postback you usually witness the instance of</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#16071</link><pubDate>Thu, 05 Jun 2003 23:14:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:16071</guid><dc:creator>Jason</dc:creator><description>		&amp;lt;base target=&amp;quot;_self&amp;quot;&amp;gt;
&lt;br&gt;

&lt;br&gt;
Sticking that in the header of the ASPX page you're targetting with .showModalDialog() gets the same results....without resorting to the overhead of IFRAME.
&lt;br&gt;

&lt;br&gt;
- J</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#16074</link><pubDate>Fri, 06 Jun 2003 00:02:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:16074</guid><dc:creator>StingK</dc:creator><description>Hasn't the target attribute been deprecated?</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#16086</link><pubDate>Fri, 06 Jun 2003 04:10:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:16086</guid><dc:creator>JosephCooney</dc:creator><description>IIRR turning smartnavigation ON on the aspx that appears in the modal dialog window also gets around this problem. YMMV.</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#17152</link><pubDate>Fri, 20 Jun 2003 01:29:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:17152</guid><dc:creator>Elizabeth Ahola</dc:creator><description>HI,
&lt;br&gt;

&lt;br&gt;
I've been struggling with this all day.  I used the dummy &amp;lt;Iframe&amp;gt; .html, but had a hard time getting the returnvalue.
&lt;br&gt;

&lt;br&gt;
I put in the &amp;lt;base....&amp;gt; tag info and that works.
&lt;br&gt;

&lt;br&gt;
But I am still having trouble getting the returnvalue.
&lt;br&gt;

&lt;br&gt;
In my Parent window I have
&lt;br&gt;
     code....
&lt;br&gt;
     arrModal = window.showModalDialog
&lt;br&gt;
                (&amp;quot;popup.asp&amp;quot;,, _
&lt;br&gt;
                 &amp;quot;dialogHeight:30;
&lt;br&gt;
dialogWidth:33;edge:Raised;center:Yes;help:No;resizable:No;status:No;&amp;quot;)
&lt;br&gt;

&lt;br&gt;
     msgbox arrmodal
&lt;br&gt;

&lt;br&gt;

&lt;br&gt;
in my popup window I have.
&lt;br&gt;

&lt;br&gt;
     code.....
&lt;br&gt;
     window.returnvalue = &amp;quot;HERE I BE&amp;quot;
&lt;br&gt;
     window.close
&lt;br&gt;

&lt;br&gt;
The value of arrModal in the parent window when the popup is close is null.
&lt;br&gt;

&lt;br&gt;

&lt;br&gt;
any ideas?   It seems so straight forward.
&lt;br&gt;

&lt;br&gt;
</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#17185</link><pubDate>Fri, 20 Jun 2003 10:56:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:17185</guid><dc:creator>Vittorio</dc:creator><description>Elisabeth, I've heard of this from others but I never had the time to actually check it out. If you don't have problems of security/confidentiality of data, I know that a lot of people used this workaround: you can put your results on a cookie generated for the purpose (use as ID a GUID supplied from the caller at the dialog opening) and retrieve (and delete) it from the caller page as the dialog closes. Let me know if it worked for you.</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#23104</link><pubDate>Fri, 08 Aug 2003 11:08:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:23104</guid><dc:creator>111</dc:creator><description>11</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#26987</link><pubDate>Wed, 10 Sep 2003 19:12:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:26987</guid><dc:creator>brendan</dc:creator><description>window.returnvalue = &amp;quot;HERE I BE&amp;quot;&lt;br&gt;should be&lt;br&gt;&lt;br&gt;window.returnValue = &amp;quot;HERE I BE&amp;quot;</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#35195</link><pubDate>Sun, 02 Nov 2003 00:44:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:35195</guid><dc:creator>ed</dc:creator><description>xxx</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#41481</link><pubDate>Sat, 06 Dec 2003 01:00:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:41481</guid><dc:creator>rtyhe</dc:creator><description>eth45yh4hy</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#48514</link><pubDate>Thu, 08 Jan 2004 12:51:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:48514</guid><dc:creator>f</dc:creator><description>dfg</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#63359</link><pubDate>Tue, 27 Jan 2004 20:51:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:63359</guid><dc:creator>Chris Moutray</dc:creator><description>thanks this fix really got me out of a jam ...</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#64333</link><pubDate>Thu, 29 Jan 2004 21:20:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:64333</guid><dc:creator>Dominique</dc:creator><description>Hello&lt;br&gt;I am also facing the same problem.&lt;br&gt;I have added &amp;lt;base target=&amp;quot;_self&amp;quot;&amp;gt; tag just below meta tags in &amp;lt;head&amp;gt;&lt;br&gt;&amp;amp; also SmartNavigation=true in page directive.&lt;br&gt;still after post back the page is opening in new IE instance..&lt;br&gt;please help..&lt;br&gt;</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#82477</link><pubDate>Tue, 02 Mar 2004 17:19:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:82477</guid><dc:creator>dfas</dc:creator><description>dfsa</description></item><item><title>sdfsdf</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#103013</link><pubDate>Tue, 30 Mar 2004 17:48:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:103013</guid><dc:creator>sdfsdf</dc:creator><description>ssdfsdf</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#109171</link><pubDate>Thu, 08 Apr 2004 02:53:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:109171</guid><dc:creator>test</dc:creator><description>test</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#114695</link><pubDate>Sat, 17 Apr 2004 01:55:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:114695</guid><dc:creator>dsaf</dc:creator><description>fsda</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#125124</link><pubDate>Tue, 04 May 2004 02:20:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:125124</guid><dc:creator>dgdf</dc:creator><description>dg</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#133175</link><pubDate>Mon, 17 May 2004 22:40:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:133175</guid><dc:creator>dwwe</dc:creator><description>asodjsodjweodjwedwe</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#133177</link><pubDate>Mon, 17 May 2004 22:40:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:133177</guid><dc:creator>ssss</dc:creator><description>ssss</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#142793</link><pubDate>Thu, 27 May 2004 10:33:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:142793</guid><dc:creator>Tomas Petricek</dc:creator><description>Thanks a lot !&lt;br&gt;I used solution with &amp;lt;base.. /&amp;gt; and i works great.&lt;br&gt;&lt;br&gt;Tomas</description></item><item><title>re: ShowModalDialog&lt;center&gt;&lt;b&gt;you&lt;/b&gt;</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#146575</link><pubDate>Wed, 02 Jun 2004 22:01:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:146575</guid><dc:creator>&lt;center&gt;&lt;b&gt;you&lt;/b&gt;</dc:creator><description>&amp;lt;center&amp;gt;&amp;lt;b&amp;gt;you&amp;lt;/b&amp;gt;</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#163997</link><pubDate>Thu, 24 Jun 2004 04:47:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:163997</guid><dc:creator>ashwini</dc:creator><description>does the &amp;lt;base target=&amp;quot;_self&amp;quot;&amp;gt; work with modal .jsp files too...i tried it ..doesn't work</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#165791</link><pubDate>Fri, 25 Jun 2004 23:29:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:165791</guid><dc:creator>drewt</dc:creator><description>test</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#165792</link><pubDate>Fri, 25 Jun 2004 23:29:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:165792</guid><dc:creator>drewt</dc:creator><description>test</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#188986</link><pubDate>Wed, 21 Jul 2004 04:02:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:188986</guid><dc:creator>Miguel Madero</dc:creator><description>I had trouble getting the return value. &lt;br&gt;I dont know why, but everytime I tried to get the value I just got undefined. &lt;br&gt;&lt;br&gt;What you can is to define a variable in the opener window and then pass it as the dialogArguments and modify it like:&lt;br&gt;window.dialogArguments = &amp;quot;new value&amp;quot;&lt;br&gt;&lt;br&gt;or even better, you can pass the window object as a reference and then update or use any variable. &lt;br&gt;window.dialogArguments.var1 = &amp;quot;new value&amp;quot;;&lt;br&gt;window.dialogArguments.var2 = &amp;quot;new value&amp;quot;;&lt;br&gt;&lt;br&gt;just open the window this way:&lt;br&gt;window.showModalDialog(&amp;quot;url.htm&amp;quot;,window);&lt;br&gt;&lt;br&gt;&lt;br&gt;I hope this helps. &lt;br&gt;&lt;br&gt;By the way, thanks for the other tips. I've tried none, but I hope one of those will work for me. &lt;br&gt;&lt;br&gt;It's weird that doesnt happens with html pages. &lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;</description></item><item><title>re: ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#208947</link><pubDate>Thu, 05 Aug 2004 23:51:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:208947</guid><dc:creator>Davide Senatore</dc:creator><description>Great tip!&lt;br&gt;The &amp;lt;base target=&amp;quot;_self&amp;quot;&amp;gt; part works great for me!&lt;br&gt;Thank you very much!&lt;br&gt;&lt;br&gt;Davide</description></item><item><title>The blogosphere saves my ass again</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#246172</link><pubDate>Fri, 22 Oct 2004 09:43:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:246172</guid><dc:creator>An attempt at structured thought.</dc:creator><description>The blogosphere saves my ass again</description></item><item><title>Postback e ShowModalDialog</title><link>http://blogs.msdn.com/vbertocci/archive/2003/06/05/8319.aspx#732974</link><pubDate>Thu, 31 Aug 2006 09:08:51 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:732974</guid><dc:creator>UGbLog di Pierre Greborio </dc:creator><description /></item></channel></rss>