E-mailing invoices
Hi All,
Can anyone give me some pointers on e-mailing invoices (or other documents) from the SDK? I was thinking in the lines of creating a PDF document and then attaching that to the e-mail. Please can anyone who has had a similar problem please give me some advice! I cannot e-mail the standard jpg format as the quality is not good enough and gives a very bad impression!
Thanks in advance,
Adele
Hi Adele,
You wont need a code example, ALD already contains the functionality to email. What you'll need to do is load the ALD, create a report and then there are some email specific fields you'll need to map to data fields.
I recommend you download a demo invoice layout from SAP for ALD. There's an import file for an AR Invoice layout attached to SAP note 813796 (once downloaded you'll need to open the XML file and read the comments about localisation as you may need to edit a property in the XML file prior to importing the layout).
To test the email functionality (2004A and 2005A should be identical):
1) Install ALD
2) Go into AdministrationSystem InitialisationPrint Preferences and tick the option to use Advanced Layout Designer.
3) Start ALD
4) Go into AdministrationData Import/ExportData Import--Import Layouts for ALD
5) Use the import window to import the invoice you've downloaded.
6) Open the AR Invoice window. Click on the Print Layout Designer icon.
7) Choose to use ALD, then highlight the new invoice layout and click on the ALD button on the bottom right of the window. This should open the ALD designer and display your invoice layout.
8) Choose Project--Properties from the top menu. Scroll down the window and you'll see fields for emailing.
9) You can use the formula button to the right of each field to map each option to a field in the database (eg you can map the Email To field to the BP Contact email address). For a simple test, you could just hardcode values in the fields.
10) Exit the window (ignoring the warning about the fax fields being empty!), save the project and exit ALD.
11) Click on the Update button on the previous window to accept the changes you have made to the layout (Very important!)
12) Print Preview an invoice. This should display as an ALD layout.
13) In the Print Preview window, click on the Email button.
14) Choose your format (PDF seems to work the best) and then accept to send as an email.
15) Providing that all the above has worked correctly, you should see an email in your Sent Items folder in Outlook and the recipient will receive an email with the attached invoice.
Hope this helps,
Owen
Similar Messages
-
Hi all,
I'm sending invoice via e-mail. I'd like to change subject of e-mail -> invoice number - vbrk-vbeln. Now i do it maually in Print options. I delete text in "Cover page text" and paste invoice number.
How can i this proces automate?
Thanks in advanced
VasekHi,
If invoice is being generated using SAP Script or Smartforms then u hv to change the driver program and the corresponding layout set (Form) to display the Invoice number in the header.
Regards,
Himanshu. -
Subject line on e-mailed invoices
Hi all----
I'm having some difficulty with the subject line of our e-mailed invoices.
We maintain in VV32 --- [our company] invoice &XNAST-OBJKY&. This includes the invoice number in the subject header along with our company's name. This works perfectly for us.
However, now we have a customer who instead of the invoice number in the subject line of their e-mails, wants their PO number.
In VV32 I tried &XVBAK-BSTNK& and &XVBRK-BSTNK_VF&, however neither of them work.
What am I missing?
Thanks in advance for your assistance.
JoshHi
Please, see these notes
Note 49174 - NAST: VF01 Replacement of symbols does not work
Note 537832 - Incorrect replacement of text symbols for MAIL
Note 718017 - Replacement of text symbols in spool title/MAIL
So, do a subrutine in RV60AFZZ, for instance ZZ_TEXT_SYMBOL_REPLACE. Populate in V/40 for your message program SAPLV60A and the last subrutine in the fields for replace of text symbols. After, do the settings in V/40 to see this text symbol.
I hope this helps you
Regards
Eduardo
PD: other idea. Rule the number of PO for splitting the invoice, and store this number in any field. If you don't have any field for this purpose, enhance VBRK with an append and populate it in the copy rules with a VOFM subroutine.
Edited by: E_Hinojosa on Jan 25, 2012 5:54 PM -
Mail Invoice in PDF as Email using Workflow
Dear all,
We are having a requirement to mail the invoice to the customer using worflow.
The workflow has to execute on a certain date and mail should be sent to Customer which will have invoice as attachment in PDF form. Everything shld happen automatically.
Is there any standard workflow available for this ?
Is it possible to have a direct link with message type config in NACE ?
Thanks in Advance.
Regards,
VivekIn NACE, in the FORM routine convert the Smartform or SapScript form to PDF and use the FM 'SO_NEW_DOCUMENT_ATT_SEND_API1' to send this file as an attachment to the required receipient.
-
How to mail invoice as pdf to customer
hi all,
i have to send a copy of the invoice as a pdf to the customer through mail, request you to kindly guide me how to configure this in the system.
thanks & regards,
padmanabhanHi,
SAP have created a standard program RSTXPDFT4 to convert your Sapscripts spools into a PDF format.
Specify the spool number and you will be able to download the sapscripts spool into your local harddisk.
Please note that it is not restricted to sapsciprts spool only. Any reports in the spool can be converted using the program 'RSTXPDFT4'.
1.Run the program RSTXPDFT4 in se38
2. Give the spool number and mention the directory and filename where to want to store the pdf file
3. press execute
MAIL: to Configure the Mail settings in the Tcode SCOT with the help of a basis person
and use the Medium as MAIL (7) instead of 1(printout)
and see that the receipient mail id (customer) are maintained properly and it should fired in the driver program..
Just we have to check the Output from the fun module
ADDR_GET_NEXT_COMM_TYPE which is there in driver program
Reward points if useful
Regards,
Govind. -
Mailing Invoice through output type - Getting Error "No address exists"
Hi Experts,
I am trying to mail the invoice using out put type. I am using the standard out put type MAIL, Print program RSNASTSO and routine SAPOFFICE_AUFRUF_VX for external send 5 and using SP partner type. I maintained email address in Customer master. When I am assigning output type to send mail its failing and am getting an error as following.
Object 1001101366
Output type: Mail
Processing log for program RSNASTSO routine SAPOFFICE_AUFRUF_VX
Function module SO_NAME_CONVERT with return code
Text 110V31001101366 MAILE0000200290 ID STAM lang
No address exists
Error while copying recipient object
Specify at least one recipient
Message object FOL35000000000004SCR36000000000089 created or sent
And the mail is not triggering. Please help me out to resolve this issue. I am an Abaper, SD consultant is not available for me now.
Thanks and Regards,
hemanthCheck whether Note 960088 - FAQ: Sending SD messages externally, helps you
thanks
G. Lakshmipathi -
Mail invoice/statement to the customer
Hi gurus
i would like to know how we set up in R11 so that the system can automatically sent invoices/statements to the customers,i tried the function of making the customer site a statement site,and setting the statement cycle but when i test it,i get no results,please help.
thanksDepending on the SAP vesion you need to set-up transmission medium 7.
Please check sap.help.com where you find an instruction how to enter the email address in that case.
Just saw that your request is very old ... too late my answer I assume. -
E-mailed iTunes invoice?
I'd like to have a hard copy print out of my purchase history. I know how to view my purchases (logging into my iTunes account and clicking at Purchase History), but the the Edit function at the Safari bar doesn't allow me to copy and print the text to another document.
At http://docs.info.apple.com/article.html?artnum=93010, it states that I'd receive an emailed invoice when purchases reach $20 or after 12 hours whichever comes first. Its been over 24 hours from my less than $20 iTunes purchase and I haven't received that email. Does anyone out there receive emailed iTunes invoices?I usually receive an e-mail invoice or receipt for music store purchases within 24 hours. I haven't exactly timed it, so it could be a whole lot less than 24 hours.
-
Invoice automatic mailing to customer
Hi all,
Please help me in the issue . I want to mail Invoice generated(VF01) should be automatically sent to the customer Can anyone please guide me to acheive the same.
Thanks in advance,
Edited by: Eric de on Jun 10, 2010 11:02 AMHi,
You can use the FM CONVERT_OTFSPOOLJOB_2_PDF to convert the OTF file int o PDF and then use the SO_NEW_DOCUMENT_ATT_SEND_API FM to send the email.
Also refer the below link for more details.
http://help.sap.com/saphelp_nw2004s/helpdata/en/a5/28d3b9d26211d4b646006094192fe3/frameset.htm
~Vaas -
Report for no of invoices sent for print
Hi Gurus,
Report is needed that indicates how many invoices should be printed daily from SAP. we are printing and mailing invoices; report should detail how many need to be mailed vs. were sent edi/faxed.
How i can achive this ?
Regards,
Sujit Shinde.The output records can be found from table NAST. I suppose you could create a query based on it.
-
Report tracking invoice prints in SAP
Hello Experts,
A SAP report is needed that indicates how many invoices should be printed daily from SAP. Client is printing and mailing invoices; report should detail how many need to be mailed vs. were sent edi/faxed.
Any suggestions please?
Regards,
RajHi Raja,
U r requirement is quite strange, just check the table NAST in that pass the parameters "application" and "message type" and "created on " you will get the list of messages on a particular day.
How this is helpful to you.
Regards,
kishore. -
How to e mail the revised and signed docs to the other w/o missing them.
How can I e mail the docs I added some texts and signed over the original docs without missing them. I tried and I all missed the added part. It was sent the ordinal doc as is.
Please give me some advice.Hi
MAIL: to Configure the Mail settings in the Tcode SCOT with the help of a basis person
and use the Medium as MAIL (7) instead of 1(printout)
and see that the receipient mail id (customer) are maintained properly and it should fired in the driver program..
Just we have to check the Output from the fun module
ADDR_GET_NEXT_COMM_TYPE which is there in driver program
REFER SDN LINK how to mail invoice as pdf to customer -
New Output Type for E-MAIL - What Programs to use
Hi ,
I am Configuring a new Output Type for E-mail Invoices. Based on the Billing Indicator on the Customer Master the New output type for E-mail should be determined and send an e-mail. To test this i have setup a new output type and used the below parameters:
Program : RSNASTSO
Form Routine: SAPOFFICE_AUFRUF
PDF/SmartForm Form: SAPOFFICE_AUFRUF_VX
Form Type: PDF
I have the e-mail address in the general data of both Bill to and Sold TO. The partner Function for this output type is BP.
When i created an Invoice i got the below error, I have highlighted the line with astericks which are showing up as error.
Processing log for program RSNASTSO routine SAPOFFICE_AUFRUF
Function module SO_NAME_CONVERT with return code
Text 220V30900018667 ZRD3E0500000425 ID STAM language E not found
**No address exists - Error**
**Error while copying recipient object - Error**
**Specify at least one recipient - Error**
Message object FOL29000000000004SCR33000000000044 created or sent
At this point i just want to be able to send an invoice via e-mail using standard program. I am looking to confirm if i am using the correct parameters. Any help will be greatly appreciated.
Thanks,
Irfan.Hi ,
You can ty using the function module SO_NEW_DOCUMENT_ATT_SEND_API1
here you will to also pass the logic that the PDF should be sent to a email recipient as per mentione din the bill to party function module
Thanks
Prashant -
Why am I receiving Mailer-Daemon notices for only one of many companies I deal with
I use QuickBooks to send and post invoices. ThunderBird is the e-mail service tied into it. On 4/14 I started receiving Mailer-Daemon failure notice 544 for just one of my accounts when I tried e-mailing invoices to them. All the other accounts are fine.
The error message usually give you the reason. Have to read the notice?
-
Any ideas why the second HOST call does not work???
Hi Folks.
I have written the following code which works fine in all but one respect.
The code creates a zip file on a server (Accessed over a network) hence the full windows network path name.
The call to host on the server works in terms of running the zipinvoices.bat file and the zip file is generated on the server in the correct location.
The prigram unit also generates the correctly formatted mailinvoices.bat file. However, the second call to HOST does not run/execute the mailinvoices.bat file. If I go to the server and run the mailinvoices.bat file directly, it runs perfectly and emails the file to me, no problemo.
Why does the second call to HOST from the client machine not run?
Any clues anyone???
Cheers
Simon Gadd
PROCEDURE send_email_invoices_pu_p (p_organisation IN VARCHAR2) IS
v_processing_cycle CHAR(4);
v_alert_but NUMBER;
v_error_num NUMBER;
v_sent_status NUMBER(1);
v_stage NUMBER(1);
v_year VARCHAR2(4);
v_month VARCHAR2(9);
v_folder_name VARCHAR2(25); -- Name of the file which holds the 'Printed' invoices in the receivables folder. v_organisation VARCHAR2(50);
v_password VARCHAR2(25);
v_organisation VARCHAR2(25);
v_host_command VARCHAR2(100);
v_from_name VARCHAR2(100);
v_to_name VARCHAR2(100);
v_subject VARCHAR2(100);
v_error_txt VARCHAR2(200);
v_file VARCHAR2(200);
v_message VARCHAR2(500);
v_line_buffer VARCHAR2(5000);
v_working BOOLEAN := TRUE;
v_zipinvoices_bat TEXT_IO.FILE_TYPE;
v_mailinvoices_bat TEXT_IO.FILE_TYPE;
CURSOR c_sent_status IS
SELECT sent
FROM INVOICE_EMAIL
WHERE UPPER(ORGANISATION) = UPPER(v_organisation);
CURSOR c_select_folder IS
SELECT folder
FROM INVOICE_EMAIL
WHERE UPPER(ORGANISATION) = UPPER(v_organisation);
CURSOR c_select_email_elements IS
SELECT send_to,
send_from
FROM INVOICE_EMAIL
WHERE UPPER(ORGANISATION) = UPPER(v_organisation);
BEGIN
v_organisation := p_organisation;
-- Check to see if the invoices have already been e-mailed for this Procssing Cycle. If they have,
-- then warn the user of this and get them to confirm that they wish to proceed and e-mail them again.
-- The batch e-mail process will re-zip the invoices (ignoring a pre existing .zip file) and overwrite
-- the existing zip file if it exists or generate it if it does not exist.
OPEN c_sent_status;
FETCH c_sent_status INTO v_sent_status;
CLOSE c_sent_status;
IF v_sent_status = 1 THEN
v_alert_but := SHOW_ALERT('SEND_AGAIN_ALRT');
IF v_alert_but = ALERT_BUTTON2 THEN RAISE FORM_TRIGGER_FAILURE;
ELSE NULL;
END IF;
END IF;
:CONTROL.WORKING := 'Started Zipping invoices for '||INITCAP(v_organisation)||'.'||CHR(10)||'Please wait..';
SYNCHRONIZE;
-- The following code opens the zipinvoices.bat file which resides in the root folder \\Ebony\c$\FCSS\DB_SCRIPTS\ and modifies it ready to
-- zip up the invoices in the relevant organisation's invoice folder for the current processing cycle.
v_processing_cycle := GET_CURRENT_TRAFFIC_PERIOD;
v_month := RTRIM(INITCAP(TO_CHAR(TO_DATE(v_processing_cycle, 'MMYY'), 'MONTH')));
v_year := (TO_CHAR(TO_DATE(v_processing_cycle, 'MMYY'), 'YYYY'));
OPEN c_select_folder;
FETCH c_select_folder INTO v_folder_name;
CLOSE c_select_folder;
KILL_OLD_ZIP_PU_P('del \\Ebony\c$\FCSS\CYCLE_DATA\'||v_processing_cycle||'\receivables\'||v_folder_name||'\invoices.zip');
SELECT zip_password
INTO v_password
FROM INVOICE_EMAIL
WHERE UPPER(ORGANISATION) = UPPER(v_organisation);
v_zipinvoices_bat := TEXT_IO.FOPEN('\\Ebony\c$\FCSS\DB_SCRIPTS\zipinvoices.bat', 'w');
v_line_buffer := 'cd..';
TEXT_IO.PUT_LINE (v_zipinvoices_bat, v_line_buffer);
v_line_buffer := 'cd..';
TEXT_IO.PUT_LINE (v_zipinvoices_bat, v_line_buffer);
v_line_buffer := 'wzzip -s'||v_password||' -x*.zip -ybc \\Ebony\c$\FCSS\CYCLE_DATA\'||v_processing_cycle||'\receivables\'||v_folder_name||'\invoices \\Ebony\c$\FCSS\CYCLE_DATA\'||v_processing_cycle||'\receivables\'||v_folder_name||'\*.*';
TEXT_IO.PUT_LINE (v_zipinvoices_bat, v_line_buffer);
v_line_buffer := 'exit';
TEXT_IO.PUT_LINE (v_zipinvoices_bat, v_line_buffer);
TEXT_IO.FCLOSE (v_zipinvoices_bat);
-- The following code executes the freshly edited \\Ebony\c$\FCSS\DB_SCRIPTS\zipinvoices.bat file to produce the zipped invoices file
-- ready to be e-mailed out to the address specified in the INVOICE_EMAIL table for the relevant organisation.
v_host_command := '\\Ebony\c$\FCSS\DB_SCRIPTS\zipinvoices.bat';
v_stage := 1;
HOST (v_host_command, NO_SCREEN);
IF NOT Form_Success THEN
IF v_stage = 1 THEN
:CONTROL.WORKING := 'Error -- The .zip file for '||INITCAP(v_organisation)||' was not produced.';
SYNCHRONIZE;
ELSIF v_STAGE = 2 THEN
:CONTROL.WORKING := 'Error -- The zipped invoices file for '||INITCAP(v_organisation)||' was not emailed.';
SYNCHRONIZE;
END IF;
ELSE NULL;
END IF;
:CONTROL.WORKING := 'All invoices for '||INITCAP(v_organisation)||' successfully zipped.'||CHR(10)||'Attempting to send via e-mail.'||CHR(10)||'Please wait..';
SYNCHRONIZE;
-- The following code e-mails the freshly created .zip file for the relevant organisation and e-mails it to the
-- recipient specified in the relevant row in the INVOICE_EMAIL programme along with from address, subject and
-- message if specified.
OPEN c_select_email_elements;
FETCH c_select_email_elements INTO
v_to_name,
v_from_name;
CLOSE c_select_email_elements;
v_stage := 2;
v_mailinvoices_bat := TEXT_IO.FOPEN('\\Ebony\c$\FCSS\DB_SCRIPTS\mailinvoices.bat', 'w');
v_line_buffer := 'cd..';
TEXT_IO.PUT_LINE (v_mailinvoices_bat, v_line_buffer);
v_line_buffer := 'cd..';
TEXT_IO.PUT_LINE (v_mailinvoices_bat, v_line_buffer);
v_line_buffer := 'clemail -quiet -smtpserver mailhost.0800dial.com -smtpport 25 -to '||v_to_name||' -from '||v_from_name||' -subject "'||v_month||' '||v_year||' Roaming Traffic Invoices from United Clearing Ltd" -bodyfile \\Ebony\c$\FCSS\DB_SCRIPTS\invoice_body.txt -attach \\Ebony\c$\FCSS\CYCLE_DATA\'||v_processing_cycle||'\receivables\'||v_folder_name||'\invoices.zip';
TEXT_IO.PUT_LINE (v_mailinvoices_bat, v_line_buffer);
v_line_buffer := 'exit';
TEXT_IO.PUT_LINE (v_mailinvoices_bat, v_line_buffer);
TEXT_IO.FCLOSE (v_mailinvoices_bat);
v_host_command := '\\Ebony\c$\FCSS\DB_SCRIPTS\mailinvoices.bat';
HOST (v_host_command, NO_SCREEN);
IF NOT Form_Success THEN
IF v_stage = 1 THEN
:CONTROL.WORKING := 'Error -- The .zip file for '||INITCAP(v_organisation)||' was not produced.';
SYNCHRONIZE;
ELSIF v_STAGE = 2 THEN
:CONTROL.WORKING := 'Error -- The zipped invoices file for '||INITCAP(v_organisation)||' was not emailed.';
SYNCHRONIZE;
END IF;
ELSE NULL;
END IF;
UPDATE INVOICE_EMAIL
SET sent = 1
WHERE UPPER(ORGANISATION) = UPPER(v_organisation);
COMMIT;
GO_BLOCK ('INVOICE_EMAIL');
EXECUTE_QUERY;
:CONTROL.WORKING := 'Please press a button on the left to e-mail invoices to the organisations listed.';
SYNCHRONIZE;
EXCEPTION
WHEN OTHERS THEN
v_error_num := SQLCODE;
v_error_txt := SUBSTR(SQLERRM, 1, 200);
MESSAGE('The error was: '||v_error_txt||' and the code was: '||v_error_num);
RAISE FORM_TRIGGER_FAILURE;
END;As a suggestion I'd put the Text_io segments into their own begin - exception - end sub-blocks within the main code. This way if Text_io does raise an exception you can catch it earlier as it may be able to recover - That is if it is a text_io exception.
Other than that you;ll have to step through in Debug.
Maybe you are looking for
-
Problem with printing pdf file HP 845c windows 7
When I am printing a pdf file it is not printed well, the ink is grey and it is difficult to read.
-
Masking not displaying correctly
Recently upgraded system to 9.1.2. I have a couple dozen phones when dialing an outside line there phone masking is not displaying. The masking is showing up with the Bill To Number of the PRI's. I have had numerous Cisco TAC show me and tell me that
-
hi! how can I put an image in the panel title? I tried with tha same way that the button, like this: <mx:Panel id="myPan" title="Panel" icon="@Embed('image.png')"> but it didn't work any idea? thank you
-
I already exit and started again several times but no solution. I always get this error message. Any suggestion please?? Thank you
-
i am setting up a mac book air and one program has put itself in the middle of my desk top and will not move. I would have put a version in launch pad, where i want it, but one icon stays on my main opening desktop page. The program is vlc media play