cancel
Showing results for 
Search instead for 
Did you mean: 

WD Abap - show pdf content

former_member193202
Participant
0 Kudos

hi folks,

i'm trying to show pdf content (type binary) with wd abap, but how?

- with interactive forms ADOBE -> i bound pdfsource the type binary value but i always get the message "ugly scripts are running at that url"

- "normal" interactive froms with a normal interface rather than pdf-data stream work.

we use NW2004s SP 05

any ideas?

kind regards oliver

Accepted Solutions (1)

Accepted Solutions (1)

thomas_szcs
Active Contributor
0 Kudos

Hi Oliver,

Have you bound the pdfSource to an attribute of type XSTRING and set enabled to false? For the display-only case the TEMPLATE_SOURCE does not need to filled and the dataSource doesn't need to be bound either.

Kind regards,

Thomas

former_member193202
Participant
0 Kudos

hi thomas,

i have pdfsource to an attribute type xstring (which is the pdf data stream), enable is NOT checked and TEMPLATE_SOURCE and DATASOURCE is not filled in.

The exceptions i get is:

WebDynpro Exception: Die URL enthält möglicherweise bösartiges Script ?ꯂѿ??

any hints?

kind regards,oliver

thomas_szcs
Active Contributor
0 Kudos

Hi Oliver,

Strange. The runtime performs a security check for all URLs, but the one for the PDF is generated by the runtime itself and therefore should not contain evil script g. When you go to st22, you should be able to see the generated URL in one of the variables. I was wondering, if you could post it please?

Kind regards,

Thomas

former_member193202
Participant
0 Kudos

Hello thomas,

all i can see in the dump which could be of interest is the following (but no url at all): ;-((

Nr. 22 Art METHOD

Name CX_WD_GENERAL=>RAISE

MSG

Die URL &A& enthält möglicherweise bösartiges Script

0000000000000000000000000000000000000000000000000000

0000000000000000000000000000000000000000000000000000

4662554224226676E6726F66666677667626F767766672567677

495052C061605E484C40D67C9385275935026312497530332904

thomas_szcs
Active Contributor
0 Kudos

Hi Oliver,

Is there a URL in a local variable of the method that calls CX_WD_GENERAL=>RAISE? When you move up the call stack by one level, you should be able to see it.

Kind regards,

Thomas

former_member193202
Participant
0 Kudos

hi thomas,

well i didnot see the url but i got out following acf trace:

ERROR|20060103160230|WD0284_5376|CAcfControl::ParseParameter|ReadArrayFromUrl failed, Url= http://cat01130.tyrolit.com:8080/sap/bc/webdynpro/tyed/ca_atcp_cre_0001/~wd_key43ACC6054ACC02C800000... error)

ERROR|20060103160230|WD0284_5376|CAcfControl::ParsePropertyParameters|ParseParameter failed|HRESULT=-2147467259(Unspecified error)

ERROR|20060103160230|WD0284_5376|CAcfControl::SendDataFromClientToAcf|SetProperty: ParsePropertyParameters failed for property dataSource|HRESULT=-2147467259(Unspecified error)

ERROR|20060103160230|WD0284_5376|CAcfControl::invoke|InovkeInternal failed|HRESULT=-2147467259(Unspecified error)

thomas_szcs
Active Contributor
0 Kudos

Hi Oliver,

Hmm.. ACF shouldn't be called for the display-only case, since only an iframe is used if enabled was set to false. I was wondering, if you could file an OSS ticket please? I think, this strange behaviour needs to be debugged to be analyzed further.

I checked your previous postings (sorry didn't see them earlier). It seems that you just want to display certain files at a user's PC. Is one of the following a suitable option for you:

(1) FileDownload control

(2) cl_wd_runtime_services=>attach_file_to_response()

(3) using an iframe

Each of these allow a user to download files from the server to his/her PC. Option (2) has lets you chose between display/save-as.

Kind regards,

Thomas

former_member193202
Participant
0 Kudos

hi thomas,

thanks so much, it is the best option, thats what i really nedded.

kind regards,

oliver

Answers (0)