//active 控件获取当前用户的桌面的路径的方法
var wsh = new ActiveXObject("wscript.shell"); listall(wsh.SpecialFolders("Desktop"));
function listall(imagePath){
// active 控件读取桌面指定名称图片的方法 var fso=new ActiveXObject("Scripting.FileSystemObject"); var file1 = fso.getFile(imagePath+'\\zp.bmp'); var src="<img src=\""+file1+"\"/>"; document.getElementById('certPicId').innerHTML = src; }