Ruby Console - Setting the UTC in ShadowInfo class


#1

Hi I’m new to coding in ruby console and I’ve been experimenting around with the ShadowInfo class.

I’ve been able to change the time and date with the code below:

t = Time.local(2015, 11, 01, 14)
Sketchup.active_model.shadow_info[“ShadowTime”] = t

However, I’m also looking to set the UTC to -5:00.

Thank you


#2
Sketchup.active_model.shadow_info["TZOffset"] = -5.0

this one?

Sketchup.active_model.shadow_info.to_a

will give you the full list


#3

Great thank you, that’s what I needed.