Pages

Nov 5, 2012

How to set css for asp.net server controls globally.

Usually Asp.Net controls like textbox, button ,radio button, checkbox are seen as input controls with different types like text,submit,radio etc...

So to set the CSS for the server controls

/* Global font for server controls */

textbox
input[type="text"]
{
    font-family: Verdana;
    font-size: 10px;
      width:160px;
}

textbox with textmode = password 

input[type="password"]
{
      width:160px;
}


Multiline text box
textarea
{
    font-family: Verdana;
    font-size: 10px;
      width:165px;
}


// for radio button/ check boxes
label
{
    font-family: Verdana;
    font-size: 10px;
}

For list boxes
select {
      /*font-family:Arial,Verdana,sans-serif; */
      font-family: Verdana;
      font-size:10px;
      font-weight:500;
}
 
/* Global font for server controls */ 

Nov 1, 2012

Unable to update the EntitySet because it has a DefiningQuery and no element exists in the element to support the current operation.

This is the error occurs when there is no primary key set in the table for which you are trying to do some update operation.

Set the primary key for the table and update the Entity model and then try.