I'm trying to have the headertext in one of my columns have html in it, but when it displays in the browser, it just shows the tags, and doesn't format it. ie. if I try to set my header text to something like "hello<b>goodbye</b>", the text will display exactly as that, instead of rendering the tag.
I'm also have some issues setting the headertext using javascript, but I think that's related to the same issue, as I don't have any problems if there are no html tags in the text, but if there are, it sets it fine the first time, but then if I try to change it, I get a javascript error (unknown runtime error).
Any ideas?
kmcdonald said: I am manually editing the markup. I rarely use the designer. I find it much easier to just type in the code that I need. Especially with intellisense. Anyway, that doesn't work.
I am manually editing the markup. I rarely use the designer. I find it much easier to just type in the code that I need. Especially with intellisense.
Anyway, that doesn't work.
Oops, sorry about that. I had it backwards. I found the place where i was putting <br> tags in my headers, and the markup has "<br />" tokens. This actually does work in my grid.
Anyway, that doesn't work. I did get it to work by changing the headertext in javascript. Basically my problem is that I wanted to add a link into the header to call some javascript when they click on it. It worked, but after they clicked on it, I was trying to change the text back, and it kept the link there, but changed the text that displayed. The next time it tried to put the link back is when I got the unknown runtime error. I got around this by realizing that it's ok for me to leave the link there, and just change the text that displays, which is what I want anyway.
So that part is working, but now I have to resize the header to make it tall enough to show the extra text. I really find the formatting of this webgrid to be quite difficult, whenever I change one thing it seems to screw up everything else.
Anyway, thanks for your suggestion.
kmcdonald said:if I try to set my header text to something like "hello<b>goodbye</b>", the text will display exactly as that, instead of rendering the tag.
You probably need to manually edit your markup. I think the designer changes "<" to "<" if you use the properties window. Clever, no?