473,385 Members | 1,553 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Grid edit item : what gives some bound columns a back colour ?

Hi there,

For some reason, when I edit row in my datagrid, some columns have (an
unwanted) back color of yellow, while others correctly display with white
back color.

I can see no setting in my datagrid that could do this...

How can I stop this from happening ?

Thanks,

Bazza
Nov 19 '05 #1
9 1443
And one more hint...

The columns with yellow background also have a sunken/recessed look to the
boarder of the editable item.

Thanks,
Bazza

"Bazza Formez" <ba**********@paradise.net.nz> wrote in message
news:Tr********************@news02.tsnz.net...
Hi there,

For some reason, when I edit row in my datagrid, some columns have (an
unwanted) back color of yellow, while others correctly display with white
back color.

I can see no setting in my datagrid that could do this...

How can I stop this from happening ?

Thanks,

Bazza

Nov 19 '05 #2
"Bazza Formez" <ba**********@paradise.net.nz> wrote in message
news:zu********************@news02.tsnz.net...
And one more hint...

The columns with yellow background also have a sunken/recessed look to the
boarder of the editable item.


Bazza,

As I suggested in a reply to an earlier question from you: it's all in the
HTML. Take a look with View Source.

Chances are that you have an EditItemStyle set which is causing the effect,
but take a look in detail at what attributes are set on which columns, and
you'll see.

I often find it helpful to take the results of View Source and save them to
a file which I can view in Visual Studio. The Format Document command can
help me make much more sense of a mess of HTML. This is especially true in
VS2005, where the HTML view is much more helpful. You may also find the
Document Outline helpful.

John Saunders
Nov 19 '05 #3
Thanks for that John.. but I am still completely puzzled. I looked at the
HTML vis VS as you suggested, but cannot spot anything that could render the
backgorund I am seeing in threee of the editable fields... It seems to be
the browser going awry to me...

I just tried cutting and pasting that same HTML into this message to show
you... and the new client rendered it correctly before my eyes...

On my IE6 browser, the same HTML below renders with yellow background for
the email, phone & ext fields in the table below..

ID First Name Last Name User ID Password Email Phone Ext Fax Role
Update Cancel Delete 3
Very strange !

Tried same page with Firefox, and all ok.

Cheers,

Bruce
Nov 19 '05 #4
Try again with HTML:

<!--

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<title>WebForm1</title>
<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
<meta content="Visual Basic .NET 7.1" name="CODE_LANGUAGE">
<meta content="JavaScript" name="vs_defaultClientScript">
<meta content="http://schemas.microsoft.com/intellisense/ie5"
name="vs_targetSchema">
<LINK rel="stylesheet" href="//Labcheck/Styles.css" type="text/css">
<!--<LINK REL="stylesheet" HREF="../timbertest.css"
<STYLE>
@import url( www.timbertest.co.nz/timbertest.css );
</STYLE>-->
</HEAD>
<body MS_POSITIONING="GridLayout" link="#000000" vlink="#000000">
<form name="Form1" method="post" action="ClientContacts.aspx?ClientID=2"
id="Form1">
<input type="hidden" name="__EVENTTARGET" value="" />
<input type="hidden" name="__EVENTARGUMENT" value="" />
<input type="hidden" name="__VIEWSTATE"
value="dDw3MjM4MzAzMjQ7dDw7bDxpPDE+Oz47bDx0PDtsPGk 8MT47aTwzPjs+O2w8dDxAMDxwPHA8bDxFZGl0SXRlbUluZGV4O 1BhZ2VDb3VudDtfIUl0ZW1Db3VudDtfIURhdGFTb3VyY2VJdGV tQ291bnQ7RGF0YUtleXM7PjtsPGk8MD47aTwxPjtpPDE+O2k8M T47bDw+Oz4+Oz47Ozs7Ozs7Ozs7PjtsPGk8MD47PjtsPHQ8O2w 8aTwxPjs+O2w8dDw7bDxpPDI+Oz47bDx0PHA8cDxsPFRleHQ7P jtsPDM7Pj47Pjs7Pjs+Pjs+Pjs+Pjt0PHA8cDxsPFRleHQ7Pjt sPENhcnRlciBIb2x0IEhhcnZleSBQYW5lbHMgLSBNREY7Pj47P js7Pjs+Pjs+Pjs+ZuTzVjlPUO8ktySJ31AsbgT3rXQ="
/>

