Login

  • Sign in with Intersoft Social ID
  • Sign in with Intersoft ID (Developer Network)
  • Sign in with Google ID
  • Sign in with Open ID. Click for more options.
Intersoft Social ID
Password
Intersoft Latest Learn More

Latest Development Blogs

Blog RSS
Loading
Retrieving News

Forum                   Topics  Post

HTML Style for BODY Tag changes colors in WebGrid

7 replies. Last post: December 22, 2010 12:45 PM by Douglas Badin
Rate this topic:
Average rating: Not rated yet.
Tags :
  • (None)

Hi,

When I add the Body Style Color to my pages, it cascades to the WebGrid and the Text is White in the WebGrid.

<style type="text/css">  
BODY
{
	COLOR: White;
}
</style>

 

What can I do to the InterSoft Controls so it doesn't pick up the BODY Styles?

Thanks,

Doug

Hi,

Would you please give me some code to set the WebGrid's font color that works completely?

I don't want to change the Body style, that is why I asked about the WebGrid.

It does not work when I set it in the WebGridColumn.  It only changes the displayed date.  When the Calendar is invoked, the normal calendar dates are still white.

<ISWebGrid:WebGridColumn
	Caption="EST_SHIP_DATE"
	CustomEditorName="VistaCalendar"
	DataFormatString="MM/dd/yyy"
	DataMember="EST_SHIP_DATE"
	DataType="System.DateTime"
	EditType="Custom"
	Name="EstShipDate_WebGridColumn"
	Width="100px"
>
	<CellStyle
		ForeColor="Black"
	/>
</ISWebGrid:WebGridColumn>

I can't even get the CalendarDropdown or CalendarCombo EditTypes to work

<ISWebGrid:WebGridColumn
	Name="DataIn_WebGridColumn"
	DataMember="COMPLETE_DATE"
	DataType="System.DateTime"
	EditType="CalendarDropdown"
	Caption="COMPLETE DATE"
	Width="70px"
	DataFormatString="MM/dd/yyyy"
>
</ISWebGrid:WebGridColumn>

When I try to invoke the Calendar I get:

An error occurred in the script on this page.

Line: 2789
Char: 34
Error: ASP.NET AJax client-side framework failed to load.
Code: 0

 

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.2; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; InfoPath.2; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
Timestamp: Thu, 16 Dec 2010 13:52:11 UTC


Message: Object required
Line: 7
Char: 1262
Code: 0
URI: http://localhost/NewCoServices/ISRes.axd?G/WebGrid_Calendar.js/707200405

 

What am I to do?

 

Doug

Hi,

This is also a problem with the Context menu for valid UI elements that  is invoked by Right Clicking on a row.

All the items have White Text:

- Add New Row
- Copy this Cell
- Copy this Row
- Copy this Table
- Edit
- Delete
- Refresh Grid
- Show Client Help

I tried putting the WebGrid in the following DIV but it did not help the pop ups.

<style type="text/css">  
BODY
{
	COLOR: White;
}
.Black
{
	COLOR: Black;
}	
</style>

<body>
    <form id="form1" runat="server">
    <div class="Black">
	<ISWebGrid:WebGrid
...
	</ISWebGrid:WebGrid>
    </div>

Putting it in a table instead of a <div> with the cell having a Black Class <td class="Black"> did not help.

Doug

Hi Douglas,

Could you please try the following code of CSS:

        div *
        {
            color: Black;
        }

Unfortunately, the context menu also belong to the div but if you see it on the structure it wont give you which div is containing the context menu.

For the mean time, please try the following workaround. But I will discuss this matter with the developer and will let you know as soon possible.

Thank you and have a nice weekend.

Regards,
Niven.

Hi,

That will not work for my situation.

Changing the DIV Style has the same impact as changing the BODY Style.  While if helps the WebGrid Pop Ups, it makes everything outside the WebGrid have Black Text.

I need something with a WebGrid Scope and not a Global Scope.

Also, it did nothing to help the EditTypes CalendarCombo and CalendarDropdown.

 

Martin LieSupport

Hello Doug,

To prevent the WebGrid to get impact with the BODY css class, you need to use Css Class Selector to set the WebGrid's color to black based on all elements inside the main Grid's DIV.

Try the following code:

<style type="text/css">
        BODY
        {
            color: White;
        }
        
        #WebGrid1_of > *
        {
            color: Black;
        }
        
        #ISPopup_0 > *
        {
            color: Black;
        }
        
        #ISPopup_1 > *
        {
            color: Black;
        }
        
        #ISPopup_2 > *
        {
            color: Black;
        }
</style>

By using the code above, WebGrid will stay in its normal state.

Hope this helps.

 

Thank you.

Hi,

That works.

Thanks,

Doug

All times are GMT -5. The time now is 3:06 PM.