Solved

Dbgrid with dbcombobox as a column

Posted on 2002-04-05
7
270 Views
Last Modified: 2010-04-04
I am writing an application which uses a dbgrid and
trying to align dbcomboboxs with each row in the grid.

What would be great is if there were a component that would allow me to assign a column as dbcomboboxs and each
cell in that column would allow me to make a selection based upon the info supplied from another column.  

Is there anything like this?  If not does anyone have a suggestion on an easier way to approach this.
0
Comment
Question by:brettawv
  • 4
  • 2
7 Comments
 
LVL 27

Accepted Solution

by:
kretzschmar earned 200 total points
ID: 6921245
you can define lookup-fields in your dataset,
where you can define another dataset as lookupsource

the dbgrid will show then for this field
a combobox at editmode

meikl ;-)
0
 
LVL 3

Expert Comment

by:VSF
ID: 6921423
Double click your dataset,
add the fields you want
select the field you want to contain a dbcombobox
and set its lookup properties to the query that will fill the combobox lines!

Hope it helps!
VSF
www.victory.hpg.com.br
0
 

Author Comment

by:brettawv
ID: 6921659
I must not be setting up my lookup properties correctly because I still can't get it to work?  It doesn't show me a combobox.  Any ideas on what I'm missing.
0
Industry Leaders: 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!

 

Author Comment

by:brettawv
ID: 6922136
OK, I got it working, but it won't change my selection when I click on a different option.  Is there a setting I'm missing?
0
 
LVL 27

Expert Comment

by:kretzschmar
ID: 6924991
? what different option?
0
 

Author Comment

by:brettawv
ID: 6938872
Hi kretzschmar,

I was having problems because of the way I was linking tables together.  I abandoned using the combobox inside the grid and I am using a dblistbox to list my options.  Things seem to be working out ok.  I am giving you the points since you were responded first to my question.

Thanks for your help, maybe I can use this somewhere in the future.
0
 

Author Comment

by:brettawv
ID: 6938873
Thanks again.
0

Featured Post

Industry Leaders: 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!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Delphi Form ownership 4 124
Unique identifier on a terminal server (rdp) 4 71
Base1 Encode/Decode 3 85
Firemonkey BASS_Init into a thread 17 50
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

679 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