<script language="javascript" type="text/javascript">
<!--
function __doPostBack(eventTarget, eventArgument) {
var theform;
if (window.navigator.appName.toLowerCase().indexOf("m icrosoft") > -1) {
theform = document.Form1;
}
else {
theform = document.forms["Form1"];
}
theform.__EVENTTARGET.value = eventTarget.split("$").join(":");
theform.__EVENTARGUMENT.value = eventArgument;
theform.submit();
}
// -->
</script>

<TABLE id="Table1" style="Z-INDEX: 101; LEFT: 32px; WIDTH: 864px;
POSITION: absolute; TOP: 128px"
cellSpacing="1" cellPadding="1" width="864" border="1">
<TR>
<TD><table cellspacing="0" cellpadding="4" rules="all" border="1"
id="dgClientContacts" style="width:1050px;border-collapse:collapse;">
<tr align="Center"
style="color:#EEEEEE;background-color:Silver;font-family:Arial;font-size:10pt;">
<td>&nbsp;</td><td>&nbsp;</td><td style="width:10px;">ID</td><td>First
Name</td><td>Last Name</td><td>User
ID</td><td>Password</td><td>Email</td><td>Phone</td><td>Ext</td><td>Fax</td><td>Role</td>
</tr><tr valign="Top"
style="background-color:#EEEEEE;font-family:Arial;font-size:8pt;">
<td><a
href="javascript:__doPostBack('dgClientContacts$_c tl2$_ctl0','')">Update</a>&nbsp;<a
href="javascript:__doPostBack('dgClientContacts$_c tl2$_ctl1','')">Cancel</a></td><td><a
href="javascript:__doPostBack('dgClientContacts$_c tl2$_ctl2','')">Delete</a></td><td>3</td><td><input
name="dgClientContacts:_ctl2:_ctl3" type="text" value="Bruce "
/></td><td><input name="dgClientContacts:_ctl2:_ctl4" type="text"
value="Forbes " /></td><td><input
name="dgClientContacts:_ctl2:_ctl5" type="text" value="bf
" /></td><td>
<input name="dgClientContacts:_ctl2:_ctl6" type="text"
value="ecurb112 " />
</td><td><input name="dgClientContacts:_ctl2:_ctl7" type="text"
value="Br**********@paradise.net.nz " /></td><td><input
name="dgClientContacts:_ctl2:_ctl8" type="text" value="(07) 362 8011 "
/></td><td><input name="dgClientContacts:_ctl2:_ctl9" type="text"
value="6000 " /></td><td><input name="dgClientContacts:_ctl2:_ctl10"
type="text" /></td><td><input name="dgClientContacts:_ctl2:_ctl11"
type="text" value="1" /></td>
</tr>
</table></TD>
</TR>
</TABLE>
<span id="lblClientName" style="width:266px;Z-INDEX: 102; LEFT: 272px;
POSITION: absolute; TOP: 32px">Carter Holt Harvey Panels - MDF</span><span
id="Label1" style="Z-INDEX: 103; LEFT: 184px; POSITION: absolute; TOP:
32px">Contacts at </span>
<input type="submit" name="btnAddContact" value="Add Contact"
id="btnAddContact" style="Z-INDEX: 104; LEFT: 32px; POSITION: absolute; TOP:
32px" />
<a id="HyperLink1" href="Clients.aspx" style="Z-INDEX: 105; LEFT: 40px;
POSITION: absolute; TOP: 72px">Back to Clients</a></form>
</body>
</HTML>
"Bazza Formez" <ba**********@paradise.net.nz> wrote in message
news:7V********************@news02.tsnz.net...
Thanks for that John.. but I am still completely puzzled. I looked at the
HTML vis VS as you suggested, but cannot spot anything that could render
the backgorund I am seeing in threee of the editable fields... It seems to
be the browser going awry to me...

I just tried cutting and pasting that same HTML into this message to show
you... and the new client rendered it correctly before my eyes...

