Better than private views

This tip describes how to give users an almost private view.

This tip gives users an "almost private" view. This formula will take the user's cursor directly to any category when the view is opened, it will expand the category showing all documents, it will always display neatly at the top of the view and will do so dynamically for individual users. Especially good when used with a view categorized by @Name.


Instead of seeing a categorized view like this: > Andrew Bacon > Bert Newton > Isaac Asimov > James Joyce > John Smith the user Isaac Asimov would see the following and won't even notice the other documents - he will just see his name at the top of the view and all documents underneath: >Isaac Asimov document.. document.. document.. document.. document.. document.. document.. >James Joyce >John Smith Steps: 1. Build categorised view (one based on notes name works well). 2. Add formula below to the PostOpen even of the view. 3. Modify the 1st line of the formula to include the current view alias. This formula requires custom _viewName and _key values per view. Formula: REM " =================================================================== " ; REM " Go to users personal category and expand, if available. " ; REM " Categorise view by Common user name (or anything to match the *_key* below) " ; REM " Note: *_thisView* must contain the name/alias of the current view "; REM " and must be modified per view. " ; REM " ==================================================================== " ; _thisView := "XXXXXXXX" ; _key := @Name([CN];@UserName) ; _val := @DbLookup( "":"NoCache" ; "" ; _thisView ; _key ; 1 ) ; @Command([ViewCollapseAll]) ; @If( !@IsError( _val ) ; @PostedCommand( [OpenView] ; _thisView ; _key ) : @PostedCommand( [ViewExpand] ) ; "" )
This was first published in July 2002
This Content Component encountered an error

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchWinIT

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchEnterpriseLinux

SearchVirtualDataCentre.co.UK

Close