spacer
cornerspacercorner
0 Kudos

Improve re-usability of form segments in a library

Status: New Idea
by on 01-25-2012 05:21 PM

Form segments that rely on 'other business objects' are not as re-usable as they could be, because the parameters passed to the 'other business objects' they use may need to be set by the process, not the library.

 

For example, I may create a form segment to display the error log for a specific mapName and place it in a library. There is not a mechanism to re-use this form segment in a process and pass in a different mapName. (please tell me I'm wrong)

 

One way to fix this would be to 'promote' the data object's parameters up to the form-segment. The idea being that this segment could be put in a library, then later include in a process, dropped on a form, and the dependent business object parameters would be available to set according to the needs of the process.

Comments
by on 01-25-2012 11:53 PM
Just have a Local variable on the form segment, and set that on load from the form the segment is used in.
by Tony Wheeler Employee on 01-26-2012 02:25 PM
Hi Tom, Like Jerome suggested, you can already reuse form segments in libraries in the way you described as long as you only use Local variables on the form segment. After dragging an instance of the form segment onto your main form, you'll see the FormSegmentReference1Data object added under your Data Access tab. All Local form segment variables can be set here (for example on form load). To maximize portability/reusability, try to only pass in business objects or explicit values set in the calling process into the library and resist the temptation to use ProcessContext within the library. Letting anything within a library figure out what is “Current” hurts portability/reusability. I happen to have a sample solution that is very close to your scenario but I can't seem to attach a file in this forum. Send an email to the HelpDesk if you'd like to see it.
by on 01-26-2012 07:45 PM

There may still be an enhancement idea here.

 

I see that it is possible to use the local variables of a form segment to 'pass-along' information from the form to the components in the segment. Thank you for that info it is very helpful.

 

When trying to do more than just display data with the segment, but have some actions based on grid selection, it would appear there is some limitation related to being able to access 'non-static' variables.

 

Complicated situation, but basically I am trying to make a typical admin form that has a grid to select values and label fields + buttons to perform insert/update/delete. This works fine on a form. Would like to put this in a segment now so it can be re-used for several processes. Each process-specific form will have different access rights. The error I get is below if that helps understand the limitation I'm suggesting be removed. 'Grid1' is in the form segment.

 

Cannot access a non-static member of outer type 'Metastorm.Runtime.Models.ww_scripting.wwAppLookup' via nested type 'Metastorm.Runtime.Models.ww_scripting.wwAppLookup.Declarations.wwAppLookup_Grid1_WhenUserSelectsRow.Declarations.CodeActivity1'

by on 01-30-2012 11:30 AM

The example and advice from Tony and Jerome addressed all the problems I was having. This 'idea' can be deleted as the functionality I was asking for already exists. Thanks again.

 

Tom

Announcements
New Phone Numbers and Email Address for Customer Support
US: +1 800-970-5209
International: +1 585-424-2339
BPSSupport@opentext.com

Why and How to Register

How to Be Notified of New Releases

How to Suggest Product Enhancements

Custom Avatars

Metastorm BPM 7.6.4 Hotfix 2 (7.6.4.2) is now available for download in the 'Patches' section of the Knowledge Center here.

Metastorm BPM Widgets Release 2 for OpenText Smart Business Workspace Version 9.1 and Metastorm BPM 9.1.3 is now available for download in the 'Patches' section of the Knowledge Center here. For more information see this post.

Metastorm BPM 9.1 SR3 (9.1.3) is now available for download in the 'Patches' section of the Knowledge Center here. For more information see this post.

Metastorm BPM 9.1.2 Hotfix 2 (9.1.2.2) is now available for download in the 'Patches' section of the Knowledge Center here.

Note: Software and documentation are now in the Knowledge Center (KC) located here.

Have a question about the Community Site? Contact Us

Top Kudoed Authors
line spacer line
spacerFollow Metastorm on:
spacer Twitter YouTube Blog iTunes LinkedIn Metastorm Community Central, MC2
spacer Copyright © 2011 OpenText Corporation. All Rights Reserved.spacer About Metastormspacer Privacyspacer Legalspacer Site Mapspacer RSSspacer Contact Us
Microsoft Gold Certified Partner
Powered by Windows Azure
line spacer line