Solved

Sending foreign characters to a modalDialog using 'window.showModalDialog'

Posted on 2008-06-15
4
510 Views
Last Modified: 2008-07-03
Hello,

I am writing a c# asp.net application in which i want to open a modal dialog and sent parameters to it.

var retVal = window.showModalDialog('EntitiesList.aspx?name=" + name, window, 'dialogWidth:220px;dialogHeight:200px,top=300,left=400,');

When my 'name' parameter contains foreign characters (for example, Montó or María), the value received at the destination page has a square (box) instead of the special letter.

How can i send the special characters to my destination page?

Thank you
0
Comment
Question by:Relegence
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 4

Expert Comment

by:Meritor
ID: 21787915
Try following
var retVal = window.showModalDialog('EntitiesList.aspx?name=" + escape(name), window, 'dialogWidth:220px;dialogHeight:200px,top=300,left=400,');

Open in new window

0
 

Author Comment

by:Relegence
ID: 21787936
I tried 'escape' but it didn't help.
When i debug the application i see that i send the correct value, but in my cs page it is not received properly.

I am using:

name = Request["name"];
0
 
LVL 4

Accepted Solution

by:
Meritor earned 400 total points
ID: 21787950
I am not familier with ASP,
but try to set proper endocing while sending response for that,
try using ISO-8859-1 or ISO-8859-2 instead of UTF-8 (the defult one, I guess).
0
 

Author Comment

by:Relegence
ID: 21787956
Thanks a lot,
I used ISO-8859-1 and it works!
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developer tools in browsers have been around for a while, yet they are still heavily underused by developers. Developers still fix html or CSS then refresh page to see effect, or they put alert or debugger in JavaScript and then try again and again …
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Wufoo.com provides powerful tools for surveying targeted groups, and utilizing data from completed surveys to find trends, discover areas of demand or customer expectation, and make business decisions on products or services.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question