![]() |
email notification changes
hopefully this is an easy question... i am looking for a way to automate turning sound & vibrate notifications for email on and off. does anyone know if there is a way to script that to make it easy? i don't mind a couple button presses, but having to dig into the settings every night is driving me nuts.
|
Re: email notification changes
Supposedly SPB Phone Suite can do that, but I have never tried it.
|
Re: email notification changes
spb Phone Suite will do it, but it is not free. You could also look into mortscript, which is free, though it will require you to do more work to get it to do what you want.
|
Re: email notification changes
mortscript seems to be exactly what's needed. thanks a lot. any idea what registry key controls notifications?
|
Re: email notification changes
If nobody knows / replies to you, the way I look for reg changes is to set the notifications to one state, export the registry using Resco Registry, then switch the notifications and export again (to a different filename). Then I transfer the .reg files to the desktop and do a comparison with pspad. You only need to export HKCU and HKLM (saves a lot of time), generally speaking.
Here's a sample mortscript I tried building to switch from normal to silent mode: Code:
Choice( "Profile","Select Profile","Normal","Silent") |
Re: email notification changes
|
Re: email notification changes
Thanks Codearn, but I was actually trying to help *you* by posting a sample mortscript that offers a choice and then makes reg edits based on that choice. I figured you could modify it to meet your needs once you figured out the values you needed to change based on your original post. :)
|
Re: email notification changes
actually i did start from it. havent finished yet but i dont see a reason why it shouldnt work. thanks again.
|
Re: email notification changes
If you are interested I've got a mortscript scheduler that you can use to run mortscripts on a schedule you specify.
|
Re: email notification changes
Quote:
|
Re: email notification changes
I'll post it tonight when I get home.
|
Re: email notification changes
Here's the scheduler script. It must be put in the \Windows\Startup folder. It uses the windows mobile notification queue so it does not impact battery life outside of the small amount of processing power to run this script when the event is scheduled to run. Change the events listed in the events array so it runs your script on the schedule you desire.
## Scheduled Events array: ## -The eventID (quoted in brackets []) format is d,hh,mm where... ## d is day of week (0=Sunday, 6=Saturday) ## hh is hour of day (00 to 23) ## mm is minute of hour (00-59) ## -The action (quoted to the right of the equal sign) is "full_path_of_script,parameter", parameters are option schedule["1,08:00"] = "\program files\mortscript\scripts\setvolume.mscr,03" schedule["1,17:00"] = "\program files\mortscript\scripts\setvolume.mscr,12" schedule["2,08:00"] = "\program files\mortscript\scripts\setvolume.mscr,03" schedule["2,17:00"] = "\program files\mortscript\scripts\setvolume.mscr,12" schedule["3,08:00"] = "\program files\mortscript\scripts\setvolume.mscr,03" schedule["3,17:00"] = "\program files\mortscript\scripts\setvolume.mscr,12" schedule["4,08:00"] = "\program files\mortscript\scripts\setvolume.mscr,03" schedule["4,17:00"] = "\program files\mortscript\scripts\setvolume.mscr,12" schedule["5,08:00"] = "\program files\mortscript\scripts\setvolume.mscr,03" schedule["5,17:00"] = "\program files\mortscript\scripts\setvolume.mscr,12" ## ## Initialize Variables and delete the logfile if it's greater than 10KB currTimestamp = Timestamp() currDayOfWeek = FormatTime("w", currTimestamp) currHour = FormatTime("H", currTimestamp) currMinute = FormatTime("i", currTimestamp) currSeconds = FormatTime("s", currTimestamp) startOfWeek = currTimestamp - (currDayOfWeek * 86400) - (currHour * 3600) - (currMinute * 60) - currSeconds script = SystemPath("ScriptPath") & "\" & SystemPath("ScriptName") & SystemPath("ScriptExt") logfile = SystemPath("ScriptExe") & "\scripts\schedulerLog.txt" If (FileSize(logfile) > 10240) Delete(logfile) EndIf WriteFile(logfile, "^NL^currTimestamp=" & currTimestamp & ",Day=" & currDayOfWeek & ",Time=" & currHour & ":" & currMinute & ":" & currSeconds & "^NL^", 1) ## ## Loop thru the scheduled events looking for the action to perform and the next event to schedule currEvent = null firstEventInSchedule = TRUE haventFoundNextEvent = TRUE ForEach event, action in array schedule eventDayOfWeek = Substr(event,1,1) eventHour = Substr(event,3,2) eventMinute = Substr(event,6,2) eventTimestamp = startOfWeek + (eventDayOfWeek * 86400) + (eventHour * 3600) + (eventMinute * 60) If (firstEventInSchedule) ## Initialize the "next event to be scheduled" to next weeks first event nextEvent = event nextEventTimestamp = eventTimestamp + 604800 firstEventInSchedule = FALSE EndIf If (haventFoundNextEvent) If (currTimestamp < eventTimestamp) ## We found the next event so save the event offset so it can be used to schedule the next event nextEvent = event nextEventTimestamp = eventTimestamp haventFoundNextEvent = FALSE WriteFile(logfile, "**Found Next event-->", 1) Else currEvent = event currEventTimeStamp = eventTimestamp EndIf EndIf WriteFile(logfile, "**Loop-event=" & event & ",eventTimestamp=" & eventTimestamp & ",Action= " & action & "^NL^", 1) EndForEach ## At end of loop If a current event wasn't found it means the "current event" is the last event from the prior week If (currEvent eq null) currEvent = event currEventTimeStamp = eventTimestamp - 604800 EndIf WriteFile(logfile, "Curr Event--ID=" & currEvent & ",Timestamp=" & currEventTimestamp & ",action=" & schedule[currEvent] & "^NL^", 1) WriteFile(logfile, "Next Event--ID=" & nextEvent & ",Timestamp=" & nextEventTimestamp & ",action=" & schedule[nextEvent] & "^NL^", 1) ## ## Remove notification queue entry that kicked off this run of the script then add an event to run this script for the next event RemoveNotifications (script) RunAt(nextEventTimestamp, script) ## ## Perform current scheduled action passing the timestamp of the current event as the last parameter scriptToRun = part( schedule[currEvent],",",1 ) scriptParm = part( schedule[currEvent],",",2 ) callscript( scriptToRun , currEventTimeStamp , scriptParm) |
| All times are GMT -4. The time now is 09:18 AM. |
Powered by vBulletin® ©2000 - 2026, Jelsoft Enterprises Ltd.
©2012 - PPCGeeks.com