Shop OBEX P1 Docs P2 Docs Learn Events
LOOKUP with ()'s and []'s — Parallax Forums

LOOKUP with ()'s and []'s

YendorYendor Posts: 288
edited 2006-09-30 01:29 in General Discussion
Hi Bean,

Glad to see I'm winning!· [noparse]:o[/noparse])

I'm just making sure you'll be employed for a while!·

Another compiler question...Believe me, I'm not trying!!!

I just so happen, by mistake, put brackets around the data of the LOOKUP command as I was adapting·some PBASIC code to SX/B, and the compiler liked it.

LOOKUP Index, [noparse][[/noparse]Con1, Con2, Con3, Con4, Con5, Con6, Con7],·myVar· 'Compiles, Doesn't work
LOOKUP Index, (Con1, Con2, Con3, Con4, Con5, Con6, Con7), myVar· 'Compiles, Doesn't work
LOOKUP Index, Con1, Con2, Con3, Con4, Con5, Con6, Con7,·myVar· 'Compiles, works

Should the compiler complain with the constant's aren't defined, or are·the ()'s useful in the LOOKUP?

Thanks again!

Rodney

Comments

  • BeanBean Posts: 8,129
    edited 2006-09-30 01:29
    Rodney,
    I will look at it, it should throw a compiler error.

    You are indeed the best bug catcher.
    Are you interested in being one of the beta testers ?

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cheap used 4-digit LED display with driver IC·www.hc4led.com

    Low power SD Data Logger www.sddatalogger.com
    SX-Video Display Modules www.sxvm.com

    There are only two guaranteed ways to become weathy.
    Spend less than you make.
    Make more than you spend.
    ·
Sign In or Register to comment.