cancel
Showing results for 
Search instead for 
Did you mean: 

To get the Application name

Madhu2004
Active Contributor
0 Kudos

Hai experts,

I have a requirement as follows:

I have a component named as ZComponent which has 3 view.

i am creating 2 applications for the component named as zappl1 and zappl2.

zappl1 starts from first view itsef where as zappl2 starts from second view.

I have an ALV table in the second screen.

it shud not be editable for ZAPPL1 and shud be editable for ZAPPl2.

Inorder to that i need to get the application name at runtime in the WDDOINIT METHOD of the second view.

Is there any method to get the application name.

If so plz help me as soon as possible.

IF any doubts revert back to me ASAP.

Cheers,

Madhu

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Madhu,

You do not need the application name for this. The following would work:

1. Create one more inbound plug to your window (interface view), other than the existing plug (default). The second plug should also be an interface plug of type "startup".

2. Create a node in your component controller with an attribute denoting the editable property.

3. Map this node in the window's context.

4. Your window will have 2 plug handlers, for each startup plug. Inside one handler, set the editable attribute to true and in the other, set the same to false.

5. Map the same node in the view controller also, and in your view layout, bind the "read only" attribute of your table to the node attribute.

6. Create a new application, zappl2 and in the default plug, specify the name of the second plug.

Launch both applications, your control should be editable in one and read only in the other.

Regards,

Nithya

Madhu2004
Active Contributor
0 Kudos

Hai nitya,

Thanks for the reply.

My problem is solved.

solution is as follows:

data : lv_name type WDY_APPLICATION_NAME.

lv_name = wdr_task=>application_name.

And u can get the application name.

Cheers,

Madhu

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Madhu,

Each application will have a separate default inbound plug. You can pass the "editable" value as an importing plug parameter, and set it in the window's plug handler. Let me know if this works, I am curious to know too.

Regards,

Nithya