Print a PDF from Web Dynpro
Hi all gurus.
I developed a Web Dynpro application to let the users create their own sales orders.
Now I need to let them print the orders when they need to. Searching on the documentation I have, I've never found anything about crating a pdf print from the WD Application.
There must be a way, because I managed to do that even with the very old ITS (the one in which you had to write HTML code...) but i cannot find how.
Can anyone help me please? Even a tutorial would be very appreciated.
Thank you in advance...
>
horatiusx wrote:
> Hi all gurus.
>
> I developed a Web Dynpro application to let the users create their own sales orders.
>
> Now I need to let them print the orders when they need to. Searching on the documentation I have, I've never found anything about crating a pdf print from the WD Application.
>
> There must be a way, because I managed to do that even with the very old ITS (the one in which you had to write HTML code...) but i cannot find how.
>
> Can anyone help me please? Even a tutorial would be very appreciated.
>
> Thank you in advance...
You need a Smartform, SAPScript, or AdobeForm to be defined for your output. Define an action/method for print, then pass the data to your Form. SmartForms are not bad, as SmartForms generate a Function Module, and are easy to call.
Call the SmartForm Function with PDF output = 'X' (parameter within Output Control I think). Then pass the PDF_DATA[] table (type = TAB_SOLIX) to a new window output .
Don't have the code in front of me, but have done it several times.
Adobe Forms is another good option, but you need Adobe Server, and generally I have found ADOBE to be SLOOOOOWWWWW. I think Steve Jobs might have been on to something with ADOBE -- just my opinion.
And of course, it can be done with SAPSCript, but I would need a whole blog on how to do that.....
Similar Messages
-
Print multiple pdf from web site
Hello everyone!!,
I need print multiple pdf from web site (web page) to the local printer o client printer.
I have investigated : cfexecuted, java code, javascript, but i can't do it.
The idea is don´t open printer dialog box for to print.
Thanks.It is NOT POSSIBLE (for security reasons) to do silent printing in this way. (you wouldn't want to visit a web site and have your printer start spewing out page after page of profanity, would you??)
You can, however, offer the user the choice to print and then have it print. That can easily be done by embedding JavaScript into the PDF to be printed. If you have multiple documents, you should merge them together on the server first and then send a single document. -
I created an application to open a PDF and print it directly on the default printer. This application works if the file is a Windows' network address (example: \\192.168.0.4). But if I put an internet address (URL), the Acrobat Reader presents the following error:
There was an error opening this document. The syntax of the name of the file, folder or name of the volume is incorrect.
The command I'm using is:
"C:\Program Files\Adobe\Reader 9.0\Reader\AcroRd32.exe\" /t http: \\192.168.0.4:8082\test\file.pdf \\192.168.0.15\HPLaserJet
There are print directly as a URL?>
horatiusx wrote:
> Hi all gurus.
>
> I developed a Web Dynpro application to let the users create their own sales orders.
>
> Now I need to let them print the orders when they need to. Searching on the documentation I have, I've never found anything about crating a pdf print from the WD Application.
>
> There must be a way, because I managed to do that even with the very old ITS (the one in which you had to write HTML code...) but i cannot find how.
>
> Can anyone help me please? Even a tutorial would be very appreciated.
>
> Thank you in advance...
You need a Smartform, SAPScript, or AdobeForm to be defined for your output. Define an action/method for print, then pass the data to your Form. SmartForms are not bad, as SmartForms generate a Function Module, and are easy to call.
Call the SmartForm Function with PDF output = 'X' (parameter within Output Control I think). Then pass the PDF_DATA[] table (type = TAB_SOLIX) to a new window output .
Don't have the code in front of me, but have done it several times.
Adobe Forms is another good option, but you need Adobe Server, and generally I have found ADOBE to be SLOOOOOWWWWW. I think Steve Jobs might have been on to something with ADOBE -- just my opinion.
And of course, it can be done with SAPSCript, but I would need a whole blog on how to do that..... -
Print Version PDF in Web Dynpro ABAP Developements
Hi!
But when we push the print button, it works but doesn't generate the pdf document correctly.
alvexport.pdf 1 bytes_ the size of the document isn't correct because there is not content inside.
Best Regards.>
Gabriel Rodriguez Jimenez wrote:
> I put this direction to verify de ADS
>
> http://maep7java.miquel.es/AdobeDocumentServices/Config?style=rpc
>
> making a rpc test "works"
>
>
> The test conection in sm59 ADS works
>
>
> Also check to see if any of the sample AdobeForms WDA applications are working. <-- where I can check this?
>
>
> Thanks
The connection test in SM59 only does a basic PING to the web service endpoint. Often it will show OK, when in fact the ADS is not setup correctly. That is why there are some test applications that do more.
For proper testing of your setup see OSS Note 944221. But basically run the ABAP programs FP_PDF_TEST_00 and FP_CHECK_DESTINATION_SERVICE. You can also try running the web dynpro components WDR_TEST_ADOBE and WDR_TEST_ADOBE_PDF_ONLY -
Display archive doc as pdf from web dynpro?
Hi All,
We have a situation where we want to display archived pdf's from a web dynpro. I have put an interactive form ui element on my view and bound this to an attribute of type xstring on the context.
When I run it, i get an error message saying that file does not begin with '%PDF-'. I've tried putting this on the front of the string but i didn't work either.
So can anyone tell me the process for displaying archived pdf's from a web dynpro.
Many thanks in advance,
Liz.This is the code necessary to get it to work:
get optical archive id of pdf to display
select single * from toahr into ls_toahr
where sap_object = 'PREL'
and OBJECT_ID = lv_obj_id
and ar_object = ls_zhr_paylsip-zhr_doc_type.
lv_archiv_id = 'H1'.
lv_document_type = ls_toahr-ar_object.
lv_archiv_doc_id = ls_toahr-arc_doc_id.
lv_signature = 'X'.
lv_compid = 'data'.
free lt_binarchivobject.
call function 'ARCHIVOBJECT_GET_TABLE'
exporting
archiv_id = lv_archiv_id
document_type = lv_document_type
archiv_doc_id = lv_archiv_doc_id
ALL_COMPONENTS =
signature = lv_signature
compid = lv_compid
importing
length = lv_length
binlength = lv_binlength
tables
archivobject = lt_archivobject
binarchivobject = lt_binarchivobject
exceptions
error_archiv = 1
error_communicationtable = 2
error_kernel = 3
others = 4.
if lt_archivobject[] is not initial.
describe table lt_archivobject lines lv_rowcount.
lv_rowcount = lv_rowcount * 1024.
call function 'SCMS_BINARY_TO_XSTRING'
exporting
input_length = lv_rowcount
first_line = 1
last_line = lv_rowcount
importing
buffer = lv_xstring
tables
binary_tab = lt_binarchivobject
exceptions
failed = 1.
endif.
Where yo bind lv_xstring to the the pdfSource via the context -
Regd PDF Printing from Web Dynpro
Hi,
We are using NW04s SP10 . I need to show the data coming from RFC as PDF in Web Dynpro. The RFC is returning String as output after SAP Script is converted to PDF . Below is the code i have written in WD for opening as PDF. When i try to open it as PDF, I am getting message in acrobat reader "<i>The file is damaged and could not be repaired</i>" . Did anyone faced the similar problem before?
//Converting the string to binary
b = wdContext.nodeOutput().nodeBinary_File().getBinary_FileElementAt(i).getBin_File().getBytes();
pdfResource=WDWebResource.getPublicCachedWebResource(b,WDWebResourceType.PDF,WDScopeType.CLIENTSESSION_SCOPE,wdThis.wdGetAPI().getComponent().getDeployableObjectPart(),"Test"+i);
pdfResource.setResourceName("test.pdf");
wdComponentAPI.getWindowManager().createExternalWindow(pdfResource.getURL(),"Test"+i,false).open();
Thanks,
VasuHi all,
I am able to solve myself. The problem is with the generated data. Now i am able to see the PDF but i am facing issue in showing the data in pdf which i have posted in another thread.
Thanks,
Vasu -
My Mac won't print a pdf from the web
My iMac will not print any pdf from the web. The printer (an ho Photosmart plus) will only print a blank shet of paper.
Try saving the file then, then open Preview and open the file and try printing again. If if the quality is still bad then it's the file itself.
-
We are planning to Silent print a PDF from a web page using Flex. We are targeting Windows and Mac with Arcobat reader installed. I have tried using the AIR appliaction and it worked, But our requirement is NO INSTALL to the user machine for the silent printing. It is just from web page and silent printing to the default printer to the desktop/Laptop. Can anyone share your thoughts and experience with us. It will be very helpful..
For AIR : I tried the thread Re: AIR and PDF showing/silent printingHey CodeMonkey & Ross,
Did you either of you ever find a solution? I'm stuck too, it seems I can get remote printing on all these PDFs to work but it just prints a blank page since I've been using Javascript in the browser, not Adobe's (they are Engineering drawings that I do not have permission to edit so I can't just insert code into them but I need to make work instructions). I've been scouring the internet for hours now, it seems that this thread is the only relevant/useful one at this point. No one else was trying to achieve this for similar reasons to mine.
Thanks guys,
Lox -
How to get the Response Code when a URL is launched from Web Dynpro
Hello Experts,
I have a Web Dynpro Application in which in one of its views i have an IFrame UI element in which i will show a resource stored somewhere ..
But before showing it i want to check if the resource actually exists. For this i have to check the HTTP Response code from Web Dynpro Application without setting it in the Iframe..
I am using the following code to get the Response Code:
try{
URL url = new URL("Some Url");
HttpURLConnection.setFollowRedirects(false);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.connect();
wdComponentAPI.getMessageManager().reportSuccess("Response code ="+connection.getResponseCode());
}catch(Exception e){
wdComponentAPI.getMessageManager().reportSuccess("Exception");
Now the Problem is whatever response Code occurs 403 (for No Proper Authorization), 404 (for Resource not found) etc..
i always get Response Code= 500 (which is for Internal Server Error) shown in the messgae i have printed.
Please let me know the correct way of getting the Response Code from Web Dynpro.
Also my resource is lying on a SAP Portal 6.4
Best Regards
Sundeep
Edited by: Sundeep Sethi on Feb 18, 2008 9:07 AM
Edited by: Sundeep Sethi on Feb 18, 2008 10:23 AMHi,
Check this code from /thread/5242768 [original link is broken] if it works.
try{
URL myurl = new URL("http://calendar.google.com");
URLConnection connection = myurl.openConnection();
if(connection instanceof HttpURLConnection) {
HttpURLConnection httpConnection = (HttpURLConnection) connection;
HttpURLConnection.setFollowRedirects(true);
httpConnection.setRequestMethod("HEAD");
httpConnection.connect();
System.out.println("Response = "+httpConnection.getResponseCode());
catch(Exception e) {
// print exception
Regards,
Harini S -
Printing a PDF from a PDF generates a log file
I have pdfs that get generated from a web site and for whatever reason when I go to print them to pdf I just get a log file. I can print to pdf from any other pdf file. I need to do this so that it basically flattens the pdf and the end user can't see where I have typed or added a text box to blank out stuff.
I've tried examining the doc and stripping it of everything.
I've tried making it compatible with Acrobat 8 v1.7
I've tried opening in Acrobat STD, no security set and resave and yet when I open it backup the minimal security settings are back.
I have acrobat 8 std, and reader 8. The original pdf was v1.3, produced apparently from the web site with GPL Ghostscript 8.15, everything is allow in security except doc assembly, commenting, signing, creation of template pages.
Any help anyone can give would be greatly appreciated.
Thank you,
George
Here is part of the error log:
%%[ ProductName: Distiller ]%%
%%[Page: 1]%%
%%[Page: 2]%%
%%[Page: 3]%%
%%[ Error: limitcheck; OffendingCommand: ;#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#23 23#2323#2323#2323#2323#2323#2323#2323#; ErrorInfo: DictCRC --nostringval-- ]%%
Stack:
58
[/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /;#2323#2323#2323 /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef
/;#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323#2323There is one on the fonts tab of the settings. This one is for problems with embedding and says to create the PDF anyway. Font embedding with unlicensed fonts is a common problem for failure in the creation process and that is why I was suggesting it. Also, your discussion of security raises a flag. It suggests that there is some security setting and that may be the issue.
-
File, create PDF, from web page, entire site...questions
I am new to adobe, is this the proper forum for Adobe Acrobat 9 Pro for macintosh? I think yes...
Created a PDF from: File, create PDF, from web page, entire site.
Is there a way to print this without the background color? If you printed from a browser, you could choose not to print the back ground color. I know exactly the color.
Is there a way to make this PDF look like the web, with no page breakes? I have tried various things, but the page breaks are always displayed.
Is there a way to create bookmarks on somthing other than the title tag in the web site? The title tag is an SEO 1 sentence summary of the page, which makes for very long book mark names.
Thanks for your help.
bob
www.answerstat.netI don't use v9, but what I would do is click the FILE--PRINT option, print to PDF, and enter to print one page (default is first page)
-
Printing to PDF from AI makes Random Thicken Lines
This is my first time ever posting because after seaching this forum over and over...I can't find my answer.
Problem: I am working on an AI file created in CS3 that contains linework from AutoCad 2008. I did not import this linework because I didn't feel like redoing all the lineweights, instead I just printed a pdf from AutoCad and opened it into Illustrator. All of that worked very well.
The problem arises when I want to save as a pdf or print to pdf from Illustrator once my drawing is done. Some of the linework that originated in AutoCad is randomly thickened in the middle. So a segment of the line that has a stroke of .48pt when printed shows up like the middle of the line segment has bulged out to 6pt stroke. Very random lines all over the drawing.
I have looked for inconsistancy in both the Cad file and AI file to determine what could be making these lines "bubble" in the middle.
I will post the Ai file and pdf if it helps...I am desperate for a solution as this problem is super bizarre and really slowing me down. Has anyone had this problem and has a solution?
thanks in advanceGeneral Acrobat Problem Steps
If you are having problems creating a PDF, there are two steps you should do FIRST
Go to the appropriate vendor web site and apply all updates to the program you are using (several recent messages have concerned problems with MS Office conversion, with the response that different versions of Office have different BUGS that must be fixed by a download from Microsoft - and MS Office products are not the only ones which may, from time to time, need to be updated to work properly)
Apply all updates IN NUMBER ORDER
Acrobat Update http://www.adobe.com/support/downloads/product.jsp?product=1&platform=Windows
Also, for Office 2007, see if this Microsoft product will work for you
http://www.microsoft.com/downloads/details.aspx?FamilyId=4D951911-3E7E-4AE6-B059-A2E79ED87 041&displaylang=en -
I have Acrobat 9 Pro under Wins XP. I am using the "Create PDF from Web Page" feature. I would like to capture only one page out of 36. The capture setting is at its minimum (one level) and the "entire site" box is unchecked. Does Acrobat have the ability to do this? If so, what is the setting.
Any help is appreciated.
JeanI don't use v9, but what I would do is click the FILE--PRINT option, print to PDF, and enter to print one page (default is first page)
-
Need help on Printing Samrt Form via Web Dynpro
Hi All !
How can I print smartform that is displayed as PDF in web dynpro by clicking my custom button.
I am unable to get solution please help me.
Thanks & Regards!
KrishnaHi Ragavendra !
Thank you for telling but its not the solution for my problem .
Actually I need a custom button "Print All' that prints all smart forms.
Not individually by clicking print button.
Thanks ! -
When trying to print to PDF from a sales program we use it keeps throwing errors
When several people try to print to PDF from MAS90, it will save it and create a file as it normally does. However, it does not open in Acrobat 9 Pro as it normally does, and displays the famous error "Acrobat could not open 'xxxx.pdf' because it is either not a supported..." Yet when you manually open the file from the file system, it opens just fine.
So to rehash what I just said, when I print to pdf, it asks me where to save, the notification said the printing completed, adobe opens and displays error. If you click on the file, then the file opens just fine.
However several other people do not have this error while trying to print to file from mas90. Does anyone out there have any idea what could possibly be causing this error to be displayed?Hi ftd12300,
Are you saving the PDFs you're creating to a network drive or are they being saved locally?
Do you have this problem when creating PDFs from other applications such as Notepad?
-David
Maybe you are looking for
-
We are using a Mac mini Server (mid 2010) 2.66 GHz Intel Core 2 Duo, 4GB 1067MHz DDR3, NVIDIA GeForce 320M 256MB machine. There are 2 500GB hard disks which have each been partitioned into 2 separate logical disks of 250GB each (in total 4 logical 25
-
IS- Retail - Cycle count during business hours
Hi , I am trying to do cycle count thru the POS system, and this is during business hours. We want to perform cycle count at the stores using the POS system and update SAP. I checked in SAP Help and its very confusing and its not step by step. T
-
I am running windows 8.1. Whenever I try to connect to the ITunes Store, I get the message that windows has stopped working. I have unistalled Itunes ran an update to the windows 8 for any updates. I then reloaded ITunes and the same thing happens
-
Logic freezes when trying to record 8th instrument.
Today is the LAST day I have to exchange my new iMac for a better one, and of course today is the first day I've had this problem. The first section of my project has 7 tracks playing together, and they do so just fine without any problems. When I mo
-
QOS Network Planning - TCP/UDP Ports used in CWMS 2.5 MDC deployment
Does anyone know if there is documentation that describes the WAN traffic in CWMS 2.5 MDC? I'm looking for the TCP/UDP ports that must be prioritized on the WAN to properly class our traffic between the two data centers. I can't find any such docum