Process Mapping Logo

Process Mapping - Forums

Sharing 19 years of knowledge and experience

 
Metastorm BPM forums
Sign up Latest Topics
 
 
 


Reply
  Author   Comment  
Robbath

New Member
Registered:
Posts: 3
Reply with quote  #1 
Hi,

I have a Stage that displays multipule forms to display as tabs (which allow the users to view read-only versions of the forms). Each form correlates to an Action that opens one of the same forms from the same stage. Ie the same form can be opened either as a 'Read-only' form via the top tabs, or can be opened in an editable version via the actions buttons at the bottom.

Now on one of these forms I have a check box that is populated with the following calculation formula:

( (%Action.Name = "Example Action Name") )          

The problem I have is when I open a form via the action (ie via the bottom buttons) the action is fired, and the check box is set to true as expected. However when The same form is opened via the top tabs (ie in read-only) it will pick up the name of the last action to have been fired; so if the last action to have been fired happens to correspond to the particular form that has been opened the checkbox is also set to true when the form is viewed.

So my question is how can I set the checkbox to true only when the correct action has been fired, but not when the the user accesses the form via top-tabs? Ie is there a way of determining whether a form has been accessed via an action, as opposed to via the top-tabs?


0
Doogal

Avatar / Picture

Guru
Registered:
Posts: 1,564
Reply with quote  #2 
There is another approach due to a bug in the implementation of %User.Form. See the following post
http://metastorm.processmapping.com.au/tool/post/ework/vpost?id=1400372
0
Pete

Senior Veteran
Registered:
Posts: 315
Reply with quote  #3 
Robbath which version are you using? Have you looked around in the Metastorm Knowledgebase if it's a known bug? Because the way you try seems correct to me... If it's a Version 7.5 or higher I'd report it to Metastorm
__________________
If you want the job done right, hire a professional.
0
Robbath

New Member
Registered:
Posts: 3
Reply with quote  #4 
Thanks for the fast replies,

