cancel
Showing results for 
Search instead for 
Did you mean: 

How to make custom field disabled / enabled along with standard fields

Former Member
0 Kudos

Hi. I've added some custom fields to a few standard webdynpro screens in SRM 7, and it works fine except that my custom fields are always enabled.

All the standard fields are enabled or disabled depending on whether the user has pressed the edit button or not.

The standard fields do not have anything bound to the enabled property, how are they being controlled and how can I apply that to my custom fields?

I'm looking into reading the enabled property on the standard fields and setting a property bound to my custom fields, but have not got that working yet.

Any help greatly appreciated.


Dave.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Thanks but I already know how to make the make them enabled or disabled by binding the property to an attribute then setting the attribute value, but how do I know when to make them enabled or disabled?

Is there a way of reading the enabled (or read only) property of another field and using that to make mine enabled or disabled?

Former Member
0 Kudos

Hi David,

Yes you can do that way also. simply you see the event_handler method for the Edit button, Display button and there you set these parameters. If


Regards,

Ravikiran.K

Former Member
0 Kudos

in the config you also control what fields are output...this also applies to your custom fields, based on the structures you add them to.

and you can tie them to the screens that are say just for SC, for example. And yes, you can also maniupulate some of the characteristics via code.

Former Member
0 Kudos

Hi David,

Standard Fields enabling and disabling might be there somewhere in the code dynamically set.

For your custom fields,create a attribute of type wdy_boolean and bind this attibute to your custom fields enable property.

To enable your Custom fields,You have to set the binded attribute to abap_true , to disable set to abap_False. This setting can be done by coding.

1. Read the Node where the attribute was created.

2. set the attribute property based on your logic needed .

Regards,

Ravikiran.K