VaR hkey_root = "HKEY_CURRENT_USER"; var hkey_path = "\ Software \ Microsoft \ Internet Explorer \ pagesetup \"; var hkey_key; function printpage () {try {var regwsh = new activexobject ("wscript. shell "); hkey_key =" Header "regwsh. regwrite (hkey_root + hkey_path + hkey_key, "& W & B page number, & P/& P") hkey_key = "footer" regwsh. regwrite (hkey_root + hkey_path + hkey_key, "") // remove & U because I do not want to display the URL hkey_key = "margin_bottom"; regwsh. regwrite (hkey_root + hkey_path + hkey_key, "0.39"); // 0.39 is equivalent to setting the margin in the page settings to 10 hkey_key = "margin_left"; regwsh. regwrite (hkey_root + hkey_path + hkey_key, "0.39"); hkey_key = "margin_right"; regwsh. regwrite (hkey_root + hkey_path + hkey_key, "0.39"); hkey_key = "margin_top"; regwsh. regwrite (hkey_root + hkey_path + hkey_key, "0.39");} catch (e) {} var headstr = "<HTML>