I have a combo box that has in it a value. It's an unbound combo box that
gets populated based on SQL code being executed in the codebehind file.
What it displays now is a salesrep name. When you click on it, it selects
the correct field (repname, which is a code that is different than the
firstname, lastname that is displayed in the combo box).
I need to add something to the combo box in order to display the company
name in a format like the following:
(company) RepFirstname RepLastname
I don't want anything to change on the value that's being selected
(repcode), but just want to make the combo box look differently.
The SQL I have that gives me the appropriate field & formatting of it is:
select '(' + summarytable.ssalesgroup + ') ' as salesgroup1,
salesreptable.sDescription, salesreptable.srepcode from salesreptable inner
join summarytable on summarytable.ssalesrepcode = salesreptable.srepcode
and summarytable.ssalesgroup = salesreptable.ssalesgroup
group by summarytable.ssalesgroup, salesreptable.sDescription,
salesreptable.srepcode order by summarytable.ssalesgroup,
salesreptable.srepcode
The where clause gets populated based on some other combo box selections.
How do I get the (company) repdescription to display without changing what's
selected (which is sufficient in the select code). I only need to display
the company name in order to assist the users who work with a number of reps
and companies.
Thanks,
SC