예제 #1
0
        static void Main(string[] args)
        {
            // Instantiate the timer job class
            NoThreadingJob noThreadingJob = new NoThreadingJob();

            // The provided credentials need access to the site collections you want to use
            noThreadingJob.UseOffice365Authentication(User, Password);

            // In case of SharePoint on-premises use
            //noThreadingJob.UseNetworkCredentialsAuthentication(User, Password, Domain);

            // Add one or more sites to operate on
            noThreadingJob.AddSite("https://bertonline.sharepoint.com/sites/d*");

            // Print timer job information and then call Run() on the job
            PrintJobSettingsAndRunJob(noThreadingJob);
        }
예제 #2
0
파일: Program.cs 프로젝트: Calisto1980/PnP
        static void Main(string[] args)
        {
            // Instantiate the timer job class
            NoThreadingJob noThreadingJob = new NoThreadingJob();
            
            // The provided credentials need access to the site collections you want to use
            noThreadingJob.UseOffice365Authentication(User, Password);

            // In case of SharePoint on-premises use
            //noThreadingJob.UseNetworkCredentialsAuthentication(User, Password, Domain);

            // Add one or more sites to operate on
            noThreadingJob.AddSite("https://bertonline.sharepoint.com/sites/d*");

            // Print timer job information and then call Run() on the job
            PrintJobSettingsAndRunJob(noThreadingJob);
        }