Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Lotus Aprroach Scripts ? Visible Field box?

Status
Not open for further replies.

HelixLog

Technical User
Feb 26, 2007
1
AU
I have been and Approach user for some time now, but I have been Working with Macro’s, I’m now trying to understand Scripts. But with limited success.
There are two Scripts I’m interested in.
1. a script to turn a FieldBox off and make it invisible as data is Not required in that FieldBox to Use the fieldbox and make it visible on the Data Entry Screen A CheckBox is Ticked and the Value would be ‘True’ this could make the FieldBox Visable so that data can now be entered.
I Believe that this would tidy up my Data input Screen a lot.
2. A script that turns the Value in the Calculate FieldBox COLOR_RED if <= 100 , CORO_ORANGE if <= 300 and BLACK if > 301
I have had some success with this Script but Only if I enter data into that Field Box ! I would like it to Change Color when the result changes ( ie. Falls below a curtain Value
If any Body can help me with those I would greatly appreciate that.

I’m also looking for a Book that would Explain Approach Scripts as I can see a great improvement in databases, Can any body recommend some ?

Thanks Eduard
 
1) Your fieldbox has a "visible" property you can set to True or False. The bigger problem you will have is controlling when this on/off is done. You can run your script "on switch to" of the form, on recordchange of the DocWindow object (User pages forward/back), and on a change in the checkbox status. BUT, there is no event triggered if the user does a FIND and changes records that way. You would need to prevent a FIND from occurring outside of your control via macros or scripts and remove the FIND options from the menu (use a custom menu).

2) A calculated field value change does not trigger any event you can attach a script to. You would need to monitor the fields that feed into the calculated field value for changes perhaps. And like #1 above, trap other changes to update that field's color.

Sue Sloan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top