GlideDateTime is not an available object in client scripts. You would be better served using GlideAjax to do the processing on the server in this case.



Episodes 5, 6, and 33 of TechNow talk about client scripting and GlideAjax.



Docs: Client Scripts


Docs: GlideForm


Docs: GlideAjax  


Developer: Client Scripting Technical Best Practices Overview


TechNow Episode List