Home > Domino Tips > Developer > Agent > Archiving Lotus Notes documents to a specified folder
Domino Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

AGENT

Archiving Lotus Notes documents to a specified folder


Bob Gouin
12.05.2006
Rating: -3.15- (out of 5)


Lotus Notes, Domino, Workplace and WebSphere tips and advice
Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google


A common complaint about archiving Lotus Notes documents to specific folders is that there are too many steps involved. You have to select the document, move it to the specified folder, select the document again, and then finally select "archive" or "drag/drop."

To address this issue, I've created an agent that reduces the number of steps required to archive Lotus Notes documents to specified folders. This agent allows the end user to archive directly to a folder in their Lotus Notes archive database.

The Lotus Notes agent prompts the end user for the folder they'd like to archive, moves the document to the specified folder, and then archives the selected Lotus Notes documents to the archive database -- while maintaining the documents in the specified folder.

The agent saves Lotus Notes users a few steps, and makes archiving Lotus Notes documents a little easier.

You can name the agent: ArchiveSelected Documents To Folders | agent_archiveToFolder.

 Option Public
Option Declare
Use "Common"


Sub Initialize
On Error Goto Trap 
Dim s As New notessession
Dim uiws As New notesuiworkspace 
Dim db As notesdatabase
Dim coll As notesdocumentcollection
Dim StringTable As New mailtoolsstringtable   
 
'get a handle on the current database
Set db = s.currentdatabase
 
'get a handle on the selected documents to archive
Set coll = db.unprocesseddocuments
 
'prompt for users input, verify to archive
If YesNoPrompt(StringTable.GetString
(TOOL_STRING+76,coll.count),
StringTable.GetString(TOOL_STRING+75,Null)) Then 
  
Archive:   
'move the collection of documents to the folder 
Call uiws.folder(, False)
  
'archive the documents
Call db.ArchiveNow(coll)  
  
'refresh the view
Call uiws.Viewrefresh()
  
End If 'prompt for users input, verify to archive   
 
Exit Sub
 
Trap:
'edit archive settings
If YesNoPrompt(Error$ & Chr(10) & 
StringTable.GetString(TOOL_STRING+74,Null),
StringTable.GetString(TOOL_STRING+75,Null)) Then
If uiws.Currentdatabase.Editarchivesettings() Then
Resume Archive
Else
End
End If
End If 
 
End Sub

Do you have comments on this tip? Let us know.

Related information from SearchDomino.com:

  • Tip: Monitoring scheduled agents by email
  • Tip: Techniques for writing agents
  • Tip: A Lotus Notes approval reminder agent
  • Tip: Changing a Lotus Notes database mail file from 'archive' to 'mail'
  • Reference Center: Agent tips and resources

    This tip was submitted to the SearchDomino.com tip library by member Bob Gouin. Please let others know how useful it is via the rating scale below. Do you have a useful Lotus Notes, Domino, Workplace or WebSphere tip or code snippet to share? Submit it to our monthly tip contest and you could win a prize.

    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    Add to Google


    RELATED CONTENT
    Lotus Notes Domino Archiving
    Avoid Lotus Notes Domino email archiving ACL issues with AdminP
    E-discovery rules double-edged sword for CIOs
    IM, blogs next target for litigation
    Symantec peddles enterprise vault tool
    Changing a Lotus Notes database mail file from 'archive' to 'mail'
    Email archiving for SMBs: No experience required
    School district hooks up affordable compliance archive
    Exporting email from Lotus Notes to .EML messages
    Email archiving: What's right for your enterprise?
    Email archiving: Should storage pros keep everything?

    Lotus Notes Domino Agents
    Open documents in Lotus Notes from the Web without a UNID
    Fix and update Lotus Notes documents with limited access
    Verify scheduled agent status with Domino Extensible Language (DXL)
    Top 10 Lotus Notes Domino programming and development tips of 2007
    How to export data from a Lotus Notes database to a CSV file
    Must-know Lotus Notes Domino agents -- 10 tips in 10 minutes
    Enable or disable scheduled agents without opening the Lotus Notes database design
    Creating custom views in Lotus Notes databases
    Editing fields in a Lotus Notes view with Ajax
    Troubleshooting a scheduled agent not running on a Global Notes Architecture (GNA) server

    Agent
    Open documents in Lotus Notes from the Web without a UNID
    Fix and update Lotus Notes documents with limited access
    Verify scheduled agent status with Domino Extensible Language (DXL)
    How to export data from a Lotus Notes database to a CSV file
    Enable or disable scheduled agents without opening the Lotus Notes database design
    Creating custom views in Lotus Notes databases
    Editing fields in a Lotus Notes view with Ajax
    How to automatically create a backup copy of your Domino Directory
    Export Lotus Notes documents to Microsoft Word via Internet Explorer
    A bevy of Notes/Domino development tips

    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 enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

    TechTarget Corporate Web Site  |  Media Kits  |  Reprints  |  Site Map




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