>Part of your problem is that you should be appending records with a pre-determined key values using INSERT INTO and not APPEND. For example, say that your table has a primary index on a field CKEYFIELD, you would either get the next key value from your keyid table or use something like sys(2015) to generate a unique value. If you use the latter your "ADD" method would be something like...
>
>STORE SYS(2015) TO m.ckeyfield
>INSERT INTO yourview (ckeyfield) VALUES (m.ckeyfield)
>
>Then to save you issue a TABLEUPDATE command.
I don't want to store a random value to the key. I want to store the sequential key that goes in automatically when I do an APPEND BLANK. I can't do INSERT INTO because I'm not inserting anything into it. If I try it, it will put a 0 in for the key field and then I'll get a duplicate key error. That's why I use APPEND BLANK.
>If you get an error while developing the form, you need to issue a TABLEREVERT command. In the form.LOAD method, you might want to have something like...
>
>ON KEY LABEL F12 =TABLEREVERT(.T.,"locations_by_client_number")
I'll try this. Thanks.
-Michelle
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only