Welcome! Log In Create A New Profile

Advanced

HModify()

Posted by John Marrone 
John Marrone
HModify()
January 25, 2010 11:07PM
Hi
I have a query I created in the visual designer and I work with the query in code. I do not have it in any type of window control. This is just some processing I do to the data. My question is this. If the query is not being used by any window control do I still need to do a ScreenToFile after I call HModify() to save the data. When I do a Hmodify I want the actual data file updated permanently and I am not using any window controls at all with the query data. The HModify is on the query, does this write to the file if you are not using any window controls. Or do I need to do a screen to file even though I am not using any window controls? The help file shows I need to use the screen to file but I don't see why.

Thanks for any help.
ICI
Re: HModify()
January 25, 2010 11:50PM
You don't need but then you need to do this (I think smiling smiley):
HRead(MyQuery)
MyQuery.Field1=Somevalue
MyQuery.Field2=Somevalue
and so on, and so on
HModify(MyQuery, hcurrentRecNum)

Also, You need to start query with HexecuteQuery(Myquery, hModifyFile)



Edited 1 time(s). Last edit at 01/25/2010 11:51PM by ICI.
DW
Re: HModify()
January 26, 2010 01:48PM
Hello John

Are you using the hModifyFile constant when you run your query?

DW
John Marrone
Re: HModify()
January 26, 2010 02:29PM
Yes DW, thanks

Thank you too ICI. Will try this. I'll let everyone know if it worked after I try it.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: