rendering data in a frame with onmouse over

havik1

New member
Joined
Nov 24, 2009
Messages
3
Programming Experience
Beginner
Suppose: I want to render text in a frame separated from a grid in another frame. When the cursor passes over a cell the text must be rendered and when I move out the text must disappear. I get the data but strange if there's a space between two words, the text will not appear, although the data are there.
I retrieve the data in a repeater and I manipulate them with repeater_itemdatabound.
Code:
Sub Repeater_ItemDataBound(ByVal s As Object, ByVal e As RepeaterItemEventArgs)

//here I retrieve the data
Dim reader As SqlDataReader = cm.ExecuteReader()

While reader.Read()
'Response.Write(reader("DSOmschrijving"))
If reader("DSOmschrijving") <> "" Then
var1 = 1
var2 = reader("DSOmschrijving").ToString

End If

End While
//Test to render them
//response.write(var2) ---> and indeed the text is rendered on the screen(principal frame).

// here the text must be in frame2
If var1 = 1 Then

LabDSCode.Text = "<td bgcolor='#999999'>" & "<a href='details.aspx?ds=" & dataLLDCode & "&didsug=" & var2 & "' onMouseOver=parent.frames[1].document.open();parent.frames[1].document.write('" & var2 & "');parent.frames[1].document.close();>".ToString & "&nbsp&nbsp&nbsp&nbsp&nbsp" & "</a>"

Else



End If
cn.Close()
reader.Close()

// If I delete all the spaces (&nbsp) it works , but otherwise not.
If there's someone who knows a solution ???
Thxs a lot ....
 
Thxs, for your reaction. But it doesn't work. When I put "&nbsp" all the spaces are replaced by &nbsp. When I put " " then the spaces remain, but in both cases the phrase is not to be seen in the frame.
Another idea??
 
Back
Top