Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid
Message
From
04/11/1997 10:22:36
George Alexander
Qatar Armed Forces
Doha, Qatar
 
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Re: Grid
Miscellaneous
Thread ID:
00057926
Message ID:
00058155
Views:
32
>>Hi, Anybody.
>>
>>I have a problem. I want to create a form with 1 to many relationship. Now when the user wants
>> to add data, depending on a value (say x), I want to create blank records into a cursor which
>>should become the record source.
>
>The key is to create the cursor in the load event of the form. This method is executed before the grid is created, so you can, at design time link the grid to it. If you create the cursor in the init event, you will get in trouble because the form.init is executed after the creation of the grid, so the latter will not be able to find its underlying record source.
>
>I "clone" the many table using afields. If you do this, make sure that leave out field 8 to .. (I think it is 15), because otherwise you will have problems with triggers, referencial integrity and other shmiggers ...
>
>Some will say that you can achieve the same with table buffering, and they are probably right, but I'm doing it the way I described. My whole framework, is based on it.
>
>HTH,
>
>Marc

Hi, Marc.

Thank you for the help. But the problem is I am a little dumb with VFP. My situation is the form is running. The
user clicks the ADD button. In the click event of the ADD button I want to creat an updatable cursor with
a previously known no. of blank records which the user will fill and then after validation I can Insert into the
many table.

Is this situation possible. BTW I didn.t understand the difference between having the grid source in the Load
and Init event? If I am not too demanding can I get a little more light on the stuff.

thanks a lot

alex
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform