Normal Topic please help (Read 4028 times)
billgordon
Junior Member
**
Offline


No personal text

Posts: 61
Joined: Dec 31st, 2003
please help
Jan 14th, 2005 at 8:55pm
Print Post Print Post  
My program tree looks like

Demoapp
----Forms
------Add Data
----------Contacts
---------------common
---------Stuff
---------------anotherform
--------Information
---------------Info
etc..


I am trying to use @xlookupsourcelist()

page 26 supplement 1.1


I am in the form info and am using on element exit from a field called company to match a field called coname in the form named common

When the company is exited I want to use @xlookupsourcelist() to return a number of fields (similar to the sample file sesame seasons using an @AccessStringArray

I am having troubles with the use of the @xlookupsourcelist()  I have


vInfo = @XLookupSourceList(@FN, Company, "Common!Coname", "first;co_street;co_city;co_State;co_Zip;co_Ship_street;co_Ship_City;co_Ship_Sta
te;co_Ship_Zip")


I have also tried
vInfo = @XLookupSourceList(@FN, Company, "contacts!Common!Coname", "first;co_street;co_city;co_State;co_Zip;co_Ship_street;co_Ship_City;co_Ship_Sta
te;co_Ship_Zip")

and also

vInfo = @XLookupSourceList(@FN, Company, "contacts!Coname", "first;co_street;co_city;co_State;co_Zip;co_Ship_street;co_Ship_City;co_Ship_Sta
te;co_Ship_Zip")


Should it be common or contacts in the form_name ext key section.

(I have declared my variables and have other programming for the @AccessStringArray)

When I use Writeln(vinfo) I get a blank box so I believe my
@XLookupSourceList(@FN, Company, "Common!Coname", "contactt;street;city;State;Zip;Ship_street;Ship_City;Ship_State;Ship_Zip")
Is not correct.

Any help would be great!
  
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2480
Joined: Aug 20th, 2003
Re: please help
Reply #1 - Jan 14th, 2005 at 9:27pm
Print Post Print Post  
The correct argument syntax is going to be "Common!CoName"

You will want to double check the following.
1. That you are not trying to test the code in preview mode. X Commands do not work in preview mode.
2. That "CoName" is the actual name of the element on the common form.
3. If you have security, double check that the X User name and Password is a valid user name and password for the application.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
Steve_in_Texas
Senior Member
*****
Offline


No personal text

Posts: 893
Location: San Antonio
Joined: Feb 21st, 2004
Re: please help
Reply #2 - Jan 14th, 2005 at 9:40pm
Print Post Print Post  
I believe I've seen the entire command fail if 1 element name is incorrect, or if you put a semicolon at the end of the line. (if I remember correctly)

It takes some practice.

Steve
  
Back to top
IP Logged
 
BOBSCOTT
Senior Member
Members
*****
Offline


That Darn Computer #$X#
{curse words}

Posts: 1195
Joined: Nov 22nd, 2002
Re: please help
Reply #3 - Jan 15th, 2005 at 12:56am
Print Post Print Post  
Bill,

Steve is absolutely correct if just 1 element name is incorrect the command fails. I have chased my tail for hours more then once because of a typo or I used the label name instead of  the element name.

Check it then check it again if it still does not work walk away and then check it again later.

  

Team – Together Everyone Achieves More
Back to top
 
IP Logged
 
Steve_in_Texas
Senior Member
*****
Offline


No personal text

Posts: 893
Location: San Antonio
Joined: Feb 21st, 2004
Re: please help
Reply #4 - Jan 15th, 2005 at 1:02am
Print Post Print Post  
Bob,

Thanks for the confirmation. Perhaps in a future version we'll see commands like this become a bit more forgiving.

I'd like to see the command return a blank value for the 1 bad LE name, rather than simply failling completely.

Just a thought.

Steve
  
Back to top
IP Logged
 
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: please help
Reply #5 - Jan 15th, 2005 at 3:16pm
Print Post Print Post  
Quote:
Thanks for the confirmation. Perhaps in a future version we'll see commands like this become a bit more forgiving.

[quote]I'd like to see the command return a blank value for the 1 bad LE name, rather than simply failling completely.


We consider silently returning bad information to be a bit too forgiving. You could enter/update hundreds of records before discovering that one of your values is always blank, and shouldn't be.

The way to troubleshoot an issue like this is to work on a simple case. If the lookup with a long list of LE names isn't working, then comment it out and try it with only one LE name. If the simple case works, then you can look for the typo in the long list. If the simple case doesn't work, then you know to look at other factors.

  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
Steve_in_Texas
Senior Member
*****
Offline


No personal text

Posts: 893
Location: San Antonio
Joined: Feb 21st, 2004
Re: please help
Reply #6 - Jan 15th, 2005 at 3:29pm
Print Post Print Post  
Erika,

Good point. Thanks for the explanation.

Steve
  
Back to top
IP Logged
 
billgordon
Junior Member
**
Offline


No personal text

Posts: 61
Joined: Dec 31st, 2003
Re: please help
Reply #7 - Jan 16th, 2005 at 4:39am
Print Post Print Post  
Quote:
Check it then check it again if it still does not work walk away and then check it again later.



I looked at the fields over and over and today I looked again and found my spelling error.

Thanks for the help
  
Back to top
 
IP Logged