Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
.Dataenvironment.AddObject & Buffering
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00063231
Message ID:
00063349
Views:
91
The 100 name files have the same structure, but the files which they will be manipulating have different structures.
>>>>>>>
>>>>>>>No you can set up buffering manually as well as through the DE.
>>>>>>>
>>>>>>>You could using an alias. Add the table to the DE and then when you select table just alias it always with the same name of the table you added to the DE.
>>>>>>>I'm sorry, I didn't spend enough time reading through your message to Garrett whether this is a possible solution or not.
>>>>>>
>>>>>>The problem is that it's not actually using the file when it's added to the environment. ie:
>>>This thread is really big, and I don't know what is inside it, sorry. However, may I ask you silly question: do you open 'Cli_name' table programmatically (USE...) somewhere?
>>
>>No, it's not used anywhere else.
>>
>>JR
>
>But you should open table, either by USE..., or better issuing DE.Opentables (after you set Cursor.Alias property).

Here's the code:

WITH Thisform
WITH .Dataenvironment
.Addobject([Cli_name],[Cursor])
.Cli_name.Buffermodeoverride =2
.Cli_name.Alias="Cli_name"
.Closetables
.Opentables
ENDWITH
.Field_name.ControlSource =[Cli_name.Field_name]
.ChkField_core.ControlSource=[Cli_name.Field_core]
.ChkField_mand.ControlSource=[Cli_name.Field_mand]
.SpnField_len.ControlSource =[Cli_name.Field_len]
.SpnField_dec.ControlSource =[Cli_name.Field_dec]
.NameFile =[Cli_name]
.MainFile =[Clients]
.CboFilename.Value =[Clients]
.Objsrefresh
ENDWITH

Note that I'm (in this order): Adding the cursor Cli_name to the environment, setting the buffer, creating the alias for it, closing the tables, then opening the tables.

JR
CLARC Services, Inc.
3500 Tamiami Trail
Port Charlotte, FL 33952
www.clarc.com
(941) 743-0108
(800) 246-5488
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform