Solved

ComboBox derived from 2 datasources

Posted on 2009-04-01
4
216 Views
Last Modified: 2012-05-06
I have a Input ComboBox with the list bound to a sql binding source "bsStaffList" and I want to retreive and save the value from and to the customer binding source bsCustomerDetails - StaffID

Cant seem to work out how to do that. I['ve tried a few combo-nations :) no sucess so far.

Also tried values in  SelectedIndeax and SelectedValue with no sucess.

Can anyone help ?


Me.ipCbCSO.DataSource = "bsStaffList"
        Me.ipCbCSO.DisplayMember = "name"
        Me.ipCbCSO.ValueMember = "bsCustomerDetails - StaffID"  <<- ????

Open in new window

0
Comment
Question by:siacom
  • 2
  • 2
4 Comments
 
LVL 48

Accepted Solution

by:
jpaulino earned 500 total points
ID: 24045465
You cannot do that way!
You have do define the DisplayMember and ValueMember for the DataSource you have defined and not another one.
0
 

Author Comment

by:siacom
ID: 24045477
so you cant use 2 datasources ? 1 for dispolay and 1 for value ?
0
 
LVL 48

Expert Comment

by:jpaulino
ID: 24045504
No, you have to join the information in only one datasource
0
 

Author Comment

by:siacom
ID: 24045639
hmmm.... not something I want to do right now... might as well not have a combo.
thanks anyway.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Currency in SQL? 2 33
Visual studio 2015 1 22
SQL Select in Access 2003 3 29
MS SQL Conditional WHERE clause 3 19
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
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 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…
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…

820 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