﻿function ShowMsgDlg(text,btnText){
	try{
	var Outer = document.createElement("DIV");
	Outer.style.position = "absolute";
	Outer.style.top = "220px";
	Outer.style.left = "300px";
	Outer.style.width = "300px";
	Outer.style.height = "150px";
	Outer.style.border = "1px solid #8080FF";
	Outer.style.backgroundColor = "#FFF";
	var Inner = document.createElement("DIV");
	Inner.style.margin = "3px";
	Inner.style.height = "144px";
	Inner.style.border = "1px solid #8080FF";
	Outer.appendChild(Inner);
	var MsgInner = document.createElement("DIV");
	MsgInner.style.margin = "3px";
	MsgInner.style.height = "112px";
	MsgInner.style.textAlign = "center";
	MsgInner.appendChild(document.createTextNode(text));
	Inner.appendChild(MsgInner);
	var hr = document.createElement("DIV");
	hr.style.fontSize = "0px";
	hr.style.height = "2px";
	hr.style.borderTop = "1px solid #8080FF";
	hr.style.borderBottom = "1px solid #8080FF";
	//hr.style.backgroundColor = "#EAEAF4";
	Inner.appendChild(hr);
	var close = document.createElement("DIV");
	if(undefined == btnText) btnText = "Close";
	close.appendChild(document.createTextNode(btnText));
	close.style.height = "24px";
	close.style.lineHeight = "24px";
	close.style.textAlign = "center";
	close.style.marginTop = "3px";
	close.style.marginBottom = "3px";
	close.style.marginLeft = "118px";
	close.style.border = "1px solid #8080C0";
	close.style.width = "60px";
	close.style.backgroundColor = "#CCCCFF";
	close.style.cursor = "default";
	close.onmouseover = function(){
		this.style.backgroundColor = "#8080C0";
		this.style.color = "#FFF";
	}
	close.onmouseout = function(){
		this.style.backgroundColor = "#CCCCFF";
		this.style.color = "#000";
	}
	close.onclick = function(){
		Outer.parentNode.removeChild(Outer);
	}
	Inner.appendChild(close);
	document.getElementById("message_show").appendChild(Outer);
	}catch(e){
		alert(e.message);
	}
}