Excess Space Top and Bottom of big text - css

I am working with text in C#. my problem is with big texts. In a big text I have a space at top and bottom of it.
How can I clear this space via CSS?
<asp:Label ID="Label16" runat="server" Text='<%# Eval("Home_Club_Goal") %>' Font-Bold="true" Font-Size="200px" />

Try to use "line-height" property.
http://www.w3schools.com/cssref/tryit.asp?filename=trycss_line-height

Related

Tooltip in ASP.NET image button is not working properly in chrome

Image button tooltip is showing as text in chrome
<asp:ImageButton ID="btnHelp" runat="server" AlternateText="" ToolTip="Help" />
Here Help is showing as a text.
The closest I can get to the correct behavior is by setting AlternateText to a space:
<asp:ImageButton ID="btnHelp" runat="server" AlternateText=" " ToolTip="Help" />
By the way, the behavior in Firefox is even more interesting: when AlternateText is empty, some text is displayed but I have no idea where it comes from. As is the case for Chrome, setting AlternateText to a space solves the problem.

Html in RadGrid Footer

Could someone tell me how to put some html into RadGrid footer? I need to put it not into column footer, but to one for entire grid.
<telerik:RadGrid ID="radGrid" ShowFooter="true" runat="server" AutoGenerateColumns="false">
<MasterTableView>
<Columns>
<telerik:GridBoundColumn DataField="Name" HeaderText="Name">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Position" HeaderText="Position">
</telerik:GridBoundColumn>
</Columns>
</MasterTableView>
<FooterStyle BorderWidth="10px" BorderColor="Red" />
</telerik:RadGrid>
There is no <FooterTemplate> tag for "global" footer, so maybe somebody knows the elegant way to do it?
Yeah, I didn't see that as an option. The only thing I can think of, which I haven't verified, is:
Try to set a column span on the first column's cell; the RadGrid is essentially a table-based structure, and on itemcreated or itemdatabound, when the row type is a footer, you could try setting the column span on that cell.
You could try hiding the default footer, and put your own DIV at the bottom of the grid, with your additional contents. You should be able to place a DIV right against the bottom of the grid.

Datalist items display when based on number of items

I am using DataList control in ASP.net application. I have set
DataList1.RepeatColumns = 3;
DataList1.RepeatDirection = RepeatDirection.Horizontal;
properties of DataList. When item count is more than 3 it shows up properly. However if it is less than 3 it distorts and occupies whole space.
e.g. if there is only 1 item, it takes complete width and distorts UI.
if $$$ is one item, for 3 it shows like,
$$$|$$$|$$$
for one item it shows like
$$$$$$$$$$$
and UI disturbs completely.
Is there any way to format display in proper manner?
As lcarus mentionned, try setting ItemStyle-Width property. Here is a snippet which worked for me:
<asp:DataList ID="myDataList" runat="server" RepeatColumns="3" HorizontalAlign="Center" RepeatLayout="Table" RepeatDirection="Horizontal">
<ItemStyle Width="33%" />
<ItemTemplate>
<your code here>
</ItemTemplate>
</asp:DataList>
When requiring 3 columns, set the column width to 33%.
Try setting the ItemStyle-Width property to the desired width. I would expect it to set the width of each item to the exact size you set it to: Here's a link to MSDN documentation: http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.datalist.itemstyle.aspx

Textbox not displaing all the text?

I have a telerik RadTextBox, in which i want to display one line, the problem the content is a little bit scrolling and don't display all the text, how can i fix it. thanks in advance.
try to use textmode="singleline"
<telerik:RadTextBox runat="server" ID="txtbox1" TextMode="SingleLine"></telerik:RadTextBox>

Text - empty text node Problems

I have asp.net buttons rendered on the browser which are in different lines. I assume this Text- Empty text node is because of that. Since buttons are displayed in different lines, on the all the browsers I noticed a small space. How can I clear this? I dont have any css that adds this space.
If I remove the line spacing in the editor. I dont see any space, but i can't do it because of the formatting the code.
<asp:Button runat="server" ID="btnButton1" text = "Button1"/> <asp:Button runat="server" ID="btnButton1" text = "Button1"/>
If you want the buttons to be positioned next to each other, with no space in between them, you can consider using the CSS float rule:
<div style="overflow: auto">
<asp:Button runat="server" style="float: left" ... />
<asp:Button runat="server" style="float: left" ... />
</div>
The <div> element will contain both buttons, and any elements after it will be on a new line. The buttons inside the <div> will move as far left as possible, and no space will exist between them.
Demo (not ASP.NET, but works just as well): http://jsfiddle.net/vDWCn/1/

Resources