VAGSuite.msiupdater.CheckForUpdates C# (CSharp) Метод

CheckForUpdates() публичный Метод

public CheckForUpdates ( string customer, string server, string username, string password, bool FromFile ) : void
customer string
server string
username string
password string
FromFile bool
Результат void
        public void CheckForUpdates(string customer, string server, string username, string password, bool FromFile)
        {
            m_server = server;
            m_customer = customer;
            m_username = username;
            m_password = password;
            m_fromFileLocation = FromFile;
            if (!m_blockauto_updates)
            {
                System.Threading.Thread t = new System.Threading.Thread(updatecheck);
                t.Start();
            }
        }

Usage Example

Пример #1
0
        private void frmMain_Shown(object sender, EventArgs e)
        {
            try
            {
                if (splash != null)
                    splash.Hide();
            }
            catch (Exception)
            {

            }
            try
            {
                if (m_appSettings.AutoLoadLastFile)
                {
                    if (m_appSettings.LastOpenedType == 0)
                    {
                        if (m_appSettings.Lastfilename != "")
                        {
                            if (File.Exists(m_appSettings.Lastfilename))
                            {
                                OpenFile(m_appSettings.Lastfilename, false);
                            }
                        }
                    }
                    else if (m_appSettings.Lastprojectname != "")
                    {
                        OpenProject(m_appSettings.Lastprojectname);
                    }
                }
                SetFilterMode();
            }
            catch (Exception)
            {

            }

            try
            {
                m_msiUpdater = new msiupdater(new Version(System.Windows.Forms.Application.ProductVersion));
                m_msiUpdater.Apppath = System.Windows.Forms.Application.UserAppDataPath;
                m_msiUpdater.onDataPump += new msiupdater.DataPump(m_msiUpdater_onDataPump);
                m_msiUpdater.onUpdateProgressChanged += new msiupdater.UpdateProgressChanged(m_msiUpdater_onUpdateProgressChanged);
                m_msiUpdater.CheckForUpdates("Global", "http://trionic.mobixs.eu/vagedcsuite/", "", "", false);
            }
            catch (Exception E)
            {
                Console.WriteLine(E.Message);
            }
        }