How to read data from resource .rex file in java script?

How to read data from resource .rex file in java script?

am 31.12.2007 10:47:31 von chandan

Hi,
How can I show that message in alert code ( in java script) that
pick the data form resouse .rex file .

Thanks in advance.
Chandan

Re: How to read data from resource .rex file in java script?

am 31.12.2007 16:47:55 von mark

"chandan" wrote in message
news:397da582-bf47-48ee-b891-788652148496@d21g2000prf.google groups.com...

> How can I show that message in alert code ( in java script) that
> pick the data form resouse .rex file .

protected void Page_Load(object sender, EventArgs e)
{
bool blnSomeCondition = false;
// code to populate blnSomeCondition...

if (blnSomeCondition)
{
string strTextFromResx = String.Empty;
// read the text from the resource file into the strTextFromResx
variable
ClientScript.RegisterStartupScript(GetType(), "resxMsg", alert('" +
strTextFromResx + "');", true);
}
else
{
// rest of Page_Load method...
}
}


--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Re: How to read data from resource .rex file in java script?

am 31.12.2007 17:42:10 von NoSpamMgbworld

You can't do it, at least not directly.

If you emit the JavaScript, however, you can set it up based on the user's
language preference when the page is built.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

*************************************************
| Think outside the box!
|
*************************************************
"chandan" wrote in message
news:397da582-bf47-48ee-b891-788652148496@d21g2000prf.google groups.com...
> Hi,
> How can I show that message in alert code ( in java script) that
> pick the data form resouse .rex file .
>
> Thanks in advance.
> Chandan