Sign up on the Revelation Software website to have access to the most current content, and to be able to ask questions and get answers from the Revelation community

At 23 MAY 2001 05:48:04PM b cameron wrote:

I've read a lot of threads regarding comparing records using @RECORD

and OREC (btw-is OREC a global or common insert variable??) and have

put some of the coding and comments together and need some advice.

I will have a commuter mod/promoted mod that for a READ event

on a form…

Forward_Event()

record=Get_Property(@window,"RECORD")

Set_Property(@window,"@ORIG_RECORD")

then for a SAVE event for a form….

Call TRANSACTION_LOGGER()

*

Subroutine Transaction_Logger(void)

*

* Clean edittable values

*

Ctrls=Get_Property(@Window,CtrlMap$)

CtrlCnt=Count(Ctrls,@fm) + (Ctrls # Null$)

For CtrlPntr=1 to CtrlCnt

 Type=Get_Property(@Window:".":Ctrls,Type$)
 If Type=EDITTABLE" THEN
    Lines=Get_Property(@Window:".":Ctrls,"ARRAY")
    Count=Count(Lines,@VM)+(Lines # "")
    Fknt=Count(Lines,@FM)+1
    Loop
    Until Count=0 or Len(Lines)
       Count-=1
    Repeat
  • Trim blanks out
    For I=1 to Fknt
       Lines[i]=Field(Lines[i],@VM,1,Count)
    Next I
    Set_Property(@Window:".":Ctrls,"ARRAY",Lines)
 End

Next CtrlPntr

* Get the orig and "now" record values

Record=Get_Property(@Window,"RECORD")

Orig_record=Get_Property(@Window,"@ORIG_RECORD")

Now do the comparing and update my transaction file.

1) am I way off base here?

2) do I need the code in the read or does OI handle the @ORIG_RECORD?

3) how do I get find out what the datafile is for a bound form?

Thanks for any response.

BC


At 24 MAY 2001 11:21PM WinWin/revelation support wrote:

Bruce:

look at the help for orig_xxx, see if that gives you what you want.

To get the bound table, look at the TABLE property of one of the controls (assuming single table form)

Hope this helps.

Bob


At 25 MAY 2001 04:34AM Oystein Reigem wrote:

Bruce,

Here's a suggestion by Carl Pates for how to find the bound table: . This method is more general since you don't have to know the name of a bound control, or search through controls to find a bound one. Note: Read the next posting too, since Carl's posting contained a small mistake.

- Oystein -

View this thread on the forum...

  • third_party_content/community/commentary/forums_nonworks/904d0760ff4235a985256a550077c202.txt
  • Last modified: 2023/12/28 07:40
  • by 127.0.0.1