Solved

Lotus Notes Formula

Posted on 2007-11-28
4
2,748 Views
Last Modified: 2013-11-16
Hi,
 I wonder why what's happening with this codes.. it's an old program. ( it allowed duplicate booking/clash time)

@If(ResourceType="1" & Capacity="";@Return(@Prompt([Ok];"Error";"You must enter the number of attendees before you can find a room."));ReserveDate="" | TimeRange=""; @Return(@Prompt([Ok];"Error";"You must enter a valid Date and/or Time before you can find an available resource."));ResourceCategory="";@Return(@Prompt([Ok];"Error";"You must choose a Resource Category. If one is not available, there may be no resources available for the selected site."));"");
@Command([ViewRefreshFields]);
@If((@Date(StartDateTime) < @Date(@Now)); @Return(@Prompt([Ok];"Error";"You cannot reserve a room for a date which has already occurred."));"");
Keyarg:="CN=*/"+@If(ResourceType="1";"O="+Site;"OU="+ResourceCategory+"/O="+Site);
ResNameCheck:=@If(ResourceType="1";@FindFreeResource(Keyarg;ResourceType;StartDateTime;EndDateTime;Capacity);@FindFreeResource(Keyarg;ResourceType;StartDateTime;EndDateTime));
@If(@IsError(ResNameCheck);@Return(@Prompt([Ok];"Error";"You received the following error when trying to find a resource: "+ResNameCheck));"");
FIELD ResourceName:=ResNameCheck;
FIELD ResourceName:=@If(ResourceName="";"No resource/room found for times and/or capacity requirements.";ResourceName);
@Command([ViewRefreshFields])

0
Comment
Question by:wzm
  • 3
4 Comments
 
LVL 31

Expert Comment

by:qwaletee
ID: 20377855
Is there a question somewhere in there?
0
 

Author Comment

by:wzm
ID: 20379332
somehow after upgrading to 6.5 this codes not working, is the sense that it allowed duplication, supposedly it reject same time booking.
0
 
LVL 31

Accepted Solution

by:
qwaletee earned 50 total points
ID: 20379434
I have no context. I don't know if this is a button, an agent, an action, or something else. I don't know you fields.

It looks like it is a customization to either a meeting form in a mail file, or a resource reservation database, EIther way, it doesn't prevent double-booking so much as it just checks for an existing freetime entry for a "range" of resources. If freetime is out of date or freetime booking is not set up correctly, it won't work. You can see whether it is booking free time correctly by doing a lookup for the specific room, and see if blocked ranges exactly match reserved times.

(I'm not 100% certain of this -- the operation of the freetime system in Notes is a black art, and resources and rooms within that is a blacker art. WHat I've said is based on what I've observed in Domino behavior in t he past.)
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 20906002
What was your finding?
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This is an old article, please see an updated version of this article, located here: http://www.experts-exchange.com/articles/23619/Notes-8-5x-Windows-7-Notes-info-and-tips.html
Article by: Rob
Notes 8.5 Archiving Steps and Tips This article covers setting up a Notes archive, and helps understand some of the menu choices making setting up and maintaining a Notes archive file easier.
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question