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

Dynamically create dynpro?

MichiFr
Participant
0 Likes
1,272

Hi,

is there a way to dynamically create a dynpro or a dialog in ABAP? I mean I've got a structure with some fields in it, perhaps DDIC stored, and I would like to get a dynpro created with those fields in a horizontal order.

Is this possible using ABAP Objects or classic ABAP?

6 REPLIES 6
Read only

Former Member
0 Likes
962

If this is related to selection screen , then it is possible.

1. fetch the no of fields .These should be maintained in a database table with their technical attributes required on selection screen.

when you will fetch these fields , they will be in an internal table.

2. Lopp on this table and use select option to make the screen elements based on the technical attributes of various fields.

Hope you get it

Read only

0 Likes
962

Harsh,

thanks for your reply.

2. Lopp on this table and use select option to make the screen elements based on the technical attributes of various fields

I've got no problems to determine the elements of a structure or of a table, however, my problem is to build up some select options afterwards.

OK, the steps to build such a sequence of select options is certainly not the primary problem. Where should those options go? Into the current program, impossible I guess, so it seems that the solution itself is creating a new program at run-time which does this job.

OTH I still hope to find a better solution.

Read only

Former Member
0 Likes
962

Hi Fritz,

Please Debug SE11 After selecting fiedls for Selection

go contents (CTRLSHIFTF10) then go to Settings in Menu and go to Fields for Selection

You will get much of the info you are looking for.

Cheerz

Ram

Read only

0 Likes
962

Ok guys,

thanks for responding, however I think you did miss the point of my question, so I will try to rephrase it:

The DDIC structure I want to build a selection screen of:

  TYPES:
   BEGIN OF zsdsm_persist_mail_attachment,
     mail_immediately	TYPE char01,
     sms_immediately  TYPE char01,
   END OF zsdsm_persist_mail_attachment
   .

This structure is just an example ! The final application should be capable of taking any DDIC structure and build up a dynpro from its components.

So, this structure above, for example, should result in a dynpro like:

  PARAMETERS:
    p1  TYPE zsdsm_persist_mail_attachment-mail_immediately,
    p2  TYPE zsdsm_persist_mail_attachment-sms_immediately
    .

That's all!

Read only

0 Likes
962

Hi Michael,

did you ever try du debug SE16 after "Settings->Fields for Selection"?

Regards

Markus

Read only

0 Likes
962

maybe function module "STRUCTURE_EDIT" helps...??