# Excel Alarm Clock



## MrIfOnly (Oct 20, 2017)

So, I made this alarm clock as mostly an exercise in VBA that turned into a nice little time-killer project for me.  I'm sharing it here for all who want it: 

https://www.4shared.com/file/K_f8zqvRei/Alarm_Clock.html

A few of its features:


dual alarm
adjustable snooze time
adjustable update time
set alarms as: buzzer (choose from any standard sound file), music library file, 'speak to me', or run macro.
multiple color schemes
dimmer
select font of your choice
full screen option
24 hour clock option
snooze button countdown

I am not (nor will I be in the future) asking for any money, but I would be very appreciative of any and all feedback, comments, suggestions, criticisms and feature requests.

Regards,

CJ


----------



## Rick Rothstein (Oct 20, 2017)

MrIfOnly said:


> So, I made this alarm clock as mostly an exercise in VBA that turned into a nice little time-killer project for me.  I'm sharing it here for all who want it:
> 
> https://www.4shared.com/file/K_f8zqvRei/Alarm_Clock.html
> 
> ...


I click the link you posted and could not figure out which Download button was the one for your file and which was part of an ad. Why don't you set up an account on DropBox and post your file there (it will be much clearer to figure out how to download it there)?


----------



## MrIfOnly (Oct 20, 2017)

I wasn't sure what you were talking about, Rick, until I turned off my ad-blocker.  It looks like every download button on that site redirects to an ad site.  I will upload this to Dropbox later tonight.

Thanks.

CJ


----------



## MrIfOnly (Oct 21, 2017)

Okay...here is the link to the Dropbox file:

https://www.dropbox.com/s/7qjrctr2hylucti/Alarm Clock.xlsm?dl=0

Please let me know if you have any problems with this link.

Regards,

CJ


----------



## MrIfOnly (Nov 13, 2017)

Well...not having heard any feedback on this yet, I'm not sure if anyone has tried it, but for those who have, I uploaded an updated version tonight.  The new version fixes a couple of minor cosmetic issues, allows the user to set the clock background as a gradient or picture (via the normal Excel toolbars), and turns off screen updating if the clock is not the active workbook.  This last change continues to check the time and alarms set, however, so still may cause conflicts with workbooks running macros utilizing a timer.


----------



## DHayes (Nov 17, 2017)

HI,
I attempted this but unfortunately it does not work in the 64 bit version.


----------



## MrIfOnly (Nov 18, 2017)

Thanks for the feedback.  Sorry to hear it didn't work.  Unfortunately, I don't have 64-bit version and I'm not sure exactly what would cause the issue between versions.  Perhaps someone here well versed in 64-bit programming could take a look at the code.


----------



## Scott T (Nov 18, 2017)

I downloaded it and it works but when I close the file it resizes Excel window. Running Office 365.


----------



## MrIfOnly (Nov 19, 2017)

Thanks for the feedback Scott.  I wasn't able to duplicate this but it doesn't entirely surprise me.  I tried my best to keep the clock centered and properly zoomed on the display, but was never really satisfied with the result.  I sort of settled for best result on the 3 computers that I tested it on.  I thought I covered resizing issues in the Workbook_BeforeClose event, but by your report, I wasn't successful.  Any thoughts/suggestions?

Regards,

CJ


----------



## guy999 (Nov 23, 2017)

Hi
Like the look and idea of this, but when i download and open after enable editing get this message.

Run time error 91
Object variable or with block variable not set

Any ideas how to fix, running 
Microsoft office prof plus 2010 , 32 bit


----------



## MrIfOnly (Nov 23, 2017)

Hi guy999:

Thanks for the feedback.

Try this:

From the ThisWorkbook module, click anywhere in the Workbook_Open sub, and then click run.  That should set the missing object variable.  Once this is done, save the workbook and try to reopen it. 

 If you have your macro security settings set to disable macros with notification, then enable macros and then click on 'Settings' on the clock, then click 'Save & Exit' or 'Cancel' from the settings menu.  This will also set the missing object variable.

Please report back on how it works.

Regards,

CJ


----------



## Logit (Nov 23, 2017)

.
Thank you MrIfOnly .

With your instruction I was able to get the clock running. However, the display flickers constantly when changing seconds. Attempted to use Application.ScreenUpdating = False in various sections of the macro code but to no avail.

Do you have any suggestions how to stop the flicker ?


----------



## MrIfOnly (Nov 23, 2017)

Hey Logit:

My display doesn't flicker, but the cursor does.  If that's what you mean, I couldn't get around this either.  However, I supplied the option to increase the amount of time between updates in the Settings menu.  Go to Settings and increase the Update Time and see if that helps.

Regards,

CJ


----------



## Logit (Nov 23, 2017)

I saw where changing the time to a higher sec. count will delay the flicker but ...

Here is a download link so you can see what the display is doing. Keep in mind, the actual flicker is alot faster than what is shown in the video but just as visually distracting.

https://www.amazon.com/clouddrive/share/agapEDwRtmHZv6vORkv6i1KAPfme6SAzbFlpFqd3oqg

Wonder is someone else has any ideas ?


----------



## MrIfOnly (Nov 23, 2017)

Wow...yeah, that's pretty bad.  I'm not sure why that is happening and I haven't seen that on any of the computers I tested on.

Thanks for posting this issue and sorry I don't have an immediate solution.


----------



## guy999 (Nov 24, 2017)

Thank you MrIfOnly
Got to work with macro settings, didn't need to open ThisWorkbook module.

Works fine now thanks, but yes my cursor does flicker when updating but not the whole screen.

Thanks for this


----------



## MrIfOnly (Nov 24, 2017)

You're welcome.  Thanks again for the feedback.

Regards,

CJ


----------



## mandukes (Dec 8, 2017)

MrIfOnly

Thank you so much for posting it, These projects are very helpful for understanding VBA programming to beginners as well as advance users.  I really liked your project keep up the good work. 

Thank you so much once again


----------



## MrIfOnly (Dec 9, 2017)

mandukes:

Thanks for the (much needed) ego boost!

Best regards,

CJ


----------

