a string in a string in a string in my code behind....

I know my title talk about code-behind, but this is really a client-side problem (and surely a newby one too, sorry about that).

I have a javascript function that my make a little text appear when the onmouseover event of a link is activated.

So, normally, if my link was inside my html code, it would be something like this:

<a href = "whocare.com"  onmouseover="poplink('I want to test something');">test</a>

BUT, for some reason, I have to write this part in code behind with the LiteralControl function....and that will give something like that:

this.Controls.Add(new LiteralControl("<a href = 'whocare.com'  onmouseover='poplink('I want to test something');'>test</a>")

the red part is where my problem is, how can I let my browser know that this part is a string, if Im already in a string inside another string....maybe this may sound like a newbish question like I said, but im kinda in the dark here, so any help would be appreciated.
8/30/2005 3:25:36 PM
asp.net.client-side 24353 articles. 2 followers. Follow

1 Replies

Similar Articles

[PageSpeed] 19
Get it on Google Play
Get it on Apple App Store

Hi xello,

leave the html code as is and just escape double quotes:

this.Controls.Add(new LiteralControl("<a href = \"whocare.com\"  onmouseover=\"poplink('I want to test something');\">test</a>")

Julio P. Di Egidio
Software Analyst Programmer

(Peace X Love] = [++1)
8/30/2005 5:58:48 PM

Similar Artilces:

string to string[]
Hi, I've got this code : string[] Params; string SQL = "SELECT * FROM T_MANAGEMENT_PAGES"; SqlCommand myCommand = new SqlCommand(SQL, myConnection); myConnection.Open(); SqlDataReader myReader = myCommand.ExecuteReader(); try { while (myReader.Read()) { Params_Type = myReader.GetValue(0).ToString(); } } catch { } finally { } myReader.Close(); My problem is to obtain Params_Type. But each time, it says : "impossible to convert '[object]' in 'string[]' &quo...

String and String[]
What will be the advantage of using myString: String[10] over myString: String Man wrote: > What will be the advantage of using > myString: String[10] > over > myString: String "String[10]" is a fixed-length, statically allocated, Ansi-based ShortString. "String" is a dynamic-length, dynamically allocated, reference counted, Ansi-based or Unicode-based (depening on Delphi version) Long string. Unless you absolutely need the static, fixed length nature of ShortString, such as in records that interact with external systems, you should stay ...

string and string[]
hello, whats the difference here between string and string[] thanks "string" denotes an item of type String "string[]" denotes an array of type String itemsThanks, EdMicrosoft MVP - ASP/ASP.NET Gracia mon ami...

string() = string()
this code does not work (not instance of object) Dim Items(), Other() As String Items = New String() {"A","B","C"} Other = New String() {} Other = Items how can I get all the values ? angiras Hi, If I understand your requirement correctly, this should do it Dim Items() As String = {"A", "B", "C"} Dim Other(Items.Length - 1) As String Items.CopyTo(Other, 0) To more closely match you code above, but this will be less efficient Dim Items(), Other() As String ...

String and string?
Hi guys, I was wondering the difference between small letter string type and a capital letter String type. Does anyone know about this? Highly appreciate for your answers! Thankz! The "proper" version is String, as it references the System.String class of the .NET Framework Class Library. The ability to use string is provided by C#, where it is an alias to String. Similarly, the "proper" version of an integer is Int32, as it references System.Int32.  The ability to use int is provided by C#, and the ability to use Integer is provided by VB.NET, and both int and Integer are aliases...

m_AVP As IDictionary(Of String, String) = New Dictionary(Of String, String) ,not defined?
   I am creating a usercontrol (ascx,ascx.vb)   I have used Imports system.Collections Imports system.Collections.Generic     Private m_AttributeValuePair As IDictionary(Of String, String) = New Dictionary(Of String, String)     But I am gettting an error “Type Dictionary is not defined”   And also I am getting intelisense to type the line But what is the reason for my error ? How can I get escape from the error ?         this error is not showing today  ...

How to Encrypt a String to a String?
Hi Folks,I’m using Triple DES to encrypt a string… the output of the encryption is a byte array.However, I want to store the encrypted result as a string in a SQL Database and not as a byte array.(The reason I want to store it as a string, is to be able to copy & paste the result to a standalone windows form application  to decrypt it...) I’ve tried taking the byte array, converting it into a string…And then reconverting it into a byte array for the decryption. This causes an error upon decryption…How can I convert the encrypted byte array into a string and back into a byt...

RSA Encryption
Here is my goal:1. Take a string2. Encrypt it 3. Pass it as a parameter in the QueryString4. Decrypt it The value starts as a string, then is converted to a byte[] and then encrypted.  The resulting byte[] is converted to a string and send as a parameter.  The recieving page decrypts the string (creates a byte[], decrypts to a new byte[], and the value is finally parsed for its values) I am using http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemsecuritycryptographyrsacryptoserviceproviderclasstopic.asp with a small modification t...

Detecting string in string
Hello I am not an advanced perl programmer and I do not have my books with me. I want to determine if a string is within a string and to not process the string if the string is found. Could someone please provide a simple sample. Thanks, Andrew On 2/22/07, andrewmchorney@cox.net <andrewmchorney@cox.net> wrote: > I am not an advanced perl programmer Have courage -- you'll get there someday! > and I do not have my books with me. That's what the perldoc command is for. > I want to determine if a string is within a string Do you want the index func...

String and String[30]
Any advantage in using this style in defining a string type variable? myName: String; hisName: String[30]; "Alan Tse" <alan_NO_SPAM_pltse@yahoo.com.au> wrote in message news:177975@forums.codegear.com... > Any advantage in using this style in defining a string type variable? > > myName: String; > hisName: String[30]; String[30] is a short string type and is ANSI only. You should use simple String type (Unicode in D2009+). -- Wayne Niddery (TeamB) Alan Tse wrote: > Any advantage in using this style in defining a string type variable? ...

Count no of strings in a string
dim ref as string ="<a href=""/iyp/yp/ypkeywordsearch.do?" hi i would like to know something how do i count the number of ref in a html document??you see i have another string call htmldoc(it contains a html document of a web page) and i want to extract all the ref in htmldoc how do i do that? 2) How do i include a closed inverted comma in a string?? dim a as string = "abcde"fghijk""" How do i use the mid method to seacrh from " ?? 1) You should learn about Regular Expressions 2) Double the quotes: "abcde"...

Why String.Split(char[]) is possible but String.Split(string[]) is Not!
Hi everyone, i have a string for e:g String st= "Delete a record****** *************************************************** Delete Manually PatID=123456 PatName=navdeep *****Delete a record****** *************************************************** Delete Manually *****************PatID=123 PatName=navdeep6666" I need to Split this String by "Delete a record" string. Now, str[] will contain the array elements. str = st.Split("Delete a record"); Please Help Regards Navdeep check below link or try code  http://www.codeproject.co...

Hello! I use SQLANY 5.5.05 and loking for one function which will do following: find string in string and replace it with another string. In version ASA 6 I found function STUFF which I think do something like this. Is there anything in 5.5.05? Regards Tomaz Try this: create function ReplaceString(in str long varchar,in old_substr char(255),in new_substr char(255)) returns long varchar begin // Change all occurrences of old_substr to new_substr in str. declare start_pos integer; declare found_pos integer; declare new_str long varchar; set new_str=&#...

Difference between String and string
When would you use String as apposed string, when writing functions certain functions work when defined as private string help ( string param){ } Others require the following private string help ( String param){ } Does anybody know why? In C#, string is an alias for the .NET Framework provided type String (and recall C# is case sensitive). I am not aware of any compelling reason to use one vs. the other.Starting with ASP.NET 2.0? Look at:Programming Microsoft Web Forms My Blog...

Web resources about - a string in a string in a string in my code behind.... - asp.net.client-side

Korea Bucks Global Box Office Trend as ‘Himalayas’ Beats ‘Star Wars’
Local survival drama “The Himalayas” opened on top of the Korean box office, comfortably beating “Star Wars: The Force Awakens.

Emergency on Air France flight a "false alarm," CEO says
Reuters Emergency on Air France flight a "false alarm," CEO says Reuters PARIS/MOMBASA, Kenya A suspicious device found on an Air France flight ...

Splintered Spanish vote heralds arduous coalition talks
Reuters Splintered Spanish vote heralds arduous coalition talks Reuters MADRID A historically fragmented vote in Spanish elections on Sunday ...

Miss Philippines Wins Miss Universe In Bizarre Finish
(John Hinderaker) Tonight’s Miss Universe pageant concluded with a fiasco, as the announcer apparently misunderstood the final rankings and ...

Israel hit by rockets from Lebanon as tensions rise after Hezbollah's Samir Kantar killing
Katyusha missiles fired into Israel after air strike killed Hezbollah leader in Syria.

At Least 91 Still Missing After Landslide Hits Chinese Manufacturing Center
On Monday, a day after a landslide buried or toppled 33 buildings at an industrial park in China, at least 91 people were still missing, according ...

Hundreds protest release of New Delhi rapist
Salt Lake Tribune Hundreds protest release of New Delhi rapist Salt Lake Tribune Indian youth shout slogans as they are detained by police ...

Ted Cruz Maintains Big Lead in Iowa
Here's more for the "establishment is doomed" files : Ted Cruz maintains a strong lead over Donald Trump in Iowa, according to the results of ...

Learner drivers to get lessons on the motorway for the first time
Learner drivers could have lessons on motorways for the first time, in a bid to ensure they have tackled challenging conditions with a qualified ...

SpaceX delays launch and landing test of Falcon 9 rocket
(By Irene Klotz, Reuters) – Elon Musk’s SpaceX on Sunday postponed launch of an upgraded Falcon 9 rocket and an attempt to land the booster at ...

Resources last updated: 12/21/2015 4:10:02 AM