Ted S Posted August 30, 2016 Posted August 30, 2016 Since FM Server cannot make PDFs how is this for a scripted workaround: FM client makes the PDF in the TEMP user's folder on local PC. The PDF is inserted into a container field on the current record. Mother script calls PSOS subscript which finds proper record and exports container PDF to folder on server. Send Mail grabs the PDF from the folder and sends the email from the server. PDF is deleted from folder. PDF file is deleted from the container field (No need to keep it) Result (Success or Failure) is passed back to the mother script. Sound feasible?
MonkeybreadSoftware Posted August 30, 2016 Posted August 30, 2016 Sounds doable. Alternatively you can use MBS Plugin functions on Server to work with PDF using PDFKit/DynaPDF functions or send email with more options.
Ted S Posted August 30, 2016 Author Posted August 30, 2016 I think I hit a roadblock in step 3. I can't export field contents from the server. It's grayed-out.
MonkeybreadSoftware Posted August 31, 2016 Posted August 31, 2016 A way can be to write a record to a todo table, have a FM Pro sitting somewhere which checks for those job records and does the PDF creation. When PDF is created, it will put it in a record on the job record and mark it as done. Later server can find the PDF and process it.
Mike Duncan Posted August 31, 2016 Posted August 31, 2016 13 hours ago, Ted S said: I think I hit a roadblock in step 3. I can't export field contents from the server. It's grayed-out. Base Elements plugin will allow you to export a container field's contents, and works on the server.
Ted S Posted August 31, 2016 Author Posted August 31, 2016 (edited) 3 hours ago, Mike Duncan said: Base Elements plugin will allow you to export a container field's contents, and works on the server. Thank you Mike. I will give it a try. Edited August 31, 2016 by Ted S
Ted S Posted August 31, 2016 Author Posted August 31, 2016 Well, the Base Elements plugin was looking promising but it seems to be corrupting the PDF on export. If I export manually on my client PC using native FM, it works fine. If I export manually on my client PC using the BE plugin, the PDF won't open.
Ted S Posted August 31, 2016 Author Posted August 31, 2016 8 hours ago, MonkeybreadSoftware said: A way can be to write a record to a todo table, have a FM Pro sitting somewhere which checks for those job records and does the PDF creation. When PDF is created, it will put it in a record on the job record and mark it as done. Later server can find the PDF and process it. I don't think you're understanding the problem. Yes, I can email from the server but I can't create the PDF on the server. I can create the PDF on the client but I don't want to send the email from the client. So my thought was; create the PDF on the client and place it in a container field. Then call a PSOS script that finds the proper record and attaches the PDF to an email. The problem is: (1) I can't attach directly from a container. (2) Server cannot export field contents. (3) The Base Elements plugin can export but it corrupts the file in the process.
webko Posted August 31, 2016 Posted August 31, 2016 My thought would be that you *do* send it from the client - but using a SMTP server with the settings set to a generic address, so it doesn't look like the client machine sent it. It could have the same settings as the Server... Would avoid the various workarounds described above...
Ted S Posted September 1, 2016 Author Posted September 1, 2016 15 hours ago, webko said: My thought would be that you *do* send it from the client - but using a SMTP server with the settings set to a generic address, so it doesn't look like the client machine sent it. It could have the same settings as the Server... Would avoid the various workarounds described above... I'm using this method currently but it has downsides. It requires remote users have a VPN connection so that their local PC can talk to our Exchange server. Emailing from the FM client works fine for those on on the LAN but remote users sometimes forget to activate their VPN. I'm trying to make it all simpler for everyone but me. Emailing directly from the FM server would mean the user has one less thing to remember; one less thing for us IT folks to troubleshoot.
Recommended Posts
This topic is 3003 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 accountSign in
Already have an account? Sign in here.
Sign In Now