protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            DataSet ds;
            if (Request.QueryString.ToString() != "")
            {
                DB = new dbMailBox(Request.QueryString["mail"]);
                ds = DB.GetContentByID(Request.QueryString["type"], Request.QueryString["id"]);
                if (ds.Tables[0].Rows.Count > 0)
                {
                    txtLpFrom.Text = ds.Tables[0].Rows[0]["vLpFrom"].ToString();
                    txtCapture.Text = ds.Tables[0].Rows[0]["dCapture"].ToString();
                    txtLpTo.Text = ds.Tables[0].Rows[0]["vLpTo"].ToString();
                    txtLpCc.Text = ds.Tables[0].Rows[0]["vLpCc"].ToString();
                    txtLogin.Text = ds.Tables[0].Rows[0]["vLogin"].ToString();
                    txtPwd.Text = ds.Tables[0].Rows[0]["vPwd"].ToString();
                    txtSrcMac.Text = ds.Tables[0].Rows[0]["vSrcMac"].ToString();
                    txtDstMac.Text = ds.Tables[0].Rows[0]["vDstMac"].ToString();
                    txtSrcAddr.Text = common.NumberToIP(ds.Tables[0].Rows[0]["vSrcAddr"]);
                    txtDstAddr.Text = common.NumberToIP(ds.Tables[0].Rows[0]["vDstAddr"]);
                    txtLpTitle.Text = ds.Tables[0].Rows[0]["vLpTitle"].ToString();
                    txtmapadd.Text = ds.Tables[0].Rows[0]["vLocalFile"].ToString();
                    strMailAddr = ds.Tables[0].Rows[0]["vLocalFile"].ToString();

                    tbBcc.Text = ds.Tables[0].Rows[0]["vLpBcc"].ToString();

                    emlFile = common.GetFileUrl(strMailAddr);

                    if (!string.IsNullOrEmpty(strMailAddr))//&& System.IO.File.Exists(strMailAddr)
                    {
                        emlFile = "../" + strMailAddr.Substring(strMailAddr.LastIndexOf('\\') + 1);
                    }
                    else
                    {
                        emlFile = string.Empty;
                    }

                    DB.SetReaded(Request.QueryString["type"], Request.QueryString["id"]);
                }
            }
        }
    }