Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

DataGrid control

Posted on 1999-08-03
7
Medium Priority
?
235 Views
Last Modified: 2011-09-20
I have a datagrid bound to an adodc (data control) which accesses an Access database. I want to colour every row a light green colour/color if a field in the record contains a certain value. The other records would be left as they are. How do I do this ?
0
Comment
Question by:YourMajesty
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 22

Expert Comment

by:ture
ID: 1529160
YourMajesty,

I'm sorry. As far as I can see, there is no way to change the color of individual cells or rows in a DataGrid.

Ture Magnusson
Karlstad, Sweden
0
 
LVL 2

Expert Comment

by:Pepster
ID: 1529161
You can do this in an MS Flexigrid which is a much better control but you have to code in DAO rather than use controls.
0
 
LVL 22

Expert Comment

by:ture
ID: 1529162
Or use MS Hierarchical (?) FlexGrid control, which allows ADO connections.

/Ture
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 26

Expert Comment

by:EDDYKT
ID: 1529163
I don't think you can do it on MS FlexGrid control neither.

0
 
LVL 2

Expert Comment

by:Pepster
ID: 1529164
You can:

With MSFlexGrid1
    .Row = 1
    .Col = 1
    .CellBackColor = vbBlue
End With
   
0
 
LVL 3

Accepted Solution

by:
gajendra earned 600 total points
ID: 1529165
DataGrid does not coloring of individual rows/cells.

I have tried the same with the FlexGrid, it does support formatting for individual cells. In the FlexGrid you are not allowed to specify a condition where the grid automatically, you have to write code to check the value yourself and update the formatting yourself.

I have read the specs of the Apex TrueGrid has promises support for this kind of work. It does sound tempting but I have not used it yet. It has the extra cost tag attached to it.

HTH

Gajendra
0
 
LVL 1

Expert Comment

by:Moondancer
ID: 6872154
GREETINGS!

This question was awarded, but never cleared due to the JSP-500 errors of that time.  It was "stuck" against userID -1 versus the intended expert whom you awarded.  This corrects the problem and the expert will now receive these points; points verified.

Please click on your Member Profile and select "View Question History" to navigate through any open or locked questions you may have to update and finalize them.  If you are an EE Pro user, you can also choose Power Search to find all your open questions.

This is the Community Support link, if help is needed, along with the link to All Topics which reflects many TAs recently added.

http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt
http://www.experts-exchange.com/jsp/zonesAll.jsp
 
Thank you,
Moondancer
Moderator @ Experts Exchange
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question