Page 1 of 2 1 2 LastLast
Results 1 to 10 of 17

Thread: Save attachments from GroupWise

  1. #1

    Save attachments from GroupWise



    Register for a FREE account, and/
    or Log in to avoid these ads!

    I am a trying to save .doc and .docx files from a folder in GroupWise to a network folder. We are running GroupWise 8.0.3 with the latest patches. The article here: showthread.php?510-Article-Extract-Novell-Groupwise-Attachments-And-Save-To-A-Directory&highlight=GroupWise (sorry, would not let me post the link) explains how to do it. I also saw a couple of threads that talk about it, but guess I am missing part of the puzzle.

    I only changed this:
    Code:
    'Change required variables here!
    sLoginName = "ajannson"
    sFolderToSearch = "Census"
    sSavePath = "C:\Share\DOCS\Census\mail" 'do not add trailing \ sFileType = "docx"
    Here is what I get:
    C:\Download>attach.wsf
    Microsoft (R) Windows Script Host Version 5.7 Copyright (C) Microsoft Corporation. All rights reserved.
    C:\Download\attach.wsf(70, 2) Windows Script Host: Unterminated entity reference
    - matching ';' not found

    I did not change anything else in the script. I did run it from the local HD on the PC.
    I am not sure what you are using for a VB editor.
    I have not checked to see the Groupware Type Library checked.

    Can someone shed some light on how to set this up, where to run it and etc...
    TNX Will

  2. #2
    Administrator Ken Puls's Avatar
    Join Date
    Mar 2011
    Location
    Nanaimo, BC, Canada
    Posts
    2,251
    Articles
    57
    Blog Entries
    14
    Excel Version
    Excel Office 365 Insider
    Hi Will,

    Do you really have the sFileType = "docx" at the end of the line? I beleive it should be:
    Code:
    'Change required variables here!
    sLoginName = "ajannson"
    sFolderToSearch = "Census"
    sSavePath = "C:\Share\DOCS\Census\mail" 'do not add trailing \ 
    sFileType = "docx"
    Ken Puls, FCPA, FCMA, MS MVP (Excel)

    Learn to Master Your Data at the Power Query Academy (the world's most comprehensive online Power Query training) or with my book M is for Data Monkey!

    Main Site: http://www.excelguru.ca -||- Blog: http://www.excelguru.ca/blog -||- Forums: http://www.excelguru.ca/forums
    Check out the Excelguru Facebook Fan Page -||- Follow Me on Twitter

    If you've been given VBA code (a macro) for your solution, but don't know where to put it, CLICK HERE.

  3. #3
    it is actually correct...
    Windows didn't paste correctly:
    'Change required variables here!
    sLoginName = "ajannson"
    sFolderToSearch = "Census"
    sSavePath = "C:\Share\DOCS\Census\mail" 'do not add trailing \
    sFileType = "docx"

  4. #4
    From a differnt PC, I get this information:
    Script: C:\Download\attach.vbs
    Line: 2
    Char: 16
    Error: Expected end of etatement
    Code: 800A0401
    Source: Microsoft VBScript compilation error

    Will

  5. #5
    Administrator Ken Puls's Avatar
    Join Date
    Mar 2011
    Location
    Nanaimo, BC, Canada
    Posts
    2,251
    Articles
    57
    Blog Entries
    14
    Excel Version
    Excel Office 365 Insider
    Hmm... vbscript... okay that's different then.

    Can you post the first 10 lines of the code?
    Ken Puls, FCPA, FCMA, MS MVP (Excel)

    Learn to Master Your Data at the Power Query Academy (the world's most comprehensive online Power Query training) or with my book M is for Data Monkey!

    Main Site: http://www.excelguru.ca -||- Blog: http://www.excelguru.ca/blog -||- Forums: http://www.excelguru.ca/forums
    Check out the Excelguru Facebook Fan Page -||- Follow Me on Twitter

    If you've been given VBA code (a macro) for your solution, but don't know where to put it, CLICK HERE.

  6. #6
    Here you go :-)

    Option Explicit
    Private ogwApp As GroupwareTypeLibrary.Application
    Private ogwRootAcct As GroupwareTypeLibrary.Account
    Sub Groupwise_SaveAttachToFile()
    'Author : Ken Puls
    'Macro Purpose: Save all attachments of specified file type into a
    'user specified folder using Groupwise
    'NOTE: Reference to Groupware Type Libary required
    Dim ogwFolder As Folder, _
    ogwFoundFolder As Folder, _
    i As Long, _
    sCommandOptions As String, _
    sMailPassword As String, _
    sLoginName As String, _
    sFolderToSearch As String, _
    sFileType As String, _
    sSavePath As String, _
    ogwMail As Mail
    'Change required variables here!
    sLoginName = "ajannson"
    sFolderToSearch = "Census"
    sSavePath = "C:\Download\ajansson" 'do not add trailing \
    sFileType = "docx"
    'Set application object reference if needed
    If ogwApp Is Nothing Then 'Need to set object reference
    DoEvents
    Set ogwApp = CreateObject("NovellGroupWareSession")
    DoEvents
    End If

  7. #7
    Administrator Ken Puls's Avatar
    Join Date
    Mar 2011
    Location
    Nanaimo, BC, Canada
    Posts
    2,251
    Articles
    57
    Blog Entries
    14
    Excel Version
    Excel Office 365 Insider
    Yuck. Okay, here's the deal...

    The code you've got is meant to be early bound in order to run. vbscript doesn't do that. It's going to need conversion to late binding to run.

    I don't have time to do that right today, but I'll see if I can get to it tomorrow.
    Ken Puls, FCPA, FCMA, MS MVP (Excel)

    Learn to Master Your Data at the Power Query Academy (the world's most comprehensive online Power Query training) or with my book M is for Data Monkey!

    Main Site: http://www.excelguru.ca -||- Blog: http://www.excelguru.ca/blog -||- Forums: http://www.excelguru.ca/forums
    Check out the Excelguru Facebook Fan Page -||- Follow Me on Twitter

    If you've been given VBA code (a macro) for your solution, but don't know where to put it, CLICK HERE.

  8. #8
    Any help would be great! I have a user with over 1000 email messages with attachments in just one folder!! She is leaving service soon!

    TNX Will

  9. #9
    Administrator Ken Puls's Avatar
    Join Date
    Mar 2011
    Location
    Nanaimo, BC, Canada
    Posts
    2,251
    Articles
    57
    Blog Entries
    14
    Excel Version
    Excel Office 365 Insider
    Hi Will,

    See if you can follow this through: http://www.xldynamic.com/source/xld.EarlyLate.html

    That's what needs to be done. If you can give it a go, I can try and tweak and help out if you run into snags. Sorry, it's just that I'm crazy busy right at the moment!
    Ken Puls, FCPA, FCMA, MS MVP (Excel)

    Learn to Master Your Data at the Power Query Academy (the world's most comprehensive online Power Query training) or with my book M is for Data Monkey!

    Main Site: http://www.excelguru.ca -||- Blog: http://www.excelguru.ca/blog -||- Forums: http://www.excelguru.ca/forums
    Check out the Excelguru Facebook Fan Page -||- Follow Me on Twitter

    If you've been given VBA code (a macro) for your solution, but don't know where to put it, CLICK HERE.

  10. #10
    It is over my head, but will look at it...

Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •