Commit Records/Requests[ ] [ No dialog ]
Commit Records/Requests[ ] [ No dialog ]
If[ not( fnIsWebConnection( ) ) ]
If[ not( fnIsWebConnection( ) ) ]
Set Variable[ $Invoice; Value: Let( [var0 = "filemac:" & Get( DesktopPath ); var1 = "filewin:" & Get( DesktopPath )]; Case( Abs( Get( SystemPlatform ) ) = 1; p_0; Abs( Get( SystemPlatform ) ) = 2; p_1 ) & "SalesInvoice" & Sales Orders::Invoice ID & ".pdf" ) ]
Set Variable[ $Invoice; Value: Let( [var0 = "filemac:" & Get( DesktopPath ); var1 = "filewin:" & Get( DesktopPath )]; Case( Abs( Get( SystemPlatform ) ) = 1; p_0; Abs( Get( SystemPlatform ) ) = 2; p_1 ) & "SalesInvoice" & Sales Orders::Invoice ID & ".pdf" ) ]
If[ IsEmpty( Sales Orders::Bill To Email ) ]
If[ IsEmpty( Sales Orders::Bill To Email ) ]
Show Custom Dialog[ Title: "Message"; Message: "There is no email address for this record. Please try again after entering an address."; Buttons: “OK” ]
Show Custom Dialog[ Title: "Message"; Message: "There is no email address for this record. Please try again after entering an address."; Buttons: “OK” ]
Go to Field[ Sales Orders::Bill To Email ]
Go to Field[ Sales Orders::Bill To Email ]
If[ IsValidExpression( Sales One Record::Invoice ID ) ]
If[ Line Items::Invoice ID ]
Go to Related Record[ From table: Sales One Record ; Using layout: Sales Invoice ; New window: "Sales Invoice"; Width: 700 ] [ Show only related records ]
Go to Related Record[ From table: Line Items ; Using layout: Sales Invoice ; New window: "Sales Invoice"; Width: 700 ] [ Show only related records ]
Show Custom Dialog[ Title: "Alert"; Message: "There are no line items to display."; Buttons: OK ]
Print Setup[ Comm: type; 1464880449: Platform; Portrait: Orientation; 100.%: Scale; {top: -18.0, left: -36.0, bottom: 594.0, right: 756.0}: Margin; 576.: PrintableWidth; 720.: PrintableHeight ] [ No dialog; Restore ]
Print Setup[ Comm: type; 1464880449: Platform; Portrait: Orientation; 100.%: Scale; {top: -18.0, left: -36.0, bottom: 594.0, right: 756.0}: Margin; 576.: PrintableWidth; 720.: PrintableHeight ] [ No dialog; Restore ]
Save Records as PDF[ File Name: “$Invoice”; Records being browsed ] [ Document - Title: "Invoice #" & Sales Orders::Invoice ID; Compatibility: Acrobat 5 and later ] [ Pages - Number Pages From: 1; Include: All pages ] [ Security - Printing: High Resolution; Editing: Any except extracting pages; Enable Copying; Enable Screen Reader ] [ Initial View - Show: Pages Panel and Page; Page Layout: Single Page; Magnification: 100% ] [ No dialog; Restore ]
Save Records as PDF[ File Name: “$Invoice”; Records being browsed ] [ Document - Title: "Invoice #" & Sales Orders::Invoice ID; Compatibility: Acrobat 5 and later ] [ Pages - Number Pages From: 1; Include: All pages ] [ Security - Printing: High Resolution; Editing: Any except extracting pages; Enable Copying; Enable Screen Reader ] [ Initial View - Show: Pages Panel and Page; Page Layout: Single Page; Magnification: 100% ] [ No dialog; Restore ]
If[ Sales Orders::Ship To Email = Sales Orders::Bill To Email ]
If[ Sales Orders::Ship To Email = Sales Orders::Bill To Email ]
Send Mail[ Send via E-mail Client; To: Sales Orders::Bill To Name & " <" & Sales Orders::Bill To Email & ">"; Subject: "Invoice #" & Sales Orders::Invoice ID; Attachment: “$Invoice” ]
Send Mail[ Send via E-mail Client; To: Sales Orders::Bill To Name & " <" & Sales Orders::Bill To Email & ">"; Subject: "Invoice #" & Sales Orders::Invoice ID; Attachment: “$Invoice” ]
Else If[ IsEmpty( Sales Orders::Ship To Email ) ]
Else If[ IsEmpty( Sales Orders::Ship To Email ) ]
Send Mail[ Send via E-mail Client; To: Sales Orders::Bill To Name & " <" & Sales Orders::Bill To Email & ">"; Subject: "Invoice #" & Sales Orders::Invoice ID; Attachment: “$Invoice” ]
Send Mail[ Send via E-mail Client; To: Sales Orders::Bill To Name & " <" & Sales Orders::Bill To Email & ">"; Subject: "Invoice #" & Sales Orders::Invoice ID; Attachment: “$Invoice” ]
Send Mail[ Send via E-mail Client; To: Sales Orders::Bill To Name & " <" & Sales Orders::Bill To Email & ">" & ";" & Sales Orders::Ship To Name & " <" & Sales Orders::Ship To Email & ">"; Subject: "Invoice #" & Sales Orders::Invoice ID; Attachment: “$Invoice” ]
Send Mail[ Send via E-mail Client; To: Sales Orders::Bill To Name & " <" & Sales Orders::Bill To Email & ">" & ";" & Sales Orders::Ship To Name & " <" & Sales Orders::Ship To Email & ">"; Subject: "Invoice #" & Sales Orders::Invoice ID; Attachment: “$Invoice” ]
Close Window[ Current Window ]
Close Window[ Current Window ]
Show Custom Dialog[ Title: "Message"; Message: "There was an error addressing the email. Please check that your email software is installed correctly."; Buttons: “OK” ]
Show Custom Dialog[ Title: "Message"; Message: "There was an error addressing the email. Please check that your email software is installed correctly."; Buttons: “OK” ]