if(typeof(Utilities) == "undefined"){
	var Utilities = {};
}

if(typeof(Utilities.Window) == "undefined"){
	Utilities.Window = {};
}

Utilities.Window.Open = function(url, width, height, name, top, left, scroll, status, resizable, menubar){  
	if(!status) status = 0;
	if(!scroll) scroll = 'no';
	var sName = Math.round(Math.random() * 999999999);	
	if(!name) name = 'WinOpen'+ sName.toString();
	if(!width) width = '600';
	if(!height) height = '450';
	if(!resizable) resizable = 'no';
	if(!menubar) menubar = 'no';
	if(!top) top = (screen.height-height)/2 - 40;
	if(!left) left = (screen.width-width)/2;
	properties='history=no, toolbar=0, location=0, directories=0, scrollbars='+scroll+', status='+status+', menubar='+menubar+', width='+width+', height='+height+', top='+top+', left='+left+', resizable='+resizable+'';	
	var sLocation = new String(window.location);	
	
	window.open(url, name, properties);
}

Utilities.Window.SetAttribute = function(Name, Value){
	if(typeof(Window) != "undefined"){
		eval("Window.prototype." + Name +" = " + Value + ";");
	}else{
		eval("window." + Name +" = " + Value + ";");
	}
}
