Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Invalid subscript error
Message
From
30/09/1999 02:49:14
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
29/09/1999 13:35:32
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00270497
Message ID:
00270896
Views:
24
>Hi Cetin:
>
>Sorry to be a pest,
>
>I ommitted the original code you gave me, used the code from the last thread,
>and I get an error when I add the iif statement a get error:
>
>the data object must be a variable resource -
>
>I put lnsincolumn = 1
> lnsurnamecolumn =2
>in the init of my form and iif statement in controlsource for column.
>
>function surdesc - I placed with all my other functions.
>
>checked typing and ok,
>
>I sometimes get an error like this when function undefined in my
>functions file, but this is not the case here.


Oh my god this was the shower :) Till from start when reading I totally skipped that this is a matter of grid :) There seems to be forgotten quotes surrounding "iif()".
Using arrays in grid sometimes tricky. I would suggest another easier way then :
select gidetail.sin, client.surname,client.firstname, client.phone1;
 from gidetail, client;
 where gidetail.sin = client.sin;
 and gisum.sessionkey = gidetail.sessionkey;
 into cursor aclient nofilter
index on sin tag sin
select gidetail
set relation to sin into aclient
with thisform.myGrid.Columns(2)  && Recordsource = gidetail ?
  .controlsource = "aClient.Surname"
  .readonly = .t.
endwith
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform