Thanks for the reply Authenticity it helped me get on the right track. I have taken a sample script and modified it to suit my needs, one problem, I keep getting an error? This is what happens....
CODEDim $objApp
Dim $objNS
Dim $colFolders
Dim $objFolder
Dim $olAppointmentItem
$oFolder = _GetFolder ("Public Folders\All Public Folders\test")
Func _GetFolder($strFolderPath)
Dim $i
$arrFolders = StringSplit($strFolderPath, "\")
$objApp = ObjCreate("Outlook.Application")
$objNS = $objApp.GetNamespace("MAPI")
$objFolder = $objNS.CreateItem($olAppointmentItem)
$objFolder.Location = ""
$objFolder.Subject = "subject here"
$objFolder.Body = "text"
$objFolder.Start = "2/12/2009"
$objFolder.AllDayEvent = 1
$objFolder.Save
ConsoleWrite(ObjName($objFolder) & @CR)
If IsObj($objFolder) Then
For $i = 2 To $arrFolders[0]
$colFolders = $objFolder.Folders
$objFolder = $colFolders.Item($arrFolders[$i])
If Not IsObj($objFolder) Then
ExitLoop
EndIf
Next
EndIf
Return $objFolder
EndFunc
This is the error I cannot get around?
>Running:(3.2.2.0):C:\Program Files\AutoIt3\autoit3.exe "C:\Documents and Settings\anton.j\Desktop\auto it\temp1.au3"
C:\Documents and Settings\anton.j\Desktop\auto it\temp1.au3 (22) : ==> The requested action with this object has failed.:
$objFolder = $objNS.CreateItem($olAppointmentItem)
$objFolder = $objNS.CreateItem($olAppointmentItem)^ ERROR
What am i missing??? Any help would be great!
Thanks,
Anton