Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 229
  • Last Modified:

Message Box

I am fairly new to Notes script, this is probably an easy question.

I have a button on the Notes toolbar that runs an archiving agent.  It has been requested of me that I create a message box when using the archive button that asks "Are you sure you want to archive the selected document(s)?"  With "Yes" or "No" as options.

How do I go about doing this?  Do I need a second agent to run the message box or can it run thru the same agent that archives the file to the nsf file?  Currently the button just runs a simple action sending the document to the nsf file.

Thanks for your help.
0
Pucktarget
Asked:
Pucktarget
1 Solution
 
HemanthaKumarCommented:
Create a different agent which basically gives user a choice with this formula

Result := @Prompt([YesNo]; "Archive ?"; "This action will remove this document from this database, Do you want to continue");
@if( Result="1"; @Command( [ToolsRunMacro] ; "agent" ) ; "")

~Hemanth
0
 
GwrCommented:
Hi
The LotusScript(VB) version would then be:

  ans = Msgbox("This action will remove this document from this database, Do
you want to continue", MB_YESNO + MB_ICONSTOP ,"App Notice")

  if ans = 6 then
    ..send your file here..
    .
    .
  end if

Gwr
0
 
PucktargetAuthor Commented:
Thanks for the help!!  I got it working.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now