Normal Topic XListValues (Read 445 times)
FSGROUP
Full Member
***
Offline


No personal text

Posts: 179
Location: Edmonton, Alberta, Canada
Joined: Jan 14th, 2004
XListValues
Mar 24th, 2004 at 11:19pm
Print Post Print Post  
if i have a combo box named ParentName and the following code in a subform, and I want to reference LastName in the Main form, will the following not work?

var str1 as String
str1=@Xlistvalues("CMS.db", "Main!LastName")
PopulateListElement(ParentName,str1)

I keep getting a blank value for ParentName.







  
Back to top
IP Logged
 
The Cow
YaBB Administrator
*****
Offline



Posts: 2530
Joined: Nov 22nd, 2002
Re: XListValues
Reply #1 - Mar 25th, 2004 at 1:21pm
Print Post Print Post  
Could you drop a writeln in to print the value of "str" before you place it in the Combo Box?

Also, when you say you get a blank value - do you mean that the combo box list is blank, or that the "selected value" of the combo box is blank?

Also, is ParentName in the main form? Subform? Table View Subform?

Also, is CMS.db the same .db as is code? If so, why not use @fn? If not, maybe use the full path - just to avoid confusion.

You mention that this code is in a subform and that you want to reference ParentName from the main form - yet there is no code included to illustrate that. So when you say, ParentName is blank - is that something you are seeing on the form, or is there other code elsewhere trying to access it from the main form?
  

Mark Lasersohn&&Programmer&&Lantica Software, LLC
Back to top
IP Logged