Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Updating a view column that is an expression
Message
From
08/03/2018 13:51:00
 
 
To
08/03/2018 13:17:16
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012 R2
Network:
Windows Server 2012 R2
Database:
Visual FoxPro
Application:
Desktop
Virtual environment:
VMWare
Miscellaneous
Thread ID:
01658618
Message ID:
01658628
Views:
44
Exactly right - I only posted back the change to see if issuing the DBSETPROP() would allow me to post back to that field - because yes, the view designer, even if I change the value to .T. for updatable, it changes it back to .F. before updating the dbc.

So I am going to switch to a programatically created view since I have to set the property on this calculated field(s) anyhow and it would save changing the view in the VD and then me forgetting to issue the commands for each field after the fact.

So I still have to leave my code in to encrypt the fields in the view just before doing the tableupdate(). There is no other way to fire encrypting them just before the tableupdate happens (i.e. no built in way to fire some code).

I have never used the cursoradaptor class - are there methods in there that fire just before a tableupdate? I looked in help and it seems that a BeforeCursorUpdate() fires where I could put code. But I am not sure if I am barking up the wrong tree as I use a data environment where views are loaded (the old fashioned way). I would have to find some examples on how to a) attach a cursoradaptor to the DE and then make it work - without changing anything in the rest of the form(s) as this all works within a framework (VMP).

Albert

>But not encrypted, eh? Because you circumvented your own method - if I got that right, that's the field which holds the encrypted value, and your calculated field holds the unencrypted. Now if you got two fields in the view updating to the same field in the source tables, it's a matter of who writes last.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform