dbTalk Databases Forums  

Script trigger : OnObjectModify

comp.databases.filemaker comp.databases.filemaker


Discuss Script trigger : OnObjectModify in the comp.databases.filemaker forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
MB
 
Posts: n/a

Default Script trigger : OnObjectModify - 10-26-2010 , 07:49 AM






Hello,

I'm using FMPA 11. I want to enter a value in a field. On these field I
wan't to connect a scripttrigger that launches a script when the content
of the field has changed.
I thought I could do this by by selecting "OnObjectModify" in de Set
Script triggers. My problem is the following.
Lets say in the field (number) you have the number 100. I want to enter
200 and since is different to 100 the "connected" script should be
launched. Problem is that the script is launched from the moment I
entered the first digit (in this case the 2).
Is there a way to launch the script when this content is different (and
only then) to the previous content, but that this is "checked" after I
entered the whole new number and I exit or save the object.
An extra problem is that I'm doing this through a portal, so the option
to copy the previous content into another field while entering the
layout or instance and doing the check afterwards by comparing these two
is no option.

Thank you in advance,

Marc

Reply With Quote
  #2  
Old   
Christoph Kaufmann
 
Posts: n/a

Default Re: Script trigger : OnObjectModify - 10-26-2010 , 08:30 AM






MB <newsgroup (AT) bouts (DOT) in> wrote:

Quote:
Hello,

I'm using FMPA 11. I want to enter a value in a field. On these field I
wan't to connect a scripttrigger that launches a script when the content
of the field has changed.
I thought I could do this by by selecting "OnObjectModify" in de Set
Script triggers. My problem is the following.
Lets say in the field (number) you have the number 100. I want to enter
200 and since is different to 100 the "connected" script should be
launched. Problem is that the script is launched from the moment I
entered the first digit (in this case the 2).
Is there a way to launch the script when this content is different (and
only then) to the previous content
I'd take OnObjectSave and compare the content to a global variable or
global field that I'd have set with OnObjectEnter on the same field.
--
http://clk.ch

Reply With Quote
  #3  
Old   
Jens Teich
 
Posts: n/a

Default Re: Script trigger : OnObjectModify - 10-26-2010 , 08:44 AM



MB <newsgroup (AT) bouts (DOT) in> writes:

Quote:
Hello,

I'm using FMPA 11. I want to enter a value in a field. On these field
I wan't to connect a scripttrigger that launches a script when the
content of the field has changed.
I thought I could do this by by selecting "OnObjectModify" in de Set
Script triggers. My problem is the following.
Lets say in the field (number) you have the number 100. I want to
enter 200 and since is different to 100 the "connected" script should
be launched. Problem is that the script is launched from the moment I
entered the first digit (in this case the 2).
Is there a way to launch the script when this content is different
(and only then) to the previous content, but that this is "checked"
after I entered the whole new number and I exit or save the object.
An extra problem is that I'm doing this through a portal, so the
option to copy the previous content into another field while entering
the layout or instance and doing the check afterwards by comparing
these two is no option.
FileMakers behaviour is correct. Typing into a field is a
modification. Have a look for another scripttrigger which fits better to
your needs.

-jens

Reply With Quote
  #4  
Old   
MB
 
Posts: n/a

Default Re: Script trigger : OnObjectModify - 10-26-2010 , 09:21 AM



Of course, perfect and simple solution. Thanks

Op 26/10/2010 15:30, Christoph Kaufmann schreef:
Quote:
MB<newsgroup (AT) bouts (DOT) in> wrote:

Hello,

I'm using FMPA 11. I want to enter a value in a field. On these field I
wan't to connect a scripttrigger that launches a script when the content
of the field has changed.
I thought I could do this by by selecting "OnObjectModify" in de Set
Script triggers. My problem is the following.
Lets say in the field (number) you have the number 100. I want to enter
200 and since is different to 100 the "connected" script should be
launched. Problem is that the script is launched from the moment I
entered the first digit (in this case the 2).
Is there a way to launch the script when this content is different (and
only then) to the previous content

I'd take OnObjectSave and compare the content to a global variable or
global field that I'd have set with OnObjectEnter on the same field.

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.