///<Summary>
 /// SetAsposeSlidesLicense method to Aspose.Words License
 ///</Summary>
 public static void SetAsposeSlidesLicense()
 {
     try
     {
         Aspose.Slides.License acLic = new Aspose.Slides.License();
         acLic.SetLicense(_licenseFileName);
     }
     catch (Exception ex)
     {
         Console.WriteLine(ex.Message);
     }
 }
Esempio n. 2
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            GlobalConfiguration.Configure(WebApiConfig.Register);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            BundleConfig.RegisterBundles(BundleTable.Bundles);

            //aspose license
            Aspose.Slides.License license = new Aspose.Slides.License();
            //Pass only the name of the license file embedded in the assembly
            license.SetLicense(@"Aspose.Slides.lic");
        }
Esempio n. 3
0
        public static void License()
        {
            string licensePath = System.AppDomain.CurrentDomain.SetupInformation.ApplicationBase + "\\Aspose.Total.lic";

            Aspose.Pdf.License pdf_license = new Aspose.Pdf.License();
            pdf_license.SetLicense(licensePath);

            Aspose.Words.License word_license = new Aspose.Words.License();
            word_license.SetLicense(licensePath);

            Aspose.Cells.License excel_license = new Aspose.Cells.License();
            excel_license.SetLicense(licensePath);

            Aspose.Slides.License ppt_license = new Aspose.Slides.License();
            ppt_license.SetLicense(licensePath);
        }
Esempio n. 4
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            BundleConfig.RegisterBundles(BundleTable.Bundles);
            ModelBinders.Binders.Add(typeof(DateTime), new CustomDateBinder());
            ModelBinders.Binders.Add(typeof(DateTime?), new NullableCustomDateBinder());

            Stream stream = new MemoryStream(StrToByteArray(Resources.Licence));

            stream.Position = 0;
            Aspose.Pdf.License     licensePdf     = new Aspose.Pdf.License();
            Aspose.Words.License   licenseWords   = new Aspose.Words.License();
            Aspose.Cells.License   licenseCells   = new Aspose.Cells.License();
            Aspose.Slides.License  licenseSlides  = new Aspose.Slides.License();
            Aspose.BarCode.License licenseBarCode = new Aspose.BarCode.License();

            licensePdf.SetLicense(stream);
            stream.Position = 0;
            licenseWords.SetLicense(stream);
            stream.Position = 0;
            licenseCells.SetLicense(stream);
            stream.Position = 0;
            licenseSlides.SetLicense(stream);
            stream.Position = 0;
            licenseBarCode.SetLicense(stream);
            stream.Close();
            //   CreateLogins();

            //	CheckLogins();

            LogHelper.InitLogger();
            LogHelper.Log.Info("Application Start");

            EmployePermissionHelper.Init();


            QScheduler.Start();
        }
 private static void LoadLicense(string ext)
 {
     switch (ext)
     {
         case ".PDF":
             var pdfLicense = new Aspose.Pdf.License();
             pdfLicense.SetLicense("Aspose.Total.lic");
             break;
         case ".DOC":
         case ".DOCX":
         case ".RTF":
             var docLicense = new Aspose.Words.License();
             docLicense.SetLicense("Aspose.Total.lic");
             break;
         case ".XLS":
         case ".XLSX":
         case ".CSV":
             var xlsLicense = new Aspose.Cells.License();
             xlsLicense.SetLicense("Aspose.Total.lic");
             break;
         case ".PPT":
         case ".PPTX":
             var pptLicense = new Aspose.Slides.License();
             pptLicense.SetLicense("Aspose.Total.lic");
             break;
         case ".VSD":
         case ".VSDX":
             var vsdLicense = new Aspose.Diagram.License();
             vsdLicense.SetLicense("Aspose.Total.lic");
             break;
         case ".MSG":
             var emaiLicense = new Aspose.Email.License();
             var msgPdfLicense = new Aspose.Words.License();
             emaiLicense.SetLicense("Aspose.Total.lic");
             msgPdfLicense.SetLicense("Aspose.Total.lic");
             break;
         default:
             var license = new Aspose.Words.License();
             license.SetLicense("Aspose.Total.lic");
             break;
     }
 }
Esempio n. 6
0
 ///<Summary>
 /// SetAsposeSlidesLicense method to Aspose.Slides License
 ///</Summary>
 public static void SetAsposeSlidesLicense()
 {
     Aspose.Slides.License acLic = new Aspose.Slides.License();
     acLic.SetLicense("Aspose.Total.lic");
 }