mbdave
14th March 2007, 06:55
Hi

in MMT seesion i have sales order as main table session and sales order lines as satellite.

now after particular field say discount (tdsls401.disc) when user enters some value and tabs during thattime the line should get save and a new line should be inserted below it automaticlayy.

as it happens in LN std session for sales orders MMT.
i had tried to write

field.tdsls401.disc:
after.input:

execute(update.db)
execute(add.set)

but for some reason it enters two lines beolw with same position no.
can anyhelp me whether is any session or field property that does the above thing as in LN std sesion (tdsls4100m900).

ARijke
15th March 2007, 16:12
Hi, use the tools function enable.save.on.occ.change()

From the prog guide:
Syntax
void enable.save.on.occ.change()

Description
Use this function to force the 4GL Engine to save an occurrence at the time the user selects or moves to another occurrence. Any unsaved changes to the occurrence, will be automatically saved. I.e. the UPDATE.DB choice is executed and the 4GL engine will continue in the previous mode (MODIFY.SET or ADD.SET).

Notes
Use this function only in the after.form.read section.

Context
4GL library function.

mbdave
3rd May 2007, 08:18
Thanks


Its working very well.

rcorregidor
11th September 2008, 11:37
Hello,

I am trying to use the function enable.save.on.occ.change() but when I compile the program, it say me unresolvered reference to this function.

Do I have to use a library or something like that?

Thanks and regards.

sprasad
11th September 2008, 12:20
Hi,
I think this function is not vailable in Baan IV

There is another way

see this code:

field.A:
after.input:
execute(update.db)
execute(add.set)
to.field("B")

Here suppose A is last field and B is first field



Regards,
Sai Prasad

rcorregidor
11th September 2008, 13:10
Ok, Thank you very much.

nolihayati isma
17th June 2013, 10:45
tsrep124.plan:
after.input:
execute(update.db)
execute(add.set)
to.field("tsrep124.prin")

but i having error fatal error :
recursion not yet implemented
cannot continue tsrep124s001 in DLL :ottstpstandard

What is the mistake here...please assist.

Amit_Jain
15th July 2013, 18:52
Hi

Don't use 'to.field' that must be causing the recursion

Regards
Amit

nolihayati isma
17th July 2013, 03:59
Hi,

Tq.