Solved

How to set DataGrid window color

Posted on 2002-07-04
1
302 Views
Last Modified: 2006-11-17
Does anyone know how to set the window background color of a datagrid control?  This is the color of the area between the control border and the grid of cells.  DataGrid1.BackColor sets the background color of the cells and not of this area.  Please provide code if you can.

I suspect

 SendMessage(DataGrid1.hWnd, theMessageID, 0, theCOLOREFColor)

along with OleTranslateColor() to convert the VB color to RGB is the way to do it but I don't know theMessageID to change the window color.

Actually I would like to set the background color to that of the content area of an MDI child window.
0
Comment
Question by:ASP_Ray
[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
1 Comment
 
LVL 4

Accepted Solution

by:
TomLaw1999 earned 75 total points
ID: 7132576
I believe that the correct answer is that you can't. The datagrid supplied with visual basic is really a stripped down version of a commercially available grid and many of the functions are not available.

There are several commercial options available i.e Truegrid etc. and I am sure that one of these would serve your purpose.
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

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

Suggested Solutions

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

736 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