_Sunlight commands cannot be run from within macros by suppressing the dialog using
_-Sunlight, if this would be possible it might be doable to change the sun position using a simple macro combination, then use
_CloseRenderWindow etc. ( @andy do you see this ? )
However, Rhino has got a built in Animation toolbar offering the commands
_SetSeasonalSunAnimation which may be usable to change the sun location for sun studies. I´m not shure but if the capture method is set to “RenderFull” and Flamingo is the current Render plugin, it might run.
Apart from this the RDK (included in Rhino 5) does have a scripting object which may be used to control the sun position if you´re familiar with vbScript.