dbTalk Databases Forums  

Running a Script on Exit

comp.databases.filemaker comp.databases.filemaker


Discuss Running a Script on Exit in the comp.databases.filemaker forum.



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

Default Running a Script on Exit - 08-13-2005 , 09:28 AM






Hi Everyone,

I have a script that is designed to automatically generate an email and
put it in my outbox. Instead of having this script sent when a button
is pressed, how can I make it run when I close the database? Is this
(or something like it) possible?

Thanks in advance.


Reply With Quote
  #2  
Old   
ursus.kirk
 
Posts: n/a

Default Re: Running a Script on Exit - 08-13-2005 , 10:22 AM






You obviously haven't tried the help-file first.

RTFM

Try F1 or the help menu-item

Ursus

"Jameson" <jameson_ray (AT) comcast (DOT) net> schreef in bericht
news:1123943312.635357.296960 (AT) f14g2000cwb (DOT) googlegroups.com...
Quote:
Hi Everyone,

I have a script that is designed to automatically generate an email and
put it in my outbox. Instead of having this script sent when a button
is pressed, how can I make it run when I close the database? Is this
(or something like it) possible?

Thanks in advance.




Reply With Quote
  #3  
Old   
Shadenfroh
 
Posts: n/a

Default Re: Running a Script on Exit - 08-13-2005 , 03:25 PM



In FM 7, File, File Options.

Before that, Edit, Preferences, Document.

--

Shadenfroh
shadenfroh (AT) yahoo (DOT) com

"Jameson" <jameson_ray (AT) comcast (DOT) net> wrote

Quote:
Hi Everyone,

I have a script that is designed to automatically generate an email and
put it in my outbox. Instead of having this script sent when a button
is pressed, how can I make it run when I close the database? Is this
(or something like it) possible?

Thanks in advance.




Reply With Quote
  #4  
Old   
Helpful Harry
 
Posts: n/a

Default Re: Running a Script on Exit - 08-13-2005 , 04:03 PM



In article <zGsLe.7532$ns.3775 (AT) newsread1 (DOT) news.atl.earthlink.net>,
"Shadenfroh" <shadenfroh (AT) yahoo (DOT) com> wrote:
Quote:
"Jameson" <jameson_ray (AT) comcast (DOT) net> wrote in message
news:1123943312.635357.296960 (AT) f14g2000cwb (DOT) googlegroups.com...

Hi Everyone,

I have a script that is designed to automatically generate an email and
put it in my outbox. Instead of having this script sent when a button
is pressed, how can I make it run when I close the database? Is this
(or something like it) possible?

Thanks in advance.

In FM 7, File, File Options.

Before that, Edit, Preferences, Document.
Specifically, there's an option to run a script on closing the file -
this is run when the file is closed (by the window gadget, the File
menu command or a script command) and when FileMaker is quit.

This option runs the script EVERY time the file is closed, so if you
only want the script run once per day (for example) you'll need to
program that functionality into the script itself (eg. have a Global
field that is set to today's date when the script has finished and use
an If statement to check that Global field isn't already today at the
start of the script).

Helpful Harry
Hopefully helping harassed humans happily handle handiwork hardships ;o)


Reply With Quote
  #5  
Old   
42
 
Posts: n/a

Default Re: Running a Script on Exit - 08-13-2005 , 04:16 PM



In article <140820050903331438%helpful_harry (AT) nom (DOT) de.plume.com>,
helpful_harry (AT) nom (DOT) de.plume.com says...
Quote:
In article <zGsLe.7532$ns.3775 (AT) newsread1 (DOT) news.atl.earthlink.net>,
"Shadenfroh" <shadenfroh (AT) yahoo (DOT) com> wrote:
"Jameson" <jameson_ray (AT) comcast (DOT) net> wrote in message
news:1123943312.635357.296960 (AT) f14g2000cwb (DOT) googlegroups.com...

Hi Everyone,

I have a script that is designed to automatically generate an email and
put it in my outbox. Instead of having this script sent when a button
is pressed, how can I make it run when I close the database? Is this
(or something like it) possible?

Thanks in advance.

In FM 7, File, File Options.

Before that, Edit, Preferences, Document.

Specifically, there's an option to run a script on closing the file -
this is run when the file is closed (by the window gadget, the File
menu command or a script command) and when FileMaker is quit.

This option runs the script EVERY time the file is closed, so if you
only want the script run once per day (for example) you'll need to
program that functionality into the script itself (eg. have a Global
field that is set to today's date when the script has finished and use
an If statement to check that Global field isn't already today at the
start of the script).
/agree

That doesn't work in multiuser situations though. If you really only the
want the script run once a day and the solution is networked, you'll
need to implement a 1 record preferences table/file with the date last
run as one of its fields.

-cheers,
Dave


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.