I forgot to add that it only incorrectly registers the action (when accessing the form from a stage) when the user has closed the action form incorrectly (via the x). Obviously BPM has no way of knowing this (as the session/db entry won't have expired (I don't know how it is actually storing it's status; perhaps the eAction table?)). As such I was hoping that viewing a form from a stage (instead of from an Action) might set some other variable somewhere... but I guess not?

Pete - sorry, I'm not sure of the exact version that I'm using (not at work at the moment), but it's BPM 7.x. 

Doogal - that looks interesting, but should I really be coding to intentionally use a bug? Mind you I might give it a try...

Thanks again,

Rob
0
Jerome

Avatar / Picture

Guru
Registered:
Posts: 5,507
Reply with quote  #5 
Yup, this is what happens, and has been happening for a very long time. As Doogal points out, it is documented on this forum elsewhere, as is a workaround.

I have pointed out to Metastorm that:

1. The documentation is incorrect

2. The example posted on their site of how to hide fields at stages is incorrect

The only response I have had is "that's the way it works, now", I'm afraid. Perhaps if you try you will get a better response these days.


__________________
Post an example, and we will have a much better idea what the problem is. In about 90% of posts, the problem is one of communication. Examples bridge that gap.
0
cclewis

Member
Registered:
Posts: 43
Reply with quote  #6 

This is not directly related, but I was wondering if anyone new of a method to determine which form is currently being display at a stage.  I know you can get this during an action.


__________________
Clarence Lewis
Senior Process Engineer
Business Transformation Institute
0
Jerome

Avatar / Picture

Guru
Registered:
Posts: 5,507
Reply with quote  #7 
%User.Form will be filled with the form name, bot only after a form refresh. That may not help in most cases, and AFAIK there is no other way.

__________________
Post an example, and we will have a much better idea what the problem is. In about 90% of posts, the problem is one of communication. Examples bridge that gap.
0
Doogal

Avatar / Picture

Guru
Registered:
Posts: 1,564
Reply with quote  #8 

%Form.Name was introduced in 7.5 (I think) that should work in all cases.

0
cclewis

Member
Registered:
Posts: 43
Reply with quote  #9 

Thanks for the suggestions, but apperently they haven't implemented it yet in 7.5 or 7.6 


__________________
Clarence Lewis
Senior Process Engineer
Business Transformation Institute
0
Doogal

Avatar / Picture

Guru
Registered:
Posts: 1,564
Reply with quote  #10 

I may be misunderstanding what you're trying to achieve but %Form.Name is definitely there in 7.6 and I'm pretty sure it's available in 7.5 as well.

0
cclewis

Member
Registered:
Posts: 43
Reply with quote  #11 
The designer in either version did not recognize %Form.name.  I will verify again, but I know it complained that it didn't understand %Form.name.



__________________
Clarence Lewis
Senior Process Engineer
Business Transformation Institute
0
Doogal

Avatar / Picture

Guru
Registered:
Posts: 1,564
Reply with quote  #12 
Looks like it was introduced in 7.5 SR1

Behavior of %User.Form and %Form.Name in Versions of Metastorm BPM

Created: 25 Aug 2005
Last edited: 13 Nov 2007


The information in this article applies to:

Product: Metastorm BPM (e-Work)
Version: 6.x 7.x

Discussion

  • The following is adapted from the Metastorm BPM documentation.

    Metastorm BPM version 7.5 SR1 (7.5.1) corrects the behavior of %User.Form. Once this update is applied, %User.Form returns the form name in an action form (i.e. when the user has started an action and the action form is displayed). However, the function returns an empty value in a folder. This is the same behavior of %User.Form that existed with versions 6.x. In versions 7.0 - 7.5, %User.Form incorrectly returned the form name in both an action form and a folder.

    For users who have built procedures that rely on the incorrect behavior, a new function (%Form.Name) has been introduced. If process designers wish to have access to the form name in a folder, %Form.Name should be used. This returns the form name in both an action form and a folder.

  • The following is adapted from the Designer User Manual.

    %User.Form         The function %User.Form returns the form name (string, read-only name of the current form)          when viewed in an action, refill, or submit request. For example, the form name is returned          where a user has started an action and the action form is displayed.         

            This variable should be used only in the following properties:         Form - When user loads form.         Form - When user saves form.         Field - Calculation formula.         Field - List options.         Field - When button pressed, When field changed, and When user selects row.         Roles - When a role is used in the 'Restrict Viewing to roles' property of a form.        

            This function returns an empty value in a folder. The function %Form.Name also returns the form         name; however, unlike %User.Form, it does so in all situations, including in a folder.%Form.Name         The function %Form.Name returns the form name (string, read-only name of the current form)         when viewed in an action, refill or submit request. For example, the form name is returned         where a user has started an action and the action form is displayed.        

            This function also returns a value in a folder.        

            This variable should be used only in the following properties:         Form - When user loads form.         Form - When user saves form.         Field - Calculation formula.         Field - List options.         Field - When button pressed, When field changed, and When user selects row.         Roles - When a role is used in the 'Restrict Viewing to roles' property of a form.        

            The function %User.Form contains similar functionality except it returns an empty value in a folder.                                        

Keywords: kb622

0
cclewis

Member
Registered:
Posts: 43
Reply with quote  #13 
Ok.  Here is the problem.  I ran a test and it works.  I can get the form name from at a stage level.  However, the Designer's validation doesn't recognize %Form.name.  It gives a warning stating that the variable does not exist.

So the result of our collaboration is,

1)  Yes, you can get the formname at anytime by using the %Form.name in version 7.5.1

2)  No, the designer does not recognize this variable.



__________________
Clarence Lewis
Senior Process Engineer
Business Transformation Institute
0
Previous Topic | Next Topic
Print
Reply

Quick Navigation:


Create your own forum with Website Toolbox!