Solved

Change the display color of a datagrid

Posted on 2004-08-27
15
311 Views
Last Modified: 2010-04-17
Hi Experts,

I have a VB program that uses datagrid. I'd like to change the color of the datagrid ( not the forecolor or backcolor but the whole datagrid ).

thanks.

TJ
0
Comment
Question by:protugy
  • 8
  • 7
15 Comments
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917739
I believe what you want to do is change the backcolor and make the "CaptionVisiable" false.  
0
 

Author Comment

by:protugy
ID: 11917746
but if you do caption visible false, will the captions disappear?

0
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917763
yes--if u want to keep the caption--and have the datagrid all one color than just change the backcolor and the captionbackcolor
0
 

Author Comment

by:protugy
ID: 11917773
the thing is I can't the change the color of the datagrid..

thanks.
0
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917785
what do u mean u can't change the color of the datagrid...click on the datagrid...go to the properties....and go to backcolor to change it.
0
 

Author Comment

by:protugy
ID: 11917790
if you do that, it will change the color of the datagrid rows.. not the datagrid display color..

0
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917800
you want to change the gridlinecolor?
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:protugy
ID: 11917805
I wanna change the color of the whole datagrid just like you change the color of a form

the default color is grey.. i wanna change it to something else.

0
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917830
right--and inorder to do that u need to change the backcolor.  If you want your captions to be the same color you would do the same-change the captionbackcolor.

I guess what i'm not understanding is u don't want to change the color of the datagrid rows.  Just the display color.  So from this I'm guessing that you want the default color of grey to be lets say orange.  In order to run your program and have the datagrid display orange, you would need to click on the datagrid, go to properties, and change the backcolor.
0
 

Author Comment

by:protugy
ID: 11917853
that's right.. I wanna keep the datagrid color rows as white. Now, just like you said, I went to properties and clicked on the color tab. There are only 2 choices; the forecolor and the backcolor. When I changed the backcolor, the color of the row changed not the background color..

sorry for the confusion!
0
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917867
if you leave your alternating back color as white, your rows will stay white and the backcolor will stay orange.
0
 
LVL 4

Expert Comment

by:computerg33k
ID: 11917874
also leave ur backcolor white--just your backgroundcolor should be the color that you want to be in the background
0
 

Author Comment

by:protugy
ID: 11917885
May I ask where I can change the alternating backcolor and backgroundcolor. Also FYI, I'm using VB 6.0.

thanks.
0
 
LVL 4

Accepted Solution

by:
computerg33k earned 50 total points
ID: 11917955
ah---now I see why this was taking longer than expected--I do not believe that you can do this function w/ out vb.net.  
0
 

Author Comment

by:protugy
ID: 11917963
ahh.. that sucks!

thanks anyway.. here are your points!

TJ
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
countX 22 84
firstswap challenge 20 68
groovy example issue 10 90
What are programming codes and how do they work? 7 75
Here we come across an interesting topic of coding guidelines while designing automation test scripts. The scope of this article will not be limited to QTP but to an overall extent of using VB Scripting for automation projects. Introduction Now…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

861 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

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now