Should this script work right out of the box
Or do I have to modufy it
I tried running it and I get an werror
Line:           1
Char:           31
Error:  Expected statement
Code:           800A0400

--------------------------------
Rob Weatherly
--------------------------------

-----Original Message-----
From: Crumbaker, Ron [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 03, 2003 10:17 AM
To: NT 2000 Discussions
Subject: RE: Outlook 2002 cmd line switches

Can you use VBScripting?

Function GetMail(strCriteria) As Object
    ' This procedure returns all MailItem objects in
    ' the Inbox that match the criteria specified in
    ' the strCriteria argument.
    Dim fldMail     As Outlook.MAPIFolder
    Dim colItems    As Outlook.Items
    
    ' Use the InitializeOutlook procedure to initialize global
    ' Application and NameSpace object variables, if necessary.
    If golApp Is Nothing Then
        If InitializeOutlook = False Then
            MsgBox "Unable to initialize Outlook Application " _
                & "or NameSpace object variables!"
            Exit Function
        End If
    End If
    
    Set fldMail = gnspNameSpace.GetDefaultFolder(olFolderInbox)
    Set colItems = fldMail.Items.Restrict(strCriteria)
    
    If colItems.Count = 0 Then
        Set GetMail = Nothing
    Else
        Set GetMail = colItems
    End If
End Function

Thank you,
 
Ron Crumbaker, MCP


-----Original Message-----
From: Malcolm Reitz [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 03, 2003 9:11 AM
To: NT 2000 Discussions
Subject: RE: Outlook 2002 cmd line switches


The available command line switches are listed in the Outlook Help file
and here: http://support.microsoft.com/?kbid=296192

I don't see anything that tells Outlook to do a send/receive.


Malcolm

-----Original Message-----
From: Weatherly, Rob [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 03, 2003 8:03 AM
To: NT 2000 Discussions
Subject: Outlook 2002 cmd line switches

Does any one know if there is a command line switch of third party tool
for outlook that I could use, to invoke outlook and cause it to perform
a full Send/Receive.

I know you can set outlook to perform a send/receive every time it opens
but that would cause negative effects.




--------------------------------
Rob Weatherly
--------------------------------


------
You are subscribed as [EMAIL PROTECTED]
Archives: http://www.swynk.com/sitesearch/search.asp
To unsubscribe send a blank email to %%email.unsub%%

------
You are subscribed as [EMAIL PROTECTED]
Archives: http://www.swynk.com/sitesearch/search.asp
To unsubscribe send a blank email to %%email.unsub%%

------
You are subscribed as [EMAIL PROTECTED]
Archives: http://www.swynk.com/sitesearch/search.asp
To unsubscribe send a blank email to %%email.unsub%%

------
You are subscribed as [EMAIL PROTECTED]
Archives: http://www.swynk.com/sitesearch/search.asp
To unsubscribe send a blank email to [EMAIL PROTECTED]

Reply via email to