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

Change ISP depending on time of day via AppleScript Internet
Some internet service providers offer cheap rates that are valid only for a certain time period of the day (eg. 6 pm to 8 am). Connect with this script to automatically choose the cheapest (predetermined) ISP:

-- choose the cheapest ISP 
--
-- example for www.arcor.de (March 2006)

set currhour to (hours of (current date))
if ((currhour > 8) and (currhour < 18)) then
  set tel to "01920782"
  display dialog "Good day!" buttons {"cancel"} giving up after 1
else
  set tel to "01920783"
  display dialog "Good night!" buttons {"cancel"} giving up after 1
end if

set string1 to "Dialing " & tel
display dialog string1 buttons {"cancel"} giving up after 2

tell application "Internet Connect"
  get properties of current configuration of application "Internet Connect"
  set usr to "arcor"
  set psw to "internet"
  connect current configuration to telephone number tel as user usr with password psw
end tell
 

[robg adds: I haven't tested this one...]
    •    
  • Currently 1.00 / 5
  • 1
  • 2
  • 3
  • 4
  • 5
  (1 vote cast)
 
[7,253 views]  

Change ISP depending on time of day via AppleScript | 0 comments | Create New Account
Click here to return to the 'Change ISP depending on time of day via AppleScript' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.