Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Displaying TextBox over a Div Element

Status
Not open for further replies.

Maddy20

Programmer
Sep 16, 2008
2
US
Hi.

I want to display a textbox over a div element. I have a tabcontainer in which there are several textboxes along with the div elements. right now I am using 'position:absolute' to display the textbox over the div, but as the tab container has a fixed height along with the verticla scroll bar to scroll down, the textboxes are been displayed over the tab container. Is there any way to display textbox over the div element and still displayed inside the tab container??



If I use absolute positioning and left,top position the textboxes are shown over the tab container.

I am providing part of my code hope it will be usefull.

<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" />
<div id="service" style="BEHAVIOR:url(webservice.htc)" ></div>
<div>

<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<cc1:TabContainer ID="TabContainer1" runat="server" ActiveTabIndex="0" Height="200px" Width="780px" ScrollBars="Vertical">
<cc1:TabPanel ID="TabPanel1" runat="server" HeaderText="TabPanel1">
<ContentTemplate>
<table>
<tr >
<td style="width: 100px;height: 189px;">

<div class="markupbox_CSS" style="width: 399px; height: 189px;"/>
<textarea id="TextBox1" runat="server" style="width: 399px; height: 189px;" class = "textArea_CSS" ></textarea>

</td>
</tr>
<tr >
<td style="width: 100px;height: 189px; ">

<div class="markupbox_CSS" style="width: 399px; height: 169px;"/>

<textarea id="TextBox2" runat="server" style="width: 399px; height: 169px;" class="textArea_CSS" ></textarea>
</td>
</tr>
</table>
</ContentTemplate>
</cc1:TabPanel>
</cc1:TabContainer>
</ContentTemplate>
</asp:UpdatePanel>

</div>

</form>



CSS Code:

.textArea_CSS{
border: 0px;
position: absolute;
background: transparent;
color: windowtext;
font: menu;
line-height: expression('1.5em');
padding: 1px;

}

.markupbox_CSS {
position: absolute;
overflow: hidden;
font: menu;
line-height: expression('1.5em');
padding: 3px 1px 1px 1px;
background: window;
color: window;
white-space: pre;

}


Thanks a lot..



Maddy
 
i would ask in forum215. this is an html issue, not an asp.net issue. Note: the css experts shouldn't care how(asp.net) the html is rendered. they will only be concerned with what is rendered (html output).

Jason Meckley
Programmer
Specialty Bakers, Inc.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top