Exemplo n.º 1
0
        public void Page_Load(object sender, EventArgs e)
        {
            // int input;

              /* Label1.Text = Convert.ToString(GlobalClass.Sel_ind);
            Label2.Text = GlobalClass.U_n ;
            Label3.Text = GlobalClass.P_w ;*/

               try
            {
               Microsoft.Crm.Sdk.Samples.ServerConnection run = new Microsoft.Crm.Sdk.Samples.ServerConnection();
               Microsoft.Crm.Sdk.Samples.ServerConnection.Configuration con= run.Gettest(GlobalClass.U_n, GlobalClass.P_w, GlobalClass.Sel_ind);
                orgname.Text = con.OrganizationName;

            }
            catch (System.TimeoutException ex)
            {
                Label1.Text = "The application  terminated with an error.";
                Label2.Text = ex.Message;
            }
            catch (System.Exception ex)
            {
                Label1.Text = "The application  terminated with an error.";
                Label2.Text = ex.Message;

            }
        }
Exemplo n.º 2
0
        public void Page_Load(object sender, EventArgs e)
        {
            String user=(String)Session["username"];
            String pass=(String)Session["password"];
            int a=(int)Session["selection"];
               Microsoft.Crm.Sdk.Samples.ServerConnection run = new Microsoft.Crm.Sdk.Samples.ServerConnection();

               GlobalClass.s_conf = run.Gettest(user,pass,a);
               orgname.Text =(String)Session["orgname"];
        }