Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Status GUI and the Save Button

Former Member
0 Likes
1,281

Hello everyone!

I have been doing some researches about the Modules in PAI. What I want to do is to trigger a block of code in a program when you hit the "Save" button but it's an old program and there are tons of dynpros in it. But every one of their save button in each dynpro has to execute that same block of codes. I have a few choices that came to mind but all of them means rewriting everything in all the dynpros' PAI.

In fact, i was wondering if there was a way to have a common call for all dynpros of a program for the save button. You know, it's not that I mind to rewrite the call of a module every time in each PAI but I am thinking about giving a clean code and I was wondering if there was a common place to give a reaction to a click on the save button, whatever is the dynpro.

I'm not sure if my question is clear but I'll try to ask it better: Is there a place in the program you can put codes that would react at each time you click on the save button?

Thank you

Regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,211

Hello everyone!

> I'm not sure if my question is clear but I'll try to ask it better: Is there a place in the program you can put codes that would react at each time you click on the save button?

It sounds to me as if that's what you already have.

Rob

Hello everyone!

I have been doing some researches about the Modules in PAI. What I want to do is to trigger a block of code in a program when you hit the "Save" button but it's an old program and there are tons of dynpros in it. But every one of their save button in each dynpro has to execute that same block of codes. I have a few choices that came to mind but all of them means rewriting everything in all the dynpros' PAI.

In fact, i was wondering if there was a way to have a common call for all dynpros of a program for the save button. You know, it's not that I mind to rewrite the call of a module every time in each PAI but I am thinking about giving a clean code and I was wondering if there was a common place to give a reaction to a click on the save button, whatever is the dynpro.

I'm not sure if my question is clear but I'll try to ask it better: Is there a place in the program you can put codes that would react at each time you click on the save button?

Thank you

Regards

5 REPLIES 5
Read only

Former Member
0 Likes
1,212

Hello everyone!

> I'm not sure if my question is clear but I'll try to ask it better: Is there a place in the program you can put codes that would react at each time you click on the save button?

It sounds to me as if that's what you already have.

Rob

Read only

0 Likes
1,211

Well, no or else I wouldn't ask the question.... English is not my everyday language so I might have expressed myself badly

Let's say I have Dynpro 1000, 2000 and 3000 (the reality of my case is having way more dynpros).

Of course, I can write a MODULE and call it in the PAI of my three dynpros.

But is there a common place in the program where when I will click on SAVE, whatever I'm on Dynpro 1000, 2000 or 3000, the process will pass in a common code block? Or do I have to call a Module for each of them?

Read only

0 Likes
1,211

You have to have a module for each, but what I meant was, it sounds like that is what is already happening and each is calling the same code.

Rob

Read only

0 Likes
1,211

Alright! Thank you. I was pushing my curiosity at knowing if it was possible but I understand.

I'm closing this thread

Read only

0 Likes
1,211

Remember that each of your screens can have multiple GUI STATUSes, each with a save button and each with a different OK code.

Rob