wolf
08-06-2002, 02:09 PM
Can someone help me with highlighting all the text in a table cell?
I am currenly using this to create a printer friendly display of the text output. (This is the short version. There are multiple strings over many lines).
I could use a textarea, but the scroll bar prevents everything from being displayed (not printer friendly). Is there another way to do this?
function Display()
{
str = "This is an example of the text output";
document.all['previewDisplay'].innerText = str;
// add select all here
}
...
<form name="previewform">
<TABLE>
<TR><TD ID = "previewDisplay">
</TD></TR>
<TR><TD><INPUT type = "button" value = "Finished" onclick = Display()></TD></TR>
</TABLE>
</form>
I am currenly using this to create a printer friendly display of the text output. (This is the short version. There are multiple strings over many lines).
I could use a textarea, but the scroll bar prevents everything from being displayed (not printer friendly). Is there another way to do this?
function Display()
{
str = "This is an example of the text output";
document.all['previewDisplay'].innerText = str;
// add select all here
}
...
<form name="previewform">
<TABLE>
<TR><TD ID = "previewDisplay">
</TD></TR>
<TR><TD><INPUT type = "button" value = "Finished" onclick = Display()></TD></TR>
</TABLE>
</form>