Jump to content
Server Maintenance This Week. ×

Script to email report layout


JMart

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

Recommended Posts

Hi gurus,

 

I have a flat database what contains username, phone ext, department, and email address. I created a layout report grouped by department. I would like to create a script that sends the layout to each user using the email on the database.

 

Can someone guide me or point me to a sample script.

 

Thanks

JMart 

Link to comment
Share on other sites

Take a look at Menu »» File »» Send

The Script Step is found in the Script Workspace as a step , it will give you the same form as in the Send Mail, found under the File »» Send.

Here is the link to the Help online for Send Mail

Link to comment
Share on other sites

I just noticed that some of the files in your Template folder, that came with your application, have an example of the Send Mail script. here the one in Assets.com

Set Error Capture [ On ]
If [ not IsEmpty ( Assets::Selected File Container )  and $$PLATFORM ≠ "Web" ] 
	Set Variable [ $PATH ; Value: Get ( TemporaryPath ) & Assets::Selected File Container ] 
	Export Field Contents [ Assets::Selected File Container ; “$PATH” ] 
End If
Send Mail [ Send via E-mail Client ; With dialog: On ; Subject: "Asset: " & Assets::Item & If ( not IsEmpty ( Assets::Category ) ; " [" & Assets::Category & "]" ; "" ) ; Message: If ( not IsEmpty ( Assets::Item ) ; "Item: " & Assets::Item  & ¶  ; "" ) & If ( not IsEmpty ( Assets::Category ) ; "Category: " & Assets::Category  & ¶ ; "" ) & If ( not IsEmpty ( Assets::Model ) ; "Model: " & Assets::Model  & ¶ ; "" ) & If ( not IsEm…" ; “$PATH” ] 

That you can use as an example.

Lee

Link to comment
Share on other sites

This topic is 2289 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.