on 2008 Oct 24 11:54 AM
Hi freinds,
I have an issue to be discussed with. I have created many driver programs to run smart forms which downloads PDF. All was working fine in production systems also. Now the client has noted none of these are working in any of the systems.
When i debugged each programs, i have noted that the internal table OTFDATA[] is not having any entries.
i.e.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = P_FORMNAME
IMPORTING
FM_NAME = FM_NAME
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2
OTHERS = 3
.
CALL FUNCTION FM_NAME
EXPORTING
CONTROL_PARAMETERS = WA_CTRLOP
OUTPUT_OPTIONS = WA_OUTOPT
USER_SETTINGS = 'X'
IMPORTING
JOB_OUTPUT_INFO = T_OTFDATA ***************************************** No data is here for all the programs
TABLES
T_ITAB = T_ITAB3
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
.
Could anyone help me reg this...
Hi sujeel,
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = ' Y_FORM1 '
IMPORTING
FM_NAME = V_FORM_NAME
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2.
IF SY-SUBRC 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
W_CTRLOP-GETOTF = 'X'.
W_CTRLOP-NO_DIALOG = 'X'.
W_COMPOP-TDNOPREV = 'X'.
CALL FUNCTION '/1BCDWB/SF00000482'
EXPORTING
CONTROL_PARAMETERS = W_CTRLOP
OUTPUT_OPTIONS = W_COMPOP
USER_SETTINGS = 'X'
IMPORTING
JOB_OUTPUT_INFO = W_RETURN
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4.
IF SY-SUBRC 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
I_OTF[] = W_RETURN-OTFDATA[].
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
FORMAT = 'PDF'
MAX_LINEWIDTH = 132
IMPORTING
BIN_FILESIZE = V_LEN_IN
TABLES
OTF = I_OTF
LINES = I_TLINE
EXCEPTIONS
ERR_MAX_LINEWIDTH = 1
ERR_FORMAT = 2
ERR_CONV_NOT_POSSIBLE = 3
ERR_BAD_OTF = 4.
IF SY-SUBRC 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Regards,
Sravanthi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
The control structures what i have filled is:
WA_CTRLOP-GETOTF = 'X'.
WA_CTRLOP-NO_DIALOG = 'X'.
WA_CTRLOP-PREVIEW = ''.
WA_OUTOPT-TDDEST = 'LP01'.
Still the T_OTFDATA has no value
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
set WA_CTRLOP-getotf = 'X'
before ur call functionFM_NAME
if still it doesnot work then
set user settings = ' ' in the call function FM_NAME
so ur code goes like this
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = P_FORMNAME
IMPORTING
FM_NAME = FM_NAME
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2
OTHERS = 3
.
WA_OUTOPT-getotf = 'X'
CALL FUNCTION FM_NAME
EXPORTING
CONTROL_PARAMETERS = WA_CTRLOP
OUTPUT_OPTIONS = WA_OUTOPT
USER_SETTINGS = ' '
IMPORTING
JOB_OUTPUT_INFO = T_OTFDATA ***************************************** No data is here for all the programs
TABLES
T_ITAB = T_ITAB3
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Does WA_CTRLOP-GETOTF = 'X'? The pdf is in T_OTFDATA-OTFDATA (I suppose T_OTFDATA is TYPE SSFCRESCL).
Regards,
Valter Oliveira.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
73 | |
10 | |
9 | |
8 | |
8 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.