473,399 Members | 3,919 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

Using " ' ' /' /' " in RegisterStartupScript

The function bellow is really ok as long I only write a text in the
document.write(). But I wish to place also a image on my frame side, but for
it I need to have in " " another " " and maybe in thats again the " " I
think it should be a way for my pic
Many thanks for help
Greetings
Patrick Marti

==================================
// I had to cut a bit my function to show here
==================================

private void Page_Load(object sender, System.EventArgs e)
{
scriptString += "function ShowPic(){";
scriptString += "document.write('Mein Bild')";
"... document.write(<img src=C:/Inetpub/wwwroot/A/Ima/Gr1.jpg>)}";
.......................
this.RegisterStartupScript("Startup", scriptString);
==============================================
Nov 22 '05 #1
1 1143
When inserting " in C# strings you should prefix it the " with a \.

so:

string s = "Hello \"world\"";

as an example

--
Patrik Löwendahl [C# MVP]
http://www.lowendahl.net/ || http://www.cshrp.net
Please reply only to the newsgroup.

Patrick Marti wrote:
The function bellow is really ok as long I only write a text in the
document.write(). But I wish to place also a image on my frame side, but for
it I need to have in " " another " " and maybe in thats again the " " I
think it should be a way for my pic
Many thanks for help
Greetings
Patrick Marti

==================================
// I had to cut a bit my function to show here
==================================

private void Page_Load(object sender, System.EventArgs e)
{
scriptString += "function ShowPic(){";
scriptString += "document.write('Mein Bild')";
"... document.write(<img src=C:/Inetpub/wwwroot/A/Ima/Gr1.jpg>)}";
.......................
this.RegisterStartupScript("Startup", scriptString);
==============================================

Nov 22 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Patrick Marti | last post by:
The function bellow is really ok as long I only write a text in the document.write(). But I wish to place also a image on my frame side, but for it I need to have in " " another " " and maybe in...
2
by: David P. Donahue | last post by:
Is there a way to specify on each control of a page which button on the page should be "clicked" when the user presses "return" from within that control? It seems like it's always just defaulting...
0
by: Leslie McGann | last post by:
Hi, I need to open a different pdf file in an iframe each time the user clicks a button. I also need to open the pdf to a specific page each time. The pdfs in question are located on a web...
2
by: Bill Cohagan | last post by:
I'm trying out ASP.Net and am currently trying to figure out how to refresh the contents of one frame based on a button click in another frame. The button in question is actually a server side...
1
by: Grey | last post by:
i use "this.Page.RegisterStartupScript()" to display the client-side script of confirmation box ...but I want to know that how can I know the user was clicked "YES" or "NO" as I need to do different...
0
by: rom | last post by:
my main aspx page has 3 user controls. they are all located in the same place of the page and each time i set the visibility of 2 of them to false and 1 to true. now, i want to use the...
5
by: Alexander Widera | last post by:
I have a file "file1.cs" with a method: using System; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public static void justdoit() { string script = "<script...
7
by: RFS666 | last post by:
Hello, I would like to use variables with a type in jscript.NET. I declare them as follows: var x : double = 5.03; This doesn't work in my script, that I write to the page in codebehind with...
4
by: Jon Paal | last post by:
"Page.Clientscript" does not compile in assembly, with the error message "Reference to a non-shared member requires an object reference". ... what reference is it looking for ?????? class...
2
by: thirunavukarasukm | last post by:
Hai.... "i want used confirm in javascript in code behind" i am used confirm button ,,,in code behind. if the confirm button worked the function is return the true...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
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,...
0
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...
0
jinu1996
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...
0
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...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.