Jonesy's Babble

"Don't touch that please, your primitive intellect wouldn't understand things with alloys and compositions and things with... molecular structures." Ash, Army of Darkness

Alan Lepofsky
Andrew Pollack
Bruce Elgort
Chris Linfoot
Chris Whisonant
Curt Stone
Ed Brill
Jake Howlett
Joe Litton
Julian Robichaux
Mac Guidera
Paul Mooney
Phil Randolph
Philip Storry
Richard Schwartz
Rocky Oliver
Wild Bill Buchan
Toolbar button for editing fields. (SnTT)
Thursday, April 20, 2006
I've had this in draft mode since the 2nd week of Show-n-Tell Thursday's and finally got around to posting it. It's some Formula Script code that allows me to change any field of a document if I have editor access to it quickly and without too many prompts. I have the code behing a custom button in my Editing toolbar so it's always available to me. Chad Schelfhout (thanks for the correction Chris!) had posted something similar with a lot more features/power that you should check out as well. Here are the prompts you get - and the screenshots are from an email doc.

That just made the email to be like the sender had requested a return receipt. So you can notify someone over and over that you read their email with little hassle on your part if you want to have some harmless fun.
Just put this in the code for a button and you're set!

List := @DocFields;
DataTypes := "Text" : "Date" : "Number" ;
EditField := @Prompt( [OkCancelList] ;
"Select a field to alter" ; "Select the field you wish to alter:" ; "CustomerReply" ; List ) ;

Edit := @Prompt( [YesNo] ; "Confirm" ;
"Are you sure you want to alter the current contents of field \"" + EditField + "\"." );

RawValue := @If( Edit = 1 ; @Prompt( [OkCancelEdit] ;
"New Value" ; "Please enter the new desired value." ; NULL ) ;
@Return(NULL) );

DataType := @Prompt( [OkCancelList] ; "Data Type" ;
"Please Select the correct DataType" ; "Text" ; DataTypes );

@If( DataType = "Date" ; @SetField( EditField ;
@TextToTime( RawValue )) ; DataType = "Number" ;
@SetField( EditField ; @TextToNumber( RawValue )) ;
@SetField( EditField ; RawValue ) );
posted by David Jones @ 9:30 AM  
Post a Comment
<< Home
About Me

Name: David Jones
Home: Murfreesboro, Tennessee, United States
About Me:
See my complete profile
Previous Post
- "The Wikipedia FAQK"
- The Yanks make me sad
- Cuba beats the Dominican Republic to go to the Fin...
- WBC: Mexico 2, USA 1
- WBC: Mexico vs United States (take 2!)
- WBC: Mexico vs United States
- World Baseball Classic
- Quiz: Which sci-fi crew would you best fit in?
- Google Tech Talks
- Pulling data from a DB2 database using LSX (Show-n...
Taking Notes Podcast
The Morning News
TMN - The Non-Expert
Google News
Lotus Notes Wikipedia
Template by

Free Blogger Templates