On my IE6 browser, the same HTML below renders with yellow background for
the email, phone & ext fields in the table below..

ID First Name Last Name User ID Password Email Phone Ext Fax Role
Update Cancel Delete 3
Very strange !

Tried same page with Firefox, and all ok.

Cheers,

Bruce

Nov 19 '05 #5

ID First Name Last Name User ID Password Email Phone Ext Fax
Role
Update Cancel Delete 3

Nov 19 '05 #6
Thanks for that John.. but I am still completely puzzled. I looked at the
HTML vis VS as you suggested, but cannot spot anything that could render the
background I am seeing in three of the editable fields... Very simple HTML
once seen in VS.
It seems to be
the browser going awry to me...I loaded the same page into Firefox, and
everything rendered as expect. Strange.

Thanks

Bazza
Nov 19 '05 #7
Out of curiousity, do you have the Google toolbar installed with the
Autofill option turned on?

It will color all fields yellow that it can fill in.

That is probably your problem.

Lowell


Bazza Formez wrote:

On my IE6 browser, the same HTML below renders with yellow background for
the email, phone & ext fields in the table below.. ID First Name Last Name User ID Password Email Phone Ext Fax Role
Update Cancel Delete 3

Nov 19 '05 #8
You may want to check that you dont have a form autofill tool (google
toolbar). This tools can change the controls display at time.

"Bazza Formez" wrote:
Thanks for that John.. but I am still completely puzzled. I looked at the
HTML vis VS as you suggested, but cannot spot anything that could render the
background I am seeing in three of the editable fields... Very simple HTML
once seen in VS.
It seems to be
the browser going awry to me...I loaded the same page into Firefox, and
everything rendered as expect. Strange.

Thanks

Bazza

Nov 19 '05 #9
Wow ! Thanks Lowell... Yes I have.... and it is new on this machine... I
didn't know that it did that.

"Lowell Heddings" <lo****@mindjunction.com> wrote in message
news:Oc**************@TK2MSFTNGP14.phx.gbl...
Out of curiousity, do you have the Google toolbar installed with the
Autofill option turned on?

It will color all fields yellow that it can fill in.

That is probably your problem.

Lowell


Bazza Formez wrote:

On my IE6 browser, the same HTML below renders with yellow background
for the email, phone & ext fields in the table below..

ID First Name Last Name User ID Password Email Phone Ext Fax Role
Update Cancel Delete 3

Nov 19 '05 #10

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

Similar topics

4
by: Filippo Pandiani | last post by:
I have a grid that shows the file list from a folder. On the postback, how do I get a Dataset from this grid? Thanks, Filippo.
14
by: John Doe | last post by:
Hi Is it possible to set the background colour of a grid based on a value in data? I guess that it is simple but I have been unable to figure it out. TIA
0
by: doronb | last post by:
hello my question is : i define dynamic columns to datagrid , 4 columns are databound and 1 columne is "edit template column" and only this col editable , i define function for update when...
4
by: Bazza Formez | last post by:
Hi there, What determines the sizes of rows / columns / cells when a grid is in edit mode ? When I click the edit command of a row item, the whole grid 'bounces' to a much larger size... and...
3
by: Tim::.. | last post by:
Can someone please tell me how I go about preselecting an item in a drop drown list when I click the Edit Command in a datagrid? I have tried the following but it doesn't work for me! I would...
1
by: Mad Scientist Jr | last post by:
can someone explain how to simply populate a grid in .net ? the way i understand it, there is no more msflexgrid, and instead is this new control that has to be tied to a dataset, and it is a real...
117
by: phil-news-nospam | last post by:
Is there really any advantage to using DIV elements with float style properies, vs. the old method of TABLE and TR and TD? I'm finding that by using DIV, it still involves the same number of...
10
by: Corey B | last post by:
I have a data grid that has three columns: First Name, Middle Name, and Last Name. The grid has a list of people with a blank row at the bottom of the grid (in the footer) that allows the user to...
1
by: rogerford | last post by:
I have a grid which i bind with values from Database. I have events to edit and update the grid. I am not using SqlDatasource to connect to DB. Rather i am doing the updating of the grid...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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...

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.