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

x
?
Solved

Formatting a DBComboBox

Posted on 1997-06-04
2
Medium Priority
?
305 Views
Last Modified: 2006-11-17
I have a DBcombobox with a listfield generated from an sql query, the list has multiple fields.

How can I format the list so the fields line up.
When the user makes a selection I only want a subset of the fields  from the selection to be displayed in the text portion of the combobox

       
0
Comment
Question by:pchahal
[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
2 Comments
 
LVL 1

Accepted Solution

by:
milton042297 earned 300 total points
ID: 1426854
You can use the simple vb combobox to make this task.
Take a look in this suppost code:
****************************************************************
set db = OpendataBase("MyDB",true,true)

set MySnap = DB.CreateSnapShot(Select * from myTable were MyField =" & "MyCriteria"

MySnap.Movefirst
while not MySnap.EOF
    myCombo.AddItem MySnap("MyField")
    MySnap.MoveNext

wend
*********************************************************************
I think that you can use this code to solve your problem.
0
 

Author Comment

by:pchahal
ID: 1426855
does this solve the formatting problem ? I need the  field columns in the list to line up as well as set the text portion to a particular field from the selection.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
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

688 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