Making an Analog Clock on an MS Access Form (Manipulating controls, no ActiveX) (1 Viewer)

ashleedawg

"Here for a good time"
Local time
Today, 12:20
Joined
Jun 22, 2017
Messages
154
Here's a simple analog clock I put together, to see if I could. Access doesn't make it easy to do anything "drawing-like" on forms so we have to get a little sneaky -- but this is drawn without ActiveX or API's.

There's one lil' API call to add the mandatory "Tick" sound... which isn't mandatory at all; it can be customized with other constants in the main module. So many things can be customized on a simple clock that I had to stop and "scale back" so as not to cloud the basic concepts here.

Additional notes on the way. Thoughts/questions invited! :rolleyes:
 

Attachments

  • Clock.zip
    58.4 KB · Views: 678

Minty

AWF VIP
Local time
Today, 19:20
Joined
Jul 26, 2013
Messages
10,355
That's neat, being slightly anal about clocks and watches I would like it to move the hour and minute hands proportionally, have a day date magnified window by the 3, a sweep second hand and have an Omega Seamaster logo on the face.

But apart from that it's really good. ;)
 

isladogs

MVP / VIP
Local time
Today, 19:20
Joined
Jan 14, 2017
Messages
18,186
That's neat, being slightly anal about clocks and watches I would like it to move the hour and minute hands proportionally, have a day date magnified window by the 3, a sweep second hand and have an Omega Seamaster logo on the face.

But apart from that it's really good. ;)

Ah you should see what Minty writes when he doesn't like something....:D

I would add my own detailed critique but I'm all outta time
Actually its so hypnotic it may even cure my insomnia

And for your next task ... a metronome
 

missinglinq

AWF VIP
Local time
Today, 15:20
Joined
Jun 20, 2003
Messages
6,423
...I would like it to move the hour and minute hands proportionally, have a day date magnified window by the 3, a sweep second hand and have an Omega Seamaster logo on the face...

Actually, I'd like to see that on my wrist...and did for a number of years! But times are hard, especially for the disabled/retired, and sadly, had to sell mine to finance Christmas, a few years ago!

Can't imagine why you'd want an analog clock on an Access Form...but this is a very clever piece of programing...especially in this environment!

Congrats!

Linq ;0)>
 

CJ_London

Super Moderator
Staff member
Local time
Today, 19:20
Joined
Feb 19, 2013
Messages
16,553
And for your next task ... a metronome
how about someone watching a metronome?
 

Attachments

  • MetronomeWatcher.zip
    22.7 KB · Views: 397

isladogs

MVP / VIP
Local time
Today, 19:20
Joined
Jan 14, 2017
Messages
18,186
Could you slow it down quite a bit please and re-post as someone watching paint dry...
 

missinglinq

AWF VIP
Local time
Today, 15:20
Joined
Jun 20, 2003
Messages
6,423
how about someone watching a metronome?
And, since you're into challenging coding...have Leroy Anderson's The Syncopated Clock playing in the background!:cool:

Could you slow it down quite a bit please and re-post as someone watching paint dry...

That's so boringgggggggggggggggg! :rolleyes: Now, watching ice melt, on a hot day...that's exciting! :D

Linq ;0)>
 

isladogs

MVP / VIP
Local time
Today, 19:20
Joined
Jan 14, 2017
Messages
18,186
As all I've done is make sarcastic comments so far, perhaps its time for me to contribute my own masterwork to this thread.

As I'm not good with graphics, the main feature in this case is a high quality embedded audio file of a well known work by John Cage.
The piece lasts just over 4 min 30 seconds and will stop automatically

For best results, keep the volume low & wear headphones/earphones

Hope you enjoy it!
 

Attachments

  • JC433.accdb
    532 KB · Views: 349
Last edited:

isladogs

MVP / VIP
Local time
Today, 19:20
Joined
Jan 14, 2017
Messages
18,186
I do find it very soporific. Especially if you listen to the whole piece[emoji39]


Sent from my iPhone using Tapatalk
 

CJ_London

Super Moderator
Staff member
Local time
Today, 19:20
Joined
Feb 19, 2013
Messages
16,553
perhaps slightly more practical but not good enough for production - Allow me to present - scrolling without scrollbars.
 

Attachments

  • NoScrollbarScroller.zip
    75.1 KB · Views: 304

isladogs

MVP / VIP
Local time
Today, 19:20
Joined
Jan 14, 2017
Messages
18,186
LOL

And mine's practically almost silent ... apart from CPU noises of course
 

MarkK

bit cruncher
Local time
Today, 12:20
Joined
Mar 17, 2004
Messages
8,178
This inspired me to try and do the same thing but completely calculate all the hand positions. I also mostly used an OOP approach, so all the heavy lifting is done using classes.

Given that the hand positions are calculated, the hands rescale and relocate if you resize the form.

Mark
 

Attachments

  • MyClock.zip
    55.6 KB · Views: 289

isladogs

MVP / VIP
Local time
Today, 19:20
Joined
Jan 14, 2017
Messages
18,186
Hi all

I just spotted this analog clock done in 2014 by raheelwaseem2004 in sample databases

https://www.access-programmers.co.uk/forums/showthread.php?t=258947



Well worth a look.
The code is amazingly concise.
 

Attachments

  • Capture.PNG
    Capture.PNG
    10.9 KB · Views: 733

ashleedawg

"Here for a good time"
Local time
Today, 12:20
Joined
Jun 22, 2017
Messages
154
just spotted this analog clock done in 2014 by raheelwaseem2004
2014? Bah, there were no such thing as analog clocks that long ago.

I invented it, okay? Pfft. "2014," he says...
 
Last edited:

Users who are viewing this thread

Top Bottom