Quantcast
Viewing all articles
Browse latest Browse all 3726

Stop Sleep / Screen Dim Mac

Hello, it possible to call a code to stop the mac from sleeping within a window (ie a checkbox value), but more specifically, will this stop the screen from dimming? And then another code to return the back to original state (undo it).

I’ve seen this thread below: And tried both methods (MBS / Caffeinate). I’ve got it compile, and asked chatgpt for advice, but it doesn’t seem to work. Apple website seems to suggest that caffeinate will stop screen dimming. Is it because I am trying to alter states within the app? and not on app.openening?

It’s difficult to debug this at my end, because I am having to compile on windows and then transfer to my mac to run (my macos too old to run XOJO). So if anybody could explain to like I am five how this could be achieved, I would be grateful.

6 posts - 5 participants

Read full topic


Viewing all articles
Browse latest Browse all 3726

Trending Articles