예제 #1
0
파일: provider.cs 프로젝트: gpanayir/sffwk
        void SetProvider()
        {

            lblConnectionType.Text = Provider.ProviderType.ToString();
            txtAddres.Text = Provider.SourceInfo;
            txtApplicationId.Text = Provider.ApplicationId;
            cnnstring.Clear();
            if (Provider.ProviderType == ServiceProviderType.xml)
            {
                cnnstring.Visible = false;
                lblAddress.Text = "File :";
                btnView.Visible = true;
            }
            if (Provider.ProviderType == ServiceProviderType.sqldatabase)
            {
                btnView.Visible = false;
                lblAddress.Text = "Connection string";
                if (System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo] != null)
                {
                    Fwk.DataBase.CnnString c = new Fwk.DataBase.CnnString(Provider.SourceInfo, System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo].ConnectionString);
                    cnnstring.Populate(c);
                    cnnstring.Visible = true;
                }

            }
        }
예제 #2
0
파일: provider.cs 프로젝트: gpanayir/sffwk
        void SetProvider()
        {

            lblConnectionType.Text = Provider.ConfigProviderType.ToString();
            txtConfigName.Text = Provider.BaseConfigFile;
        
            cnnstring.Clear();
            if (Provider.ConfigProviderType == ConfigProviderType.local)
            {
                cnnstring.Visible = false;
                lblAddress.Text = "File :";
         
            }
            if (Provider.ConfigProviderType == ConfigProviderType.sqldatabase)
            {
               
                lblAddress.Text = "Connection string";
                if (System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo] != null)
                {
                    Fwk.DataBase.CnnString c = new Fwk.DataBase.CnnString(Provider.SourceInfo, System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo].ConnectionString);
                    cnnstring.Populate(c);
                    cnnstring.Visible = true;
                }

            }
        }
예제 #3
0
        void SetProvider()
        {
            lblConnectionType.Text = Provider.ConfigProviderType.ToString();
            txtConfigName.Text     = Provider.BaseConfigFile;

            cnnstring.Clear();
            if (Provider.ConfigProviderType == ConfigProviderType.local)
            {
                cnnstring.Visible = false;
                lblAddress.Text   = "File :";
            }
            if (Provider.ConfigProviderType == ConfigProviderType.sqldatabase)
            {
                lblAddress.Text = "Connection string";
                if (System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo] != null)
                {
                    Fwk.DataBase.CnnString c = new Fwk.DataBase.CnnString(Provider.SourceInfo, System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo].ConnectionString);
                    cnnstring.Populate(c);
                    cnnstring.Visible = true;
                }
            }
        }
예제 #4
0
 void SetProvider()
 {
     lblConnectionType.Text = Provider.ProviderType.ToString();
     txtAddres.Text         = Provider.SourceInfo;
     txtApplicationId.Text  = Provider.ApplicationId;
     cnnstring.Clear();
     if (Provider.ProviderType == ServiceProviderType.xml)
     {
         cnnstring.Visible = false;
         lblAddress.Text   = "File :";
         btnView.Visible   = true;
     }
     if (Provider.ProviderType == ServiceProviderType.sqldatabase)
     {
         btnView.Visible = false;
         lblAddress.Text = "Connection string";
         if (System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo] != null)
         {
             Fwk.DataBase.CnnString c = new Fwk.DataBase.CnnString(Provider.SourceInfo, System.Configuration.ConfigurationManager.ConnectionStrings[Provider.SourceInfo].ConnectionString);
             cnnstring.Populate(c);
             cnnstring.Visible = true;
         }
     }
 }
예제 #5
0
 public void Populate(Fwk.DataBase.CnnString pCnnString)
 {
     txtDatabase.Text  = pCnnString.DataSource;
     txtSQLServer.Text = pCnnString.InitialCatalog;
 }