Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; By Frank Bauhn Comfort Hotel Stockholm
- #NoEnv
- #SingleInstance ignore
- SetTitleMatchMode, 2
- Gui, Add, Text, x6 y7 w360 h30 +Center, Choose An Option For Reservation Overview
- Gui, Add, Text, x6 y27 w360 h30 +Center, (Press F4 To Exit)
- Gui, Add, Radio, x126 y47 w100 h30 vAnswer1 Checked group, Advance Folio
- Gui, Add, Radio, x126 y87 w130 h30 vAnswer2, Close Further Postings
- Gui, Font, bold
- Gui, Add, Button, x66 y127 w240 h60 ,Go
- Gui, Font, normal
- Gui, Show, x375 y245 h197 w377, By Frank Comfort Hotel Stockholm v.1
- Return
- KillComment:
- IfWinExist, Cenium Comment Sheet
- {
- Send {Esc}
- }
- Return
- ButtonGo:
- SetTimer, KillComment, 100
- Gui, Submit, NoHide
- Gui, +OwnDialogs
- clipboard =
- Gui, Hide
- WinActivate, Microsoft Dynamics NAV Classic
- WinWaitActive, Microsoft Dynamics NAV Classic, , 2
- Send !-x
- Send ^{F12}{DOWN 5}
- WinWaitActive, Reservation Overview, , 2
- if ErrorLevel
- {
- SetTimer, KillComment, Off
- MsgBox, 48, Error, Can't Find Window Reservation Overview!
- Gui, Show
- return
- }
- Send ^a
- Sleep, 300
- Send ^c
- ClipWait, 3
- var := clipboard
- StringReplace, var, var, `n, `n, UseErrorLevel
- clipboard =
- Rounds = %ErrorLevel%
- Send ^{Home}
- if (Rounds = 0)
- {
- SetTimer, KillComment, Off
- MsgBox, 48, Error, Data Missing!
- Gui, Show
- return
- }
- if Answer1
- {
- Loop, %Rounds%
- {
- Progress,B fs18 zh0 w185 h50 Cblack,Done %A_Index% Of %Rounds%,,Arial
- Send ^{F11}
- WinWaitActive, Check Out - Folio
- Send !ua
- Send {Esc}
- WinWaitActive, Reservation Overview
- Send {DOWN}
- }
- Progress, Off
- MsgBox, 0, Folio Has Been Advanced, %Rounds% Reservations Done!
- ExitApp
- }
- else if Answer2
- {
- Loop, %Rounds%
- {
- Progress,B fs18 zh0 w185 h50 Cblack,Done %A_Index% Of %Rounds%,,Arial
- Send ^{F11}
- WinWaitActive, Check Out - Folio
- Send ^{up}{RIGHT 3}{UP 4}{Space}
- Send {Esc}
- WinWaitActive, Reservation Overview
- Send {Down}
- }
- Progress, Off
- MsgBox, 0, Closed Postings, %Rounds% Reservations Done!
- ExitApp
- }
- GuiClose:
- ExitApp
- F4::ExitApp
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement