on 02-06-2009 7:04 AM
Hi Experts,
I am running a smartform through VF31 T-code. If I press print button in that, thesmartform should be saved as pdf file and if I press preview button, I should have smartform preview.
My problem is whatever I do first, it is coming successfully. My code will be like below in driver program.
If sy-ucomm = 'PROC'.
" Code for pdf file save in presentation server.
Elseif sy-ucomm = 'VIEW'.
" Code for print preview.
Endif.
Sometimes I am able to get both the results, which I want. But sometimes only one comes. If I see preview and coming back If I press print button, It says the message "All selected jobs are completed", but no save window comes. If I save pdf first and if I press preview button secondly, preview doesn't come. If I go in debug, in second time, sometimes sy-ucomm value is null. What can I do for this?
What may be the problem. I have cleared all the variables also, before running second time.
Regards,
Venkat
Checked with wait up to 0 seconds and the sy-comm value got updated and got required result.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have cleared all the variables also, before running second time.
Hi Venkat
Did u clear sy-ucomm value also
if you have cleared that then that might be the reason that you are not getting required output for the second time as you are clearing sy-ucomm value
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vikas,
You are correct. I didn't clear sy-ucomm value. But When press different button(Print/Preview), It should automatically overwrite the previous value or if it is not overwriting also, I should get the result which I got last time( either preview/ pdf ). But it doesn't happen. I think, it would be tough to you to determine the problem, unless u see my code. Thank you for your consideration.
Regards,
Venkat
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.