Skip to Content
author's profile photo Former Member
Former Member

Setting values on system forms

Hi everybody,

I have to change dynamically, under certain conditions, some value on the Sales Order interface depending on user's selections. For example I could have to force the "authorized" checkbox on the "Logistic" tab folder or other UDF items in other folders.

-Setting values on the binded ORDR datasource (UDF or not UDF) is not allowed from the SDK because of "Item - The item is not a user-defined item".

-Setting the values directly on the UI item (i.e the checked property of a CheckBox) does not work when the tab folder is not Active.

Which is the right approach?

Many thanks.


Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Aug 16, 2015 at 08:22 PM

    Hi Daniele,

    As you can't write directly to the datasources on a system form, I typically use the following steps to change a value on a non-active tab:

    1) Read the current pane level and store in a variable.

    2) Freeze the form.

    3) Call the click method of the folder object where the field I want to change is.

    4) Change the value on the field using the item properties or methods.

    5) Click on the folder object for the original pane level.

    6) Unfreeze the form.

    Depending on the form design, you might have to call the click method on a field on the original pane (or on a field that is available on all pane levels).

    Kind Regards,


    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Owen, thank you for your response.

      Actually the solution you suggested is the only way I found to get closer to what I wanted to do.

      I have to set lot of items and slowdowns and the graphical result (even freezing the form) is really not acceptable.

      There is no other way?

  • author's profile photo Former Member
    Former Member
    Posted on Aug 24, 2015 at 01:56 PM

    There are only three "ways" to alter the database through a system form (believe me, I've tried everything I can think of):

    • UserDataSource - Intended to alter the contents of only one field
    • DBDataSource - Intended to load one entire recordset into a form
    • UI manipulation through code - a "hack", and as such, unsupported and very slow

    As far as I know, that's it. And it's VERY limiting. It looks like SAP intended any kind of data alteration to happen directly at the database level, and there is very little ability to change this through the "form" except through the UI, which is as you've found, incredibly slow.

    It would be nice if in some time in the future, SAP database objects could be manipulated easier in code, such as being able to cast them to temporary Visual Studio DataTables to be manipulated directly and then re-written back to the database with ease, but for now it looks like they REALLY want us to use their forms, their database structure, and their Screen Painter as much as possible.

    It wouldn't be quite so frustrating, if they weren't so limiting in functionality. Que sera, sera... c'est la vie.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.