Solved

Link Subform to Mainform Combobox

Posted on 2013-05-11
4
647 Views
Last Modified: 2013-05-11
I have a parent form which contains a Combo Box with the following SQL:

SELECT Mid(Claimant,InStr(1,Claimant," ")+1) AS Expr1, Strings.Claimant
FROM Strings
WHERE ((([Claimant] & "")<>""))
GROUP BY Mid(Claimant,InStr(1,Claimant," ")+1), Strings.Claimant
ORDER BY Mid(Claimant,InStr(1,Claimant," ")+1);


I want to link a Subform to the answer that the person chooses in the combo.
The Subform Contains Claimant, so I am trying to figure out how to link claimant.
0
Comment
Question by:seamus9909
[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
4 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 39158400
set the master/child link fields property of the subformcontrol

but, i think it is not a good thing using a part of the claimant field as the bound column of the combo box, as it is very possible to have duplicate values.

do you have a unique id field for claimants?
it will be best to use the unique id as the bound column of the combo box.
0
 

Author Comment

by:seamus9909
ID: 39158411
I want each record that contains the name Claimant to show in the subform, so its good if there are duplicate values.

I am not sure what the values should be in the subformcontrol however.

Master:  Combo171 ?  How do I pick the correct column being returned in the combo box?
0
 
LVL 29

Expert Comment

by:IrogSinta
ID: 39158483
The Bound Column property of the comboBox determines the column being returned.  In your case, setting it to 1 will return Expr1 and setting it to 2 will return Claimant.
bound column
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 39158591
<I want each record that contains the name Claimant to show in the subform, so its good if there are duplicate values.>
please explain



in your expression

Mid(Claimant,InStr(1,Claimant," ")

this will return possible duplicates, i.e.,

with the claimant names

jack smith
john smith
ann smith
dave clark
kent clark
etc..
"smith" will all be listed three times as items in your combo box
"clark" will be listed twice

but this can be eliminated to display as single items respectively
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

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

In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.

734 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