How to create ALV as a POPUP in abap web dynpro?
I have a requirement to display an ALV report as a popup for ESS application in HR module. Data fetching and binding is done in component controller
WDINIT method and it is displaying ALV in ESS. Now my requirement is to show this alv as a popup in ESS, I have used the method "Generate_Popup" using wizard however it is showing error that "Instance is already used for window".
Please let me know how to create POPUP alv where data fetching is done in "Component controller" hence I have only 1 view and 1 window in my web dynpro program.
Below is the logic for data fetching and data binding in WDINIT method of "Component controller":
method WDDOINIT .
DATA: lv_pernr type p0105-PERNR,
lv_user TYPE P0105-USRID.
lv_user = sy-uname.
CALL FUNCTION 'RP_GET_PERNR_FROM_USERID'
EXPORTING
begda = sy-datum
endda = sy-datum
usrid = lv_user
usrty = '0001'
IMPORTING
USR_PERNR = lv_pernr
EXCEPTIONS
RETCD = 1
OTHERS = 2.
IF sy-subrc = 0.
TYPES: BEGIN OF ty_pa2001,
PERNR TYPE PERSNO,
SUBTY TYPE SUBTY,
ENDDA TYPE ENDDA,
BEGDA TYPE BEGDA,
END OF ty_pa2001.
DATA: lt_pa2001 TYPE TABLE OF ty_pa2001.
"Changes by shiromani
DATA lo_nd_node_pernr TYPE REF TO if_wd_context_node.
DATA lo_el_node_pernr TYPE REF TO if_wd_context_element.
DATA ls_node_pernr TYPE wd_this->element_node_pernr.
* navigate from <CONTEXT> to <NODE_PERNR> via lead selection
lo_nd_node_pernr = wd_context->get_child_node( name = wd_this->wdctx_node_pernr ).
* get element via lead selection
lo_el_node_pernr = lo_nd_node_pernr->get_element( ).
* @TODO handle not set lead selection
IF lo_el_node_pernr IS INITIAL.
ENDIF.
* get all declared attributes
lo_el_node_pernr->get_static_attributes(
IMPORTING
static_attributes = ls_node_pernr ).
SELECT PERNR
SUBTY
ENDDA
BEGDA FROM pa2001
INTO CORRESPONDING FIELDS OF TABLE lt_pa2001
WHERE pernr = lv_pernr AND subty = 'ITEL'.
if sy-subrc = 0.
DATA lo_nd_node_details TYPE REF TO if_wd_context_node.
DATA lo_el_node_details TYPE REF TO if_wd_context_element.
DATA ls_node_details TYPE wd_this->element_node_details.
* navigate from <CONTEXT> to <NODE_DETAILS> via lead selection
lo_nd_node_details = wd_context->get_child_node( name = wd_this->wdctx_node_details ).
* get element via lead selection
lo_el_node_details = lo_nd_node_details->get_element( ).
lo_nd_node_details->bind_table( lt_pa2001 ).
* alternative access via index
ENDIF.
ENDIF.
endmethod.
Hi
You ca use this function to Create a new window..
CALL METHOD wd_window->create_window
EXPORTING
modal = abap_true
window_name = 'MMPUR_CPPR_RFQ_WDW'
title = lv_otr_text
close_button = abap_true
button_kind = 3
close_in_any_case = abap_true
RECEIVING
window = wd_comp_controller->window.
wd_comp_controller->window->open( ).
here you acn impliment buttons, if you want to subcribe window button please use this window subcribe method.
CALL METHOD wd_comp_controller->window->subscribe_to_button_event
EXPORTING
button = if_wd_window=>co_button_ok
action_name = 'RFQ_WT_VENDOR'
action_view = l_api
is_default_button = abap_false
button_text = lv_otr_text
tooltip = lv_otr_text.
wd_comp_controller->window->open( ).
Please let me know if you have any issue. Please reword if its solve your problem.
Regards
Satrajit
Similar Messages
-
How to create a user in UME Database using web dynpro java custom application
Hi,
Can you please suggest me how to create a user in UME Database using web dynpro java custom application.
My Requirement is user can register his/her user id in SAP Portal 7.3 UME database.
Please suggest me.
Thanks and Regards,
AmitHi Amit,
Generated Documentation (Untitled)
This is what you're looking for, there's no real cook-book -- though Amey mentioned there might be some material on SDN, perhaps some tutorials.
You should be looking into com.sap.security.api.IUserFactory, methods newUser(String) which gives you and IUserMaint and commitUser(IUserMaint, IUserAccount) -- IUserAccount can be obtained using com.sap.security.api.IUserAccountFactory, method newUserAccount(String)
Hope it helps,
D. -
How to create table in interactive form via Java Web Dynpro
Hi,
How to create table in interactive form via Java Web Dynpro ?
Any online tutorial / example ?
Thank you.
Regards,
EricHi Eric,
Just choose the UI element Table from Form Library and drag and drop it on the form. now choose the no. of rows and columns and other settings you want about table from the wizard initiated through this process. This all is what you have to do to create the table. Now to bind it to the fields of the data source bind the individual colums to individual attributes of the node in the datasource.
Hope it will solve your query.
Regards,
Vaibhav Tiwari. -
How to create the Dynamic UI element table in web dynpro in abap
Hi All,
Does anybody have reference note or teach me how to create dynamic UI element table in web dynpro in abap ?
Regards,
LukeHI LukeWong ,
for creating any UI dynamically you shoul use their runtime class that always start with cl_wd_* ui element name*
so for the Table UI element the runtime class is CL_WD_TABLE
now reffer the below code for creating the Table UI dynamically
METHOD wddomodifyview.
DATA lr_table TYPE REF TO cl_wd_table.
DATA lr_flow_data TYPE REF TO cl_wd_flow_data.
DATA lr_container TYPE REF TO cl_wd_uielement_container.
DATA lr_column_name TYPE REF TO cl_wd_table_column.
DATA lr_text_view TYPE REF TO cl_wd_text_view.
DATA lr_table_header TYPE REF TO cl_wd_caption.
DATA lr_column_name_header TYPE REF TO cl_wd_caption.
IF first_time EQ abap_true.
lr_container ?= view->get_element( 'ROOTUIELEMENTCONTAINER' ).
lr_table = cl_wd_table=>new_table(
id = 'TBL_TABLE'
bind_data_source = 'TABLE'
design = cl_wd_table=>e_design-alternating
visible_row_count = 3
lr_flow_data = cl_wd_flow_data=>new_flow_data( element =
lr_table ).
lr_container->add_child( lr_table ).
lr_column_name = cl_wd_table_column=>new_table_column(
id = 'TBL_EXAMPLE_NAME'
lr_table_header ?= cl_wd_caption=>new_caption( text = 'Table UI elem
ent - example').
lr_table->add_column( the_column = lr_column_name ).
lr_table->set_header( lr_table_header ).
lr_text_view = cl_wd_text_view=>new_text_view(
id = 'TXV_NAME'
bind_text = 'TABLE.NAME'
lr_column_name_header ?= cl_wd_caption=>new_caption( text = 'Name').
lr_column_name->set_table_cell_editor( the_table_cell_editor = lr_text_view).
lr_column_name->set_header( lr_column_name_header ).
ENDIF.
ENDMETHOD.
Regards
Chinnaiya P
Edited by: chinnaiya pandiyan on Sep 17, 2010 12:01 PM -
Creating a report in EP portal using Web Dynpro
Hi all,
Can anyone guide me how to create a Report in EP portal using Web Dynpro.
Regards,
R.V.EasterHi,
You should read the documentation ([Web Dynpro ABAP: Development in Detail|http://help.sap.com/saphelp_nw70/helpdata/en/03/0048413e466e24e10000000a155106/frameset.htm]) and study the tutorials : [Go and Create First Application with Web Dynpro ABAP|http://help.sap.com/saphelp_nw70/helpdata/en/e6/2c4b29dc87c6409d6469ec390e8f3d/frameset.htm] and [Creating a Simple Flight Info Application|http://help.sap.com/saphelp_nw70/helpdata/en/e6/2c4b29dc87c6409d6469ec390e8f3d/frameset.htm].
Regards,
Pierre -
How to create alv table dynamically by performing action on the button.
Hi all,
my requirement is to create alv table dynamically.
that is i will create two buttons
1) show alv table
2) close alv table
if user selects show alv table then the alv table should be displayed.
and if user selects clsoe alv table then the alv table should be closed.
to create alv table dynamically i have followed this procedure.
under view properties i have added salv_wd_table component. then under the action of showalvbutton i went to code wizard and i have selected instantiate used component component use salv_wd_table. the following code will be generated
with this code i am unable to display alv table dynamically correct me where i went wrong kindly send me the necessary steps how to create alv table dynamically
data lo_cmp_usage type ref to if_wd_component_usage.
lo_cmp_usage = wd_this->wd_cpuse_salv_wd_table( ).
if lo_cmp_usage->has_active_component( ) is initial.
lo_cmp_usage->create_component( ).
endif.
to close table i have used the following code. with this code i am able to achieve the functionality to delete the alv table
data lo_cmp_usage type ref to if_wd_component_usage.
lo_cmp_usage = wd_this->wd_cpuse_salv_wd_table( ).
if lo_cmp_usage->has_active_component( ) is initial.
else.
lo_cmp_usage->Delete_component( ).
endif.
Thanks & Regards,
Naveen
Edited by: naveen.webhelp on Feb 10, 2011 5:52 AMHi
ALV table will be shown in the viewcontainerUI element.
it is shown there empty if you dont fill the node bound to the data node of the interface controller of the comp usage
SALV_WD_TABLE.
and if you are not getting the table filled in the first place.
then check have you mapped the DATA node to some node in the comp controller
wht basically is your requirment is that you want to show ALV gird on click of one button and delete it on click of other button.
there are many ways to do so.
best way is control the visiblity of the viewcontainer UI element which containes the TABLE view of SALV_WD_table comp.
create an attribute of type WDUI_VISIBILITY name say VIS.
now go to the layout and bound hte visible property of the viewcontainer to this attribute VIS.
then in the showalv grid button's eventhandler write
wd_context->set_attribute(
name = 'VIS'
value = '02'
and in the wddoinit and delete alv grid button's event handler write
wd_context->set_attribute(
name = 'VIS'
value = '01'
thanks
sarbjeet singh -
How to show modal window without popup in a web page using javascript
Hi,
How to show modal window without popup in a web page using javascript, means when the modalwindow is opened it should not ask for popup blocker alert......
pls help me.....Thanx for ur reply,
Actually the senario is when i click on a button, another jsp page should be displayed in a modal window without popup, but the functions alert() and confirm() will not accept the url path of the another jsp page... -
How to create the Table of Content (TOC) in WEB
Dear Sir
Please help me
How to create the Table of content (TOC) in Web Intelligence Report,
Thanks
Gnanasekarn.K
Edited by: Gnanasekaran Kandasamy on Nov 20, 2008 11:12 AMHi Gnanasekarn,
You can create TOC in webi using Open Document, You can create link on the TOC and you can connect that link to open new report .
With the help of open document you can open the specific portion of report.
So you can achive your requirement using URL reporting or Open Document.
Regards,
Chaitanya Deshpande -
How To Create A Technical And Business Systems For Web AS ABAP ???
Hi Experts,
How To Create A Technical And Business Systems For Web AS ABAP ???
Please Let me Know All the Step-By-Step Process to Create ????
Points Will be Given
Regards
KhannaHi Sumit,
When U Told the thing that first time to execute the RZ70 and All i Did this in XI System
So I got An Entry for the Technical System for XI System.
Now i Deleted that and Executed RZ70 in R/3.
When I Executed RZ70, I got this Error.
<b> "RFC Call failed: Error Opening an RFC Connection "</b>.
Now I am Unable to see Any Technical System Under Web As ABAP. It's Showing Empty Now.
Please Let me know
Regards
Khanna -
How to create generic search help in wd abap
Hi experts,
How to create generic search help in wd abap.
Regards...
Arun.Hi Arun,
Following links have step by step procedures for creating search helps and other related topics.
<a href="http://help.sap.com/saphelp_nw04s/helpdata/en/3d/e53642e2a3ab04e10000000a1550b0/content.htm">ABAP Dictionary Search Help for WD</a>
<a href="http://help.sap.com/saphelp_nw04s/helpdata/en/9b/c51c42735b5133e10000000a155106/content.htm">Input Help in WD ABAP</a>
<a href="http://help.sap.com/saphelp_nw04s/helpdata/en/cf/21ee2b446011d189700000e8322d00/content.htm">Search Helps</a>
<a href="http://help.sap.com/saphelp_nw04s/helpdata/en/cf/21ee5f446011d189700000e8322d00/content.htm">Creating Elementary Search Help</a>
Regards,
Neha
<i><b>PS:Reward if helpful</b></i> -
How to Create a Restricted Key Figure in BO Webi Report
Hi Experts,
Please tell me How to Create a Restricted Key Figure in BO Webi Report.
Thanks in Advance.
Regards,
RafiHi,
1. Define a new measure in the designer.
2. In the select clause give the reference to the key figure on which restriction to be applied.
For example
@Select(Key Figures\Number of Records)
3. In the where clause, give the MDX expression for the filter to be applied.
For example
<FILTER KEY="[0PURCH_ORG].[LEVEL01]">
<CONDITION OPERATORCONDITION="InList">
<CONSTANT CAPTION="HAS"/>
</CONDITION>
</FILTER>
Regards -
How to create internal table storing instances of ABAP class
Hi experts, any one knows how to create internal table storing instances of ABAP class or alternative to implement such function?
Hi
Please see below example from ABAPDOCU, this might help you.
Internal Table cnt_tab is used to store class objects.
Regards,
Vishal
REPORT demo_objects_references.
CLASS counter DEFINITION.
PUBLIC SECTION.
METHODS: set IMPORTING value(set_value) TYPE i,
increment,
get EXPORTING value(get_value) TYPE i.
PRIVATE SECTION.
DATA count TYPE i.
ENDCLASS.
CLASS counter IMPLEMENTATION.
METHOD set.
count = set_value.
ENDMETHOD.
METHOD increment.
ADD 1 TO count.
ENDMETHOD.
METHOD get.
get_value = count.
ENDMETHOD.
ENDCLASS.
DATA: cnt_1 TYPE REF TO counter,
cnt_2 TYPE REF TO counter,
cnt_3 TYPE REF TO counter,
cnt_tab TYPE TABLE OF REF TO counter.
DATA number TYPE i.
START-OF-SELECTION.
CREATE OBJECT: cnt_1,
cnt_2.
MOVE cnt_2 TO cnt_3.
CLEAR cnt_2.
cnt_3 = cnt_1.
CLEAR cnt_3.
APPEND cnt_1 TO cnt_tab.
CREATE OBJECT: cnt_2,
cnt_3.
APPEND: cnt_2 TO cnt_tab,
cnt_3 TO cnt_tab.
CALL METHOD cnt_1->set EXPORTING set_value = 1.
CALL METHOD cnt_2->set EXPORTING set_value = 10.
CALL METHOD cnt_3->set EXPORTING set_value = 100.
DO 3 TIMES.
CALL METHOD: cnt_1->increment,
cnt_2->increment,
cnt_3->increment.
ENDDO.
LOOP AT cnt_tab INTO cnt_1.
CALL METHOD cnt_1->get IMPORTING get_value = number.
WRITE / number.
ENDLOOP. -
How to pass field symbol or table from one view to another view in abap web dynpro?
I am creating an Inbound Outbound ALV report in ABAP Web Dynpro. However at selection-screen I have select options and fetching is done at view2. Problem is we can pass parameter using inbound outbound parameters but how to pass internal table or field-symbols from one view to another view? I made use of Assistance Class too but its not very clear to me. Please give me some example or code to sort this problem out.
I am creating an Inbound Outbound ALV report in ABAP Web Dynpro. However at selection-screen I have select options and fetching is done at view2. Problem is we can pass parameter using inbound outbound parameters but how to pass internal table or field-symbols from one view to another view? I made use of Assistance Class too but its not very clear to me. Please give me some example or code to sort this problem out.
-
How to set a variable in portal session using web dynpro java.
Hi,
I have created a web dynpro application, which is running inside portal. I have created a role called "R1". Inside role R1, i have created 3 workset W1, W2 and W3. and inside each workset i have some pages and iviews.
My requirement is when user logins to the portal , and when he clicks on role R1 for the first time, a login page should come (so that we can do revalidation), and when he enters his password again in that login page , then only workset W1, W2 and W3 should be visible/accessible to him and after successful revalidation, if he clicks again on role R1, in that particular portal session, than that login page should not come.
for this, i thought i will set a variable in portal session, whenever user successfully revalidated himself, and if after successful revalidation he clicks again on role R1, i will check in doinit method of webdynpro whether variable is set or not (which i already set on successful revalidation), and if it is set then i will do Donavigation else i will present login page to the user.
Can anyone tells me how to set a variable in portal session using web dynpro java.
thanks
ArushHi,
Try this:
WDScopeUtil.put(WDScopeType.CLIENTSESSION_SCOPE, key, value)
WDScopeUtil.get(WDScopeType.CLIENTSESSION_SCOPE, key)
Ex:
WDScopeUtil.put(WDScopeType.CLIENTSESSION_SCOPE,"Key1","Value1");
String value1=WDScopeUtil.get(WDScopeType.CLIENTSESSION_SCOPE,"Key1").toString();
/people/william.cui/blog/2007/02/12/sharing-session-context-between-parent-and-external-windows-running-on-same-host
Regards,
Charan -
Creating 'Z' views for Standard ABAP Web dynpro Application
Hi Experts,
I am totaly new to ABAP web dynpro objects.
In our project there were some client requirements which required us to change the properties of the Views related to the Webdynpro. The Client now has said that he needs to apply some enhancement pathces on his system. Due to this, the changes made to the Views i.e all the changes done in standard code are lost.
The client now wants a long term solution where all the changes need to be done in 'Z' implimentataion so that changes are not lost every time the pathces are applied.
Is it possible to create an entire new 'Z' Views for the standard Webdynpro instead of standrad ones?
If Yes how does one link them to the Webdynpro application ?Hi
Have a look at following article about enhancing webdynpro applications.
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/700317da-bd79-2c10-368e-8f18bf5d8b81?quicklink=index&overridelayout=true
Regards
Manas Dua
Maybe you are looking for
-
Cannot scan to computer with HP Deskjet 1510 due to missing scan icon ?
Hi there, I have recently purchased a HP Deskjet 1510 series printer ; the installation of the drivers on my Windows XP laptop went well, however now when I double-click the HP Deskjet 1510 series icon on my desktop, the panel that opens up contains
-
How do I move a clip with transitions attached on the primary storyline?
One more frustrating problem with the mysterious magnetic timeline: on the priumary storyline I created a text clip with a gap clip on each side, then added cross dissolve at the beginning and end of the clip so that it fades in and out to black: Now
-
Is there a way to reference a variable name by the value of a String?
I realize my title may not be expressing the question accurately so... In perl I can do this: $varname = "nIterations"; ${$varname} = 27; which is the same thing as $nIterations = 27; Is there a way to do this in Java? eg I want something like String
-
hello planning to buy a mac mini i would like to know if if can be used as a recorder (just connecting a microphone to audio in). does it work ? is there anyone with real experience with it ? thanks in advance and have a nice weekend. Bruno
-
Does it have an audio out?
Does it have an audio out?