function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
E.J.RE.J.R 

The only time my code works is when developer console is open

This has been happening a lot recently. I write some code and it seems to work perfectly, but only when I have the developer console open. Below is a simple example of this happening again today:

I have a custom visualforce page that plots opportunities on the map, and color codes the map markers based on the driver's assigned color.

When I load the page with the developer console closed, the map markers don't get colored in:
Not working

To fix this, all I need to do is open the developer console, and voila, the colors show up:
Working

I assume this is some kind of coding issue, but I don't want to confuse things by posting sample code. My main interest is how this is even possible. What effect does the developer console have on the execution of code? Any info would be helpful and speculation is welcome.Thanks!