private void TestServiceForm_Load(object sender, EventArgs e)
        {
            string siteURL = Path.Combine(MainForm.CurrentProject.DevSite.AccessPoint, this.ContractName, this.PackageName + "." + this.ServiceName);
            txtSiteURL.Text = MainForm.CurrentProject.DevSite.AccessPoint;
            txtContract.Text = this.ContractName;
            txtService.Text = this.ServiceFullName;
            _sttForm = new SecurityTokenForm(this.ContractName, this.ContractUniqName);

            try
            {
                string dir = Path.Combine(Environment.CurrentDirectory, "TestServiceConfig");
                if (!Directory.Exists(dir))
                    Directory.CreateDirectory(dir);

                string filename = Path.Combine(dir, this.ServiceUniqName);
                if (File.Exists(filename))
                {
                    XmlDocument doc = new XmlDocument();
                    doc.Load(filename);
                    txtRequest.Text = doc.DocumentElement.OuterXml;
                    txtRequest.FormatXml();
                }
            }
            catch { }
            txtRequest.UserKeyUp += new KeyEventHandler(txtRequest_UserKeyUp);
        }
Exemplo n.º 2
0
        private void TestServiceForm_Load(object sender, EventArgs e)
        {
            string siteURL = Path.Combine(MainForm.CurrentProject.DevSite.AccessPoint, this.ContractName, this.PackageName + "." + this.ServiceName);

            txtSiteURL.Text  = MainForm.CurrentProject.DevSite.AccessPoint;
            txtContract.Text = this.ContractName;
            txtService.Text  = this.ServiceFullName;
            _sttForm         = new SecurityTokenForm(this.ContractName, this.ContractUniqName);

            try
            {
                string dir = Path.Combine(Environment.CurrentDirectory, "TestServiceConfig");
                if (!Directory.Exists(dir))
                {
                    Directory.CreateDirectory(dir);
                }

                string filename = Path.Combine(dir, this.ServiceUniqName);
                if (File.Exists(filename))
                {
                    XmlDocument doc = new XmlDocument();
                    doc.Load(filename);
                    txtRequest.Text = doc.DocumentElement.OuterXml;
                    txtRequest.FormatXml();
                }
            }
            catch { }
            txtRequest.UserKeyUp += new KeyEventHandler(txtRequest_UserKeyUp);
        }