473,472 Members | 2,140 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

unwanted blank space in tables

Buz
I am having a problem with extra, unwanted space showing
up on my web form tables. I've tried hand coding and can
get the htm file to display fine. But as soon as I bring
the form into Visual Studio, convert it to an aspx web
form, and insert my user controls, I start getting extra
blank space between my rows, even when I give an
explicit "height" attribute.

The problem seems to occur with tables that have rowspans
and/or user controls. It is extremely frustrating. I have
tried everything, but once Visual Studio gets ahold of
the form, the white space shows up.

Help would be greatly appreciated. Thank you.

Buz
Nov 22 '05 #1
4 2097
Hi Buz,

Did you have HTML Table in the form and your Web User control is in the
Table's Cell? Based on my experience, there may be some unwant blank lines
in this situation, due to the size of Web User control. Once it is
displayed in a cell, other cell in same row have to fit same height, this
may cause some unwant blank lines.

Would you please post some actual code which can reprodcue the problem
exactly? With them, we may try to find if there is other way to display the
control and table in proper mode.

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Nov 22 '05 #2
Hi Buz,

Did you have HTML Table in the form and your Web User control is in the
Table's Cell? Based on my experience, there may be some unwant blank lines
in this situation, due to the size of Web User control. Once it is
displayed in a cell, other cell in same row have to fit same height, this
may cause some unwant blank lines.

Would you please post some actual code which can reprodcue the problem
exactly? With them, we may try to find if there is other way to display the
control and table in proper mode.

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Nov 22 '05 #3


Well, you are right. I removed the three user controls in my 3 X 3 HTML
table and the problem resolved. I added back in my first user control, a
row-span of the first table column and there was still no problem. I
added in my second control (an Amazon.com link) which is a row span of
the bottom two cells of the right hand column and the problem partially
returned. I added back the third user control (a roll-over image link)
to the top right cell and the problem returned completely.

I expected the top row to expand to hold the user control, but the
expansion appears to be longer than the user control by a line or two.
Also, my left user contol does not "top" properely now.

Here is the HTML body:

<HTML>
<body>
<table width="100%" border="0" cellspacing="1" cellpadding="1">
<tr>
<td rowspan="3" width="148" valign="top">&nbsp;
<uc1:MLSideBar id="MLSideBar1" runat="server"></uc1:MLSideBar></td>
<td align="center" valign="middle"><img
src="Madame_librarian_banner.gif" width="544" height="128"></td>
<td width="130" valign="top" align="center">
<uc1:WordFairRollOver id="WordFairRollOver1"
runat="server"></uc1:WordFairRollOver>&nbsp;</td>
</tr>
<tr>
<td><div align="center"><font size="+2" face="Verdana, Arial,
Helvetica, sans-serif"><strong>Link Lists</strong></font></div></td>
<td rowspan="2" valign="top">&nbsp;
<uc1:AmazonList id="AmazonList1"
runat="server"></uc1:AmazonSearch></td>
</tr>
<tr>
<td valign="top"><p><font face="Verdana, Arial, Helvetica,
sans-serif">Wording goes here</td>
</tr>
</table>
</body>
</HTML>

Now the user control:

<script language="JavaScript" type="text/JavaScript">
<!--
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++)
x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0;
i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image;
d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document;
if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++)
x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++)
x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array;
for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc)
x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
<TABLE id="tblWordFairRO" cellSpacing="1" cellPadding="1" width="152"
border="0">
<TR>
<td width="39" valign=top align="center"&gt;<a href="http://wordfair"
onMouseOut="MM_swapImgRestore()"
onMouseOver="MM_swapImage('wordfair','','../images/fair_tentsmall2.gif',
1)"><img src="../images/fair_tentsmall.gif" alt="Word Fair"
name="wordfair" width="150" height="155"
border="0"></A></td>
</TR>
<TR>
<TD>
<P align=center><FONT face=Verdana>Writing
Services</FONT></P></TD>
</TR>
</TABLE>

Sure appreciate you looking at this. Thank you.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 22 '05 #4
Hi Buz,

In the user control's table:

<TABLE id="tblWordFairRO" cellSpacing="1" cellPadding="1" width="152"
border="0">
You only specify the width not with height. If you set it to a proper
value, will the problem get better?

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Nov 22 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Steve K | last post by:
Hi, The site I've just created, when tested on a windows PC has an unwanted white space (about 2-4 pixels high) in between two tables. I would like there to be zero space there. Here is the test...
3
by: Brian | last post by:
I have a page with content, navigation, and footer divs, in that order. The nav div has position: absolute, width 8em, on green background. The other divs have an 8em green left border, such that...
3
by: Buz | last post by:
I am having a problem with extra, unwanted space showing up on my web form tables. I've tried hand coding and can get the htm file to display fine. But as soon as I bring the form into Visual...
0
by: John Dann | last post by:
I'm creating a Listview control in details view under VB.Net which always has 31 rows (populated at runtime) and 4 columns (ie 1 item plus 3 subitems) of specified width. But at runtime and...
16
by: lovecreatesbeauty | last post by:
/* When should we worry about the unwanted chars in input stream? Can we predicate this kind of behavior and prevent it before debugging and testing? What's the guideline for dealing with it? ...
3
by: Jeff Calico | last post by:
Hello everyone I am transforming an XML document to text, basically only outputting a small portion of it. When I run the following XSLT via Xalan's processor, I get a bunch of unwanted blank...
3
by: et | last post by:
How can I strip out unwanted characters in a string before updating the database? For instance, in names & addresses in our client table, we want only letters and numbers, no punctuation. Is...
5
by: Tom | last post by:
I am having a problem where an extra gap (whitespace, padding) appears in a table cell where I don't want it. The data fed in the table is via dynamic HTML, so the amount in the middle cell may...
1
by: muthurama | last post by:
How to remove the unwanted space between two tables in the HTML
3
by: Joe Stateson | last post by:
I have a template field that contains filenames that are (or can be) on a unix system. The hypen (and others) is a valid filename character in unix. When I display the name of the file I get an...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.