Home > Domino Tips > Administrator > Web > Avoid Save Conflicts Over the Web
Domino Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

WEB

Avoid Save Conflicts Over the Web


rajan babu
03.26.2001
Rating: -2.83- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


Here is a cool method of avoiding the save conflicts over the Web. It is basically comparing the time the document was brought on to the Web and the time the document was saved last; if both are same then no conflicts else there is a conflict and make the save options field to "0" so the document is not saved.



Code

Concept :- create a computed for display field named "Web_Modified" on the form with the default value as
"@If(@IsDocBeingSaved;Web_Modified;@ReplaceSubstring( @Text(@Modified) ; " " ; "_" ))

Add SaveOptions[Computed for display] field with default value as "1"

In the webquerysave run an agent which as the following.

set session = new NotesSession
Set db = session.currentdatabase
set thisdoc = session.documentcontext

If thisdoc.HasItem("Web_Modified") Then
If thisdoc.Web_Modified(0) <> "" Then
om = thisdoc.Web_Modified(0)
End If
End If

tmp = Evaluate( {@ReplaceSubString( @Text(@Modified) ; " " ; "_" )} , thisdoc )
nm = tmp(0)

If om = nm Then
" Continue , there is no save conflict ,
Else
"make saveOptions field to "0"
" give a alert box asking the user to resubmit the document

End If


Rate this Tip
To rate tips, you must be a member of SearchDomino.com.
Register now to start rating these tips. Log in if you are already a member.




Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   



RELATED CONTENT
Web
Display SharePoint data in a Lotus Notes Web application with Ajax
Top 10 Lotus Notes/Domino administration tips of 2008
How to create a dynamic SVG graph using a Lotus Notes agent
Hosting multiple Lotus Domino servers at one IP address without a VPN
Upgrading and patching Firefox: Security considerations for administrators
Admin2005 Learning Guides
Making old, new flavors of Domino SSO work
A fun site, with serious code
Creating corporate welcome pages with Lotus Notes
Domino Web traffic analyzers

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary

DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



Domino & Lotus Notes Security Solutions: Authentication, Antispam, Encryption and Antivirus
HomeTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersDomino IT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 1999 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts