Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Publish a PC Outlook Calendar to .Mac' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Publish a PC Outlook Calendar to .Mac
Authored by: gboudrea on Dec 27, '04 10:02:28AM
Here's a modified AutoIT script which uses the keyboard shortcuts when possible (instead of mouse clicks) and doesn't require any other software than AutoIT 3.

;
; AutoIt Version: 3.0
; Language:       English
; Platform:       Win9x/NT
; Authors:        Phil Newman, Guillaume Boudreau
;
; Script Function:
;   Runs OutPort.
;

; Run OutPort
Run("Outport.exe")

; Wait for Outport to become active - it is titled "Outport"
WinWaitActive("Outport")

;MouseClicks are relative to window
AutoItSetOption("MouseCoordMode", 0)

;Select Calendar
Send("{DOWN}{DOWN}{SPACE}")

;Select Overwrite
MouseClick("left",204,279)

;Click Export
Send("!e")

;Allow access Outlook warning
AdlibEnable("allowAccess")

;Wait for export to complete
WinWaitClose("Exporting...","Cancel",120)

AdlibDisable()
;Close log warning, if any
AdlibEnable("closeWarning")

;Click Close
WinActivate("Outport")
Send("!{F4}")

AdlibDisable()

;Now to copy the file to .Mac

;Finished!
Exit

Func allowAccess()
    If WinExists("Microsoft Office Outlook","A program is trying to access") Then
	WinActivate("Microsoft Office Outlook","A program is trying to access")
	Send("{TAB}{TAB}{SPACE}")
	Send("{TAB}{DOWN}{DOWN}{DOWN}")
	Send("{TAB}{ENTER}")
    EndIf
EndFunc

Func closeWarning()
    If WinExists("Outport","There were messages logged while exporting the selected folder(s).") Then
	WinActivate("Outport","There were messages logged while exporting the selected folder(s).")
	Send("!n")
    EndIf
EndFunc


[ Reply to This | # ]