I ran across an interesting little trick in some code I’m working on today. As usual, not my code, someone else’s that I’m trying to decipher and fix.
You can use the g_strDateTimeControlIDs array like this:
var eventDateID = g_strDateTimeControlIDs["SPEventDate"]; document.getElementById(eventDateID).value = date;
Note the ‘SP’ ahead of the column name.