cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP Webdynpro Print_Page( )

Former Member
0 Kudos

Hi,

I'm using Netweaver 7.02. I inserted a custom button 'PRINT' and on click <Component-controller>-print_page() is executed. After printing Web Dynpro ABAP view, the button 'PRINT' shows up in the print out. Is there a way to make the custom print button invisible before printing?

Thanks.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Df,

Create one attribute of type WDUI_VISIBILITY and bind this to PRINT button VISIBLE property.

In your button action before printing code...first write code to invisible button by using SET_ATTRIBUTE method

passing value '01' for invisible '02' for visible.

wd_context->set_attribute(
name = 'VISIBLE'  // your attribute name here..
value = '01' ). // for invisible

Cheers,

Kris.

Answers (2)

Answers (2)

Former Member
0 Kudos

Thanks, Kris and Srinivas.

I tried unsuccessfully to make the button visible after the PRINT event by immediately changing the visibility attribute in event handler. Addig an additional 'Refresh' button will work to bring back the 'Print' button but it's bit user unfriendly. I hope there will be a better solution in future by SAP. One of the solution can be like FileUpload UI element which automatically adds an input field and BROWSE button. Similarly, there can be a 'PRINT' UI element which will popup the print window.

Former Member
0 Kudos

Thanks Kris,

By setting the visibility attribute of the 'PRINT' button to '01' just before printing was able to hide the button during print out. However, when I closed the popped up print window without printing; or after printing when the it goes back to the page, the page understandably does not have the PRINT button anymore. The question is after printing or after closing the popped up Print window, is there anything that we can do to refresh the page so that the PRINT button becomes visble again.

Thanks.

Former Member
0 Kudos

Hi,

After your print code, at last you write same code by setting '02' value for visible. Try this, if not works.

For refresh create one button .. in that action reinitialaize all nodes ( i mean as it is what you are doing initially ).

Cheers,

Kris.

former_member199125
Active Contributor
0 Kudos

Hi...

I think, we cant refresh the print dailog window. Am i right?

i think We can controll of our applications but not standard one like print..If you have some custom functionality to refresh the page or window, there you can set the attribute value to 02 for visibility.

Regards

Srinivas