Ask a Question related to ASP.NET Data Grid Control, Design and Development.
-
MA #1
Loosing css?
Hi all!
I have a problem with my datagrid and css.
To fill my grid, I have a database connection. The sql is partly built from
drop down lists (select * from myTable where id='ddl value'.
My problem is, that when I select something in my drop down and the page
reloads, there seems to be some odd spacing around the controls in the
cells.
I have set padding (left, right, bottom, top), cellpadding and cellspacing
to 0px but I canīt get ridd of it.
Im out of ideas here :(
Do you have any?
/Marre
MA Guest
-
Property is loosing value
Hello NG, I've created a custom component inherited from "System.Web.UI.Webcontrold.Button" and added a new String Property .... Private... -
onClick without loosing data
I have a page with several radio buttons. (Add, Deactivate). When I click on Add, an add form is displayed on a page and when and it works the... -
Loosing roles between two pages ?
Ok Thanks, Here is what i've found in MS Press literature and it's ok : If FormsAuthentication.Authenticate( _ txtNom.Text, txtMP.Text) Then... -
Problem with loosing top of windows
Sometimes when I am working on an image in PS7 the top blue title bar of the window gets up under the menu bar at the top of the page and I cant... -
Loosing things on stage?
Check the "Animate in background" option when you create the projector. Andrew -
Eliyahu Goldin #2
Re: Loosing css?
How are you laying the controls out? Are using Flow Layout? Using html
tables is the best way of keeping consistent layout when page changes.
Eliyahu
"MA" <news@.removethis.supremelink.se> wrote in message
news:357jpdF4j0cq2U1@individual.net...from> Hi all!
>
> I have a problem with my datagrid and css.
>
> To fill my grid, I have a database connection. The sql is partly built> drop down lists (select * from myTable where id='ddl value'.
>
> My problem is, that when I select something in my drop down and the page
> reloads, there seems to be some odd spacing around the controls in the
> cells.
>
> I have set padding (left, right, bottom, top), cellpadding and cellspacing
> to 0px but I canīt get ridd of it.
>
> Im out of ideas here :(
>
> Do you have any?
>
> /Marre
>
>
Eliyahu Goldin Guest
-
MA #3
Re: Loosing css?
Well, itīs inside the grid cell.
Lets say i have two rows in a cell. After the postback, the space between
those rows are bigger. Iīm confused ;)
/Marre
"Eliyahu Goldin" <removemeegoldin@monarchmed.com> wrote in message
news:uDi12Fl$EHA.3336@TK2MSFTNGP11.phx.gbl...> How are you laying the controls out? Are using Flow Layout? Using html
> tables is the best way of keeping consistent layout when page changes.
>
> Eliyahu
>
> "MA" <news@.removethis.supremelink.se> wrote in message
> news:357jpdF4j0cq2U1@individual.net...> from>> Hi all!
>>
>> I have a problem with my datagrid and css.
>>
>> To fill my grid, I have a database connection. The sql is partly built>>> drop down lists (select * from myTable where id='ddl value'.
>>
>> My problem is, that when I select something in my drop down and the page
>> reloads, there seems to be some odd spacing around the controls in the
>> cells.
>>
>> I have set padding (left, right, bottom, top), cellpadding and
>> cellspacing
>> to 0px but I canīt get ridd of it.
>>
>> Im out of ideas here :(
>>
>> Do you have any?
>>
>> /Marre
>>
>>
>
MA Guest
-
Ken Cox [Microsoft MVP] #4
Re: Loosing css?
Could you show us a sample of the HTML that is rendered? It is possible that
ASP.NET is inserting a SPAN tag that needs to be accounted for.
"MA" <news@.removethis.supremelink.se> wrote in message
news:357jpdF4j0cq2U1@individual.net...> Hi all!
>
> I have a problem with my datagrid and css.
>
> To fill my grid, I have a database connection. The sql is partly built
> from drop down lists (select * from myTable where id='ddl value'.
>
> My problem is, that when I select something in my drop down and the page
> reloads, there seems to be some odd spacing around the controls in the
> cells.
>
> I have set padding (left, right, bottom, top), cellpadding and cellspacing
> to 0px but I canīt get ridd of it.
>
> Im out of ideas here :(
>
> Do you have any?
>
> /Marre
>Ken Cox [Microsoft MVP] Guest
-
MA #5
Re: Loosing css?
Hi!
Sorry for not answering erlier.
A gridcell looks like this after a postback:
<td><nobr><div class='calendar_cell' title='text: text
text1: 1
text2: 2
text3: 3
text4: 4
--------------------------------------------
' alt='text: text
text1: 1
text2: 2
text3: 3
text4: 4
--------------------------------------------
'>my text 1</div></nobr><nobr><div class='calendar_cell' title='text: text
text1: 1
text2: 2
text3: 3
text4: 4
--------------------------------------------
' alt='text: text
text1: 1
text2: 2
text3: 3
text4: 4
--------------------------------------------
'>my text 2</div></nobr></td>
As you can see, there is a lot of text inside the title and alt. But this
text is there even before the postback.
I have tried to put this text in my calendar_cell-class:
..calendar_cell
{
cellpadding: 0px;
cellspacing: 0px;
padding: 0px 0px 0px 0px;
padding-bottom: 0px;
padding-left: 0px;
padding-right: 0px;
padding-top: 0px;
}
But it?s not working at all!
/Marre
"Ken Cox [Microsoft MVP]" <BANSPAMken_cox@sympatico.ca> wrote in message
news:eW3A9JBAFHA.1400@TK2MSFTNGP11.phx.gbl...> Could you show us a sample of the HTML that is rendered? It is possible
> that ASP.NET is inserting a SPAN tag that needs to be accounted for.
>
> "MA" <news@.removethis.supremelink.se> wrote in message
> news:357jpdF4j0cq2U1@individual.net...>>> Hi all!
>>
>> I have a problem with my datagrid and css.
>>
>> To fill my grid, I have a database connection. The sql is partly built
>> from drop down lists (select * from myTable where id='ddl value'.
>>
>> My problem is, that when I select something in my drop down and the page
>> reloads, there seems to be some odd spacing around the controls in the
>> cells.
>>
>> I have set padding (left, right, bottom, top), cellpadding and
>> cellspacing to 0px but I canīt get ridd of it.
>>
>> Im out of ideas here :(
>>
>> Do you have any?
>>
>> /Marre
>>
MA Guest



Reply With Quote

