How To, published project with attachment to send from server

Hi,

Can you please advise how a project with an attachment published from Easy Morph Desktop to the Easy Morph Server would send the attachment using the e-mail tool if the file path is on the local machine where Easy Morph Desktop is installed? Can you explain the solution please.

Thanks

Hi Kireshlyn and welcome to the Community!

EasyMorph operates with files (e.g. sends attachments) located on the same machine where the workflow is executed. If you publish a project from Desktop to Server, there are two ways how you can specify file paths that don’t require changing after publishing from Desktop to Server:

  1. Use relative paths. Every file path field in EasyMorph allows using a relative path. Of course, you need to make sure that the necessary files exist on Server in the folders specified by the relative paths.

  2. Use calculated paths. The project can have a parameter named, for instance, “Base path”. Give it a value actual for your Desktop, e.g. C:\files or some other location where the files are stored. Then a file path can be calculated using a calculated parameter with an expression, for instance:

    {Base path} & '\data\input.csv'
    

    When you publish the project to Server, create the “Base path” parameter in the Server task and bind it to the “Base path” parameter in the project (see tab “Parameters” in Server task settings). In the task parameter, you can specify the base path that points to the folder with files on the Server, e.g. C:\EasyMorph\Data. When the task is executed on Server, it will assign the “Base path” parameter of the project with the “Base path” parameter of the Server task and execute the project. Therefore the project will use the base path from Server, not from Desktop.