Application Development 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: 

Change Class content from a report

Former Member
0 Kudos
320

Dear friends,

The requirement is to replace some content "ABC" with "XYZ" in all classes (or even from a list of classes taken from user input.

Is it possible to do this programatically from a report?

Thanks!
Rohan

1 ACCEPTED SOLUTION

horst_keller
Product and Topic Expert
Product and Topic Expert
105

What is "class content"? If it is source code why don't you simply read SAP's documentation and especially all the warnings there. Since it seems that you are not too experienced with that stuff, I'd say: Hands off!

8 REPLIES 8

horst_keller
Product and Topic Expert
Product and Topic Expert
106

What is "class content"? If it is source code why don't you simply read SAP's documentation and especially all the warnings there. Since it seems that you are not too experienced with that stuff, I'd say: Hands off!

0 Kudos
105

Thanks, Horst. And, thanks for the warning!

bertrand_delvallee
Active Participant
105

Hello,

That seems a desperate solution but it's doable.

Please, have a look at this thread :

https://archive.sap.com/discussions/thread/90787

Whatever solution you will choose, you should really consider changing "XYZ" by a call to a static method / class constant instead of a raw value.

Best regards

0 Kudos
105

Thanks, Bertrand. Will follow up that trail.

former_member182550
Active Contributor
105

I would go further and instead of modifying this value direct in code, modify the method to read from a table or something like that and then you would not need to change this in the code afterwards.

0 Kudos
105

Yes. If a global change like this is required, it's an indication of poor programming to begin with.

0 Kudos
105

<grins> and ducks.....

0 Kudos
105

I know, I know. This is for a poc we're working on, where we're trying to switch frameworks. Just an option that must eventually be struck off, but not before knowing the possibilities.