Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 4890 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hi there.

Can someone help me at this?

I need to be able to export a table as Excel in a temp directory (preferably in a subdirectory from where the .fp7 file resides)and then be sent to a fixed email address as an attachment.

Is it possible that the process be started through an IWP session (unsure)?

How will I specify the path inside the server machine?

More questions upon an answer possibly :B

Thanks in advance.

Posted

With the little you've provided, I'll just say Yes, it's all possible. You could set a flag to queue the export and email in a server script.

The server script runs (as often as you like) and Finds the queued record. If no recs found, it halts. Otherwise, it'll set $exportPath to Get (TemporaryDirectory) & "filename.xls", Export Records $exportPath, then Send Mail attaching $exportPath.

Posted

I need to be able to export a table as Excel in a temp directory (preferably in a subdirectory from where the .fp7 file resides)

FMS can only export to two locations: its own Documents folder, or a special Temp folder that gets created by the script and deleted when the script is done.

So if you want to have file end up anywhere else you'll have to use a FMS sequence schedule to use the OS to move the file after the FM script is done...

Posted

With the little you've provided, I'll just say Yes, it's all possible. You could set a flag to queue the export and email in a server script.

The server script runs (as often as you like) and Finds the queued record. If no recs found, it halts. Otherwise, it'll set $exportPath to Get (TemporaryDirectory) & "filename.xls", Export Records $exportPath, then Send Mail attaching $exportPath.

FMS can only export to two locations: its own Documents folder, or a special Temp folder that gets created by the script and deleted when the script is done.

So if you want to have file end up anywhere else you'll have to use a FMS sequence schedule to use the OS to move the file after the FM script is done...

Thanks a lot bcooney and Wim, that's just about all I really needed to know !

One last question Wim, when you say "its own Documents folder" you mean the directory tree where it is installed, or the "Documents" folder?

Posted

See http://www.fmforums.com/com/training/server-side-imports-and-exports-r21

This topic is 4890 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.