-- background: 12137 from stack: in -- bmap block id: 12883 -- flags: 0000 -- background id: 0 -- name: Requests Off ----- HyperTalk script ----- on openBackground -- menu set up global menu1 put NewMenu ("Options","Delete this Card", "New SchedulER Card","Next Card/8", "Prior Card/9","Clear All Buttons", "Clear Data Field","(-","Set Days On","Scheduler", "(-","Find An Employees Card" ) into menu1 if menu1 is 0 then answer ("Unable to make menu "Beep") with "Drat" end openBackground on closebackground global menu1 put deleteMenu(menu1) into menu1 end closebackground on idle -- personal menu setup global menu1,lastTick if (the ticks-lasttick)> 120 then put the ticks into lastTick showMenu(menu1) end if pass idle end idle on doMenu which global menu1 if which is "New SchedulER Card" then send "mouseUp" to bkgnd button "New SchedulER Card" -- my version of new card else if which is "Delete this Card" then send "mouseUp" to bkgnd button "DeleteCard" else if which is "Next Card" then send "mouseUp" to bkgnd button "Next Card" else if which is "Prior Card" then send "mouseUp" to bkgnd button "Prior Card" else if which is "Clear All Buttons" then send "mouseUp" to bkgnd button "Clear buttons" else if which is "Select Whole Days Off" then send "mouseUp" to bkgnd button "Select Whole Days" else if which is "Clear Data Field" then put "" into field "Data" else if which is "set days On" then closebackground go to first card of bkgnd "Requests On" else if which is "Scheduler" then closebackground pop card else if which is "Find An Employees Card" then Ask "Which Employee's Card are you Looking for" find it in field "Name" else pass doMenu end doMenu -- part 1 (field) -- low flags: 00 -- high flags: 4000 -- rect: left=45 top=69 right=87 bottom=164 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 21 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Name -- part 144 (field) -- low flags: 01 -- high flags: 4000 -- rect: left=157 top=257 right=272 bottom=250 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 10 -- style flags: 0 -- line height: 13 -- part name: Shiftlimit1 -- part 145 (field) -- low flags: 01 -- high flags: 4000 -- rect: left=158 top=277 right=292 bottom=252 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 10 -- style flags: 0 -- line height: 13 -- part name: ShiftLimit2 -- part 183 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=258 top=51 right=66 bottom=274 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 184 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=274 top=51 right=66 bottom=290 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 185 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=290 top=51 right=66 bottom=306 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 186 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=306 top=51 right=66 bottom=322 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 187 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=322 top=51 right=66 bottom=338 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 188 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=338 top=51 right=66 bottom=354 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 189 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=354 top=51 right=66 bottom=370 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 190 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=258 top=85 right=100 bottom=274 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 191 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=274 top=85 right=100 bottom=290 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 192 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=290 top=85 right=100 bottom=306 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 193 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=306 top=85 right=100 bottom=322 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 194 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=322 top=85 right=100 bottom=338 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 195 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=338 top=85 right=100 bottom=354 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 196 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=354 top=85 right=100 bottom=370 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 197 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=257 top=116 right=131 bottom=273 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 198 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=273 top=116 right=131 bottom=289 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 199 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=289 top=116 right=131 bottom=305 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 200 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=305 top=116 right=131 bottom=321 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 201 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=321 top=116 right=131 bottom=337 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 202 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=337 top=116 right=131 bottom=353 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 203 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=353 top=116 right=131 bottom=369 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 204 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=256 top=145 right=160 bottom=272 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 205 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=272 top=145 right=160 bottom=288 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 206 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=288 top=145 right=160 bottom=304 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 207 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=304 top=145 right=160 bottom=320 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 208 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=320 top=145 right=160 bottom=336 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 209 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=336 top=145 right=160 bottom=352 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 210 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=352 top=145 right=160 bottom=368 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 211 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=258 top=177 right=192 bottom=274 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 212 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=274 top=177 right=192 bottom=290 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 214 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=290 top=177 right=192 bottom=306 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 215 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=204 top=85 right=100 bottom=220 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 216 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=204 top=106 right=121 bottom=220 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 217 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=204 top=126 right=141 bottom=220 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 218 (button) -- low flags: 00 -- high flags: 2005 -- rect: left=204 top=147 right=162 bottom=220 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: -- part 219 (button) -- low flags: 00 -- high flags: 2006 -- rect: left=443 top=73 right=88 bottom=459 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Select Days ----- HyperTalk script ----- on mouseUp set cursor to 4 put "" into day put "" into shiftflag put "A B C D" into shifts put "False" into set repeat with i = 32 to 35 if hilite of bkgnd button i = "True" -- is one of them set? then put "true" into set end repeat if set = "False" then answer "You have to set one of the shift buttons" exit mouseUp end if repeat with i = 1 to 31 if hilite of bkgnd button i = "True" then repeat with shift = 32 to 35 if hilite of bkgnd button shift = "True" then put " " & i & (word (shift - 31) of shifts) after day end if end repeat end if end repeat repeat with shift = 1 to 35 set hilite of bkgnd button shift to "False" end repeat put " " & day after bkgnd field "Data" set hilite of bkgnd button "Select Days" to "False" end mouseUp -- part 220 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=411 top=0 right=16 bottom=511 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: New SchedulER Card ----- HyperTalk script ----- on mouseUp doMenu "Copy Card" doMenu "Paste Card" put "Blank" into field Name end mouseUp -- part 221 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=433 top=113 right=142 bottom=469 -- title width / last selected line: 0 -- icon id / first selected line: 22308 / 22308 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Next Card ----- HyperTalk script ----- on mouseUp get id of card put id of last card of background "requests off" into lastcard if it = lastcard then go to first card of background "requests off" else visual effect wipe right go to next card of bkgnd "Requests off" end if end mouseUp -- part 222 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=104 top=0 right=16 bottom=203 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Select Whole Days -- part 223 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=194 top=0 right=16 bottom=274 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: DeleteCard ----- HyperTalk script ----- on mouseUp set lockscreen to true get id of card put it into cardID put id of first card of bkgnd "requests off" into firstcard put id of last card of bkgnd "requests off" into lastcard if cardID = firstcard and cardID = lastcard then answer "Can't Delete the last card" else answer "Are You Sure" with "Yes" or "No" if it = "yes" then domenu "delete card" if cardID = lastcard then go to First card of bkgnd "Requests Off" end if set lockscreen to false end mouseUp -- part 224 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=434 top=161 right=191 bottom=469 -- title width / last selected line: 0 -- icon id / first selected line: 19381 / 19381 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Prior Card ----- HyperTalk script ----- on mouseUp get id of card put id of first card of background "requests off" into firstcard if it = firstcard then visual effect wipe left go to last card of background "requests off" else visual effect wipe left go to previous card of bkgnd "requests off" end if end mouseUp -- part 225 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=20 top=0 right=14 bottom=101 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Clear Buttons ----- HyperTalk script ----- on mouseUp repeat with i = 1 to 35 set hilite of bkgnd button i to "False" end repeat end mouseUp -- part 228 (field) -- low flags: 01 -- high flags: 4007 -- rect: left=4 top=156 right=193 bottom=184 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 21 -- text size: 10 -- style flags: 0 -- line height: 13 -- part name: Data -- part 229 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=273 top=222 right=252 bottom=294 -- title width / last selected line: 0 -- icon id / first selected line: 16692 / 16692 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: shiftanumup ----- HyperTalk script ----- on mouseUp get field shiftindicatorA if it = "A" then put 1 into num else if it = "B" then put 2 into num else if it = "C" then put 3 into num else if it = "D" then put 4 into num end if get word num of field shiftlimit1 if it >= 31 then put 0 into it put 1 + it into it put it into word num of field shiftlimit1 end mouseUp -- part 230 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=297 top=246 right=261 bottom=313 -- title width / last selected line: 0 -- icon id / first selected line: 16560 / 16560 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: New Button ----- HyperTalk script ----- on mouseUp Get field shiftindicatorA if it = "A" then put "B" into it else if it = "B" then put "C" into it else if it = "C" then put "D" into it else if it = "D" then put "A" into it end if put it into field shiftindicatorA end mouseUp -- part 231 (field) -- low flags: 01 -- high flags: 0000 -- rect: left=295 top=225 right=242 bottom=312 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 14 -- style flags: 256 -- line height: 18 -- part name: ShiftindicatorA -- part 233 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=315 top=222 right=252 bottom=336 -- title width / last selected line: 0 -- icon id / first selected line: 3584 / 3584 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: shiftanumup ----- HyperTalk script ----- on mouseUp get field shiftindicatorA if it = "A" then put 1 into num else if it = "B" then put 2 into num else if it = "C" then put 3 into num else if it = "D" then put 4 into num end if get word num of field shiftlimit1 if it <= 0 then put 31 into it put it - 1 into it put it into word num of field shiftlimit1 end mouseUp -- part 234 (field) -- low flags: 01 -- high flags: 0000 -- rect: left=295 top=268 right=285 bottom=312 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 14 -- style flags: 256 -- line height: 18 -- part name: Shiftindicatorb -- part 235 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=273 top=265 right=295 bottom=294 -- title width / last selected line: 0 -- icon id / first selected line: 16692 / 16692 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: shiftanumup ----- HyperTalk script ----- on mouseUp get field shiftindicatorb if it = "A" then put 1 into num else if it = "B" then put 2 into num else if it = "C" then put 3 into num else if it = "D" then put 4 into num end if get word num of field shiftlimit2 if it >= 31 then put 0 into it put 1 + it into it put it into word num of field shiftlimit2 end mouseUp -- part 236 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=317 top=265 right=295 bottom=338 -- title width / last selected line: 0 -- icon id / first selected line: 3584 / 3584 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: shiftanumup ----- HyperTalk script ----- on mouseUp get field shiftindicatorb if it = "A" then put 1 into num else if it = "B" then put 2 into num else if it = "C" then put 3 into num else if it = "D" then put 4 into num end if get word num of field shiftlimit2 if it < 0 then put 31 into it put it - 1 into it put it into word num of field shiftlimit2 end mouseUp -- part 237 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=296 top=295 right=310 bottom=312 -- title width / last selected line: 0 -- icon id / first selected line: 16560 / 16560 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: New Button ----- HyperTalk script ----- on mouseUp Get field shiftindicatorb if it = "A" then put "B" into it else if it = "B" then put "C" into it else if it = "C" then put "D" into it else if it = "D" then put "A" into it end if put it into field shiftindicatorb end mouseUp