Spire.XLS is a professional Excel API that enables developers to create, manage, manipulate, convert and print Excel worksheets. Get free and professional technical support for Spire.XLS for .NET, Java, Android, C++, Python.

Mon Feb 04, 2019 11:48 am

Hello

I have an urgent issue with Spire XLS inside a console application (.NET 4.6.2)

Code: Select all
 var filename = "Triggers.xlsx";           

  Spire.License.LicenseProvider.SetLicenseKey("OUR KEY");

            var workbook = new Workbook
            {
                Version = ExcelVersion.Version2016
            };

            var sheet = workbook.Worksheets[0];
            sheet.Range["A1"].Text = "HELLO";
            workbook.SaveToFile(filename, ExcelVersion.Version2016);


Crashes with

'The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters’

This is being run under 64 bit with Spire 9.1.22

Whats the problem? I need this to be working reliably asap! This is really frustrating as its such a simple task I am giving it!

Cheers

Paul

paulsaxtonuk
 
Posts: 1
Joined: Tue Aug 15, 2017 5:09 pm

Tue Feb 05, 2019 5:10 am

Hi Paul,

Thanks for your inquiry.
The error is because you used wrong license key. You could comment out the code "Spire.License.LicenseProvider.SetLicenseKey("OUR KEY");" to check simply the result. Kindly note the correct license key is the value/string of the Key attribute of the element License of your license xml file. Please use correct key to remove the warning information.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy.jiang
 
Posts: 3099
Joined: Tue Sep 06, 2016 8:30 am

Return to Spire.XLS