Anleitung
Securely hide formulas
The main goal of Excel file copy protection is to remove formulas from cells to make them unavailable to anyone. If the formulas are not really secured protected then anyone who get permission to launch your model, (even if it was protected with password, license key and/or with hardware locking), may copy all data and formulas (manually or using some Excel Add-In) into another unprotected workbook and use your model without any restrictions.
The DoneEx XCell Compiler compiles all formulas from xls into binary format and remove them from the cells of xls. For now a days this method is the most secure. Even encoding with strong encryption algorithm is not so secure because you should provide decrypt key for user and since this moment your data are decrypted and available for anybody.
-
To check if there are any available formulas in any compiled EXE you can switch Excel in "Formula Auditing Mode". To do this please follow "Main Excel menu" >> "Tools" >> "Formula Auditing" >> "Formula Auditing Mode"
-
To check that formulas are not available from VBA code you can use the following equation in VBA Sheets("sheet name from your workbook").Range("address of cell with formula").formula. The secured formulas protection is available for any type of DoneEx XCell Compiler licenses . To protect your formulas you just need to compile your xls with DoneEx XCell Compiler. Please see how to compile your model.
Compile Excel File
Creating an application from XCell Compiler.
Once you install the XCell Compiler on your PC do the following steps.
-
Go to Start menu
-
Click Programs-->DoneEx-->XCell Compiler-->Click to Start.
-
The following screen will appear.

-
Please have a look on content of cell E10, you can see the formula.
-
Select DoneEx--> Excel Compiler-->Compile from the Excel menu bar.
The following dialog form will appear.
-
Lets enter the application name as 'Sample'
-
Put the version number 1 0 2 as shown in the above image
-
Enter the copyright text in the copyright box.
-
Click the browse button
to choose the target path. Select C drive and give the file name as 'sample.exe'.
-
Click the browse button
for screen image. Select the image.
-
Click the compile button in the XCell Compiler screen. Once the compilation completed, the following message will be displayed.
-
Click OK on the compilation message screen.
-
Click the close button on the XCell Compiler screen.
-
Close Excel.
-
Browse "My Computer". Go to C drive. To use the compiled file, just double click the compiled file icon (sample.exe file).
-
The file will be opened in Microsoft Excel environment . If you select the cone volume (E10) cell, you cannot see the formula in the sample exe file.
-
Now change the 'Radius' to 5 and 'Height' to 7 then press enter. The cone volume is calculated but you cannot see the formula. This formula cannot be reached as from grid as from VBA code.
-
Once the Excel worksheet is compiled, a file in the EXE format will be saved at the specified target path.
-
The file is secured now; you can send the compiled file to your client in a peace of mind.
Use Registration Tool
Registration/License Management
XCell Compiler offers very easy and hassle free excel file copy protection. You don't need to have programming experience to accomplish professional copy protection of your excel file. XCell Compiler is royalty free! With only a single copy of the software you can protect unlimited number of your excel files with no additional investments. You don't need any additional hardware like dongles or hardware keys.
You can achieve following features when you use 'Registration/Licensing' facility of XCell Compiler.
-
Hardware locking! Lock your excel application to target computer.
-
Excel application copy protection, illegal copying from one computer to another.
-
Simple and effective protection procedure, no need for additional programming.
-
Protect excel application from reverse engineering and analyzing.
-
Evaluation (trial) version feature, Easily create demo version of your excel application, with date limitations.
-
Limited license feature, rent or lease your excel application by setting the license expiration period.
-
License extension feature, your client can now easily extend his limited license before it expires.
Registration Example
Let's take an example, how to achieve the registration and hardware locking process.
-
Go to Start menu
-
Click Programs-->DoneEx-->XCell Compiler-->Click to Start.
-
It will open the sample.xls file. Compile the sample file with the 'Apply Registration Key (License) to EXE' and 'Hardware locking' checked as shown below.
-
If the "Apply registration key (license) to EXE" is checked 'on' then the "Limit application usage period" is inaccessible. The date limit can be set during regkey generation (see below).
-
Compile the application 'sample'. After compilation it should create a smaple.exe file in C:\ drive.
-
Let us assume you or your customer ran the sample.exe file. A message will appear like the image below.
-
Go to excel menu 'DoneEx->XCell Compiler->Registration Key Tool' .
The menu will open a dialog like below.
-
Browse to the C:\Sample.exe for 'Path to compiled Exe'.
-
Put customer name and customer email address on the boxes.
-
Now the most important information is the computer id, please copy/type the computer id.
-
You can put also the date restriction on the registration file by choosing the 'Limit application usage period'.
-
When you will click the 'Create RegKey', it will create 'sample.rkey' in the same directory.
-
You can send sample.rkey to your customer, so that the sample.exe will run only in his computer.
This way you can protect your excel application from illegal copying from one computer to another.
Protect with Matrix Dongle
-
Download the DoneEx XCell Compiler.
-
Extract and install the DoneEx XCell Compiler (30 days free trial version). After that Excel has the new menu item - DoneEx
-
Compile the XLS file, the result is a MS Excel file in the EXE format.
-
Download the Matrix Mx-Crypt tool.
-
Extract and install the Mx-Crypt tools. You can copy these tools to a memory stick or any data storage.
-
Start Mx-Crypt, load the Excel-EXE-file and click the "crypt" button - encrypt the EXE, linked with the Matrix dongle. Since you don't have a dongle, this is the only test.
-
Now you need the USB License Dongles. Matrix recommends the type MLU-60.
Here is the Matrix price list. For any license you need one dongle.
You can make your own customized license arrangement in consideration of all future possibilities and updates. With the protection of secret operational data or the prevention of the unauthorized data manipulation you receive the higher level of protection.
It is possible to link many files to one dongle license.
You can set up to 79 additional 10-digit keys in a dongle memory.
Your license allows to copy the protected spreadsheets to various computers but only the computer with the dongle has a valid license.
The dongles work on any computer; just plug and play without software installation or drivers.
For both, XCell Compiler as well as Mx-Crypt, the free Trial versions are available.
The prices and more details are available on DoneEx and Mx-Crypt websites.
Create Trial EXE
You may create Trial version of your compiled EXE file with the trial period limited by amount of days you will set before compilation.

To create the Trial version of your compiled EXE you need to follow these steps:
-
"Copy protection with registration key" ON
-
Check "Hardware locking" ON, in case if you would like to have your EXE to be locked to client computer id number after the trial period expired.
-
Check "Trial version" ON
The following form appears:
-
Set the number of days for trial period.
-
Selecting value for delay time before 'Close' button appears on trial warning window.
-
By selecting the warning recall interval time, you will set the interval time between the latest trial warning window appearance and when it will appear again. In case if you select 0 minutes then the trial warning window will appear at start time only.
-
If you would like to customize the trial annoying warning content then you may set your own message by selecting the .TXT or .RTF file with content of your warning from disk into 'Custom warning content' field.
-
Press Compile button and you will get the compiled trial EXE
-
This EXE will work with the following trial version warning window (which will be shown every several minutes which you have selected in field 'Warning recall interval' of the'Trial Version Options' form), without the request of the user computer id until the trial period has expired. During the trial period the computer id can be found in Application Name About box
But when you are ready to distribute the Trial EXE, you should not start it after compilation, because EXE will fix the date of the first start as a start date of trial period.
The DoneEx XCell Compiler adds new parameter values for that function which returns correct values in compiled EXE only.
INFO("rmail") - returns #VALUE! in original xls, #N/A in compiled EXE which works in trial mode and returns registered e-mail if EXE is registered with registration key file.
INFO("compid") - returns #VALUE! in original xls, computer id number of current computer where compiled EXE is started.
This new INFO function's parameters let you distinguish compiled/uncompiled and registered/trial version of your mode.
for example:
=IF(ISERROR(INFO("rname")),IF(ISNA(INFO("rname")),"Trial mode","Uncompiled model info"),IF(INFO("rname")="admin","Admin Info", "Customer info"))
A cell, where this equation will be entered, returns "Uncompiled model" for original xls, "Trial mode" for compiled EXE in trial mode, "Admin info" for registered user with name "admin" and "Customer Info" for all other registered users.
Hide Excel on start
"Hide Excel on start" is a special feature to beautify the end user interface and allows to make Excel grid invisible. This interface should be coded by VBA. Hide Excel on start" does not affect on protection rate of compiled EXE application.
Please download the following two examples to find out how the "Hide Excel on start" feature works.
http://www.doneex.com/downloads/samplevba_he.exe
SampleVBA_he.exe file was compiled with "Hide Excel" option "ON"
http://www.doneex.com/downloads/samplevba.exe
SampleVBA.exe file was compiled with "Hide Excel" option "OFF"
Original SampleVBA.xls file you may find in the DoneEx XCell Compiler installation folder.
If you take a look at the example you will see that it contains the custom form. In case of using 'Hide Excel' this form will be used instead of the original Excel interface.
Export/Import Changed Data
The Export/Import of changed data is allowed if the EXE application was compiled with "Allow Export/Import" option on.
For example, when the compiled application 'Sample.exe' runs, the following menu appears on Excel.
Please note that the 'Export Data' item is grayed. It will be activated as soon as any data will be changed on spreadsheet because the option allows to export changed data only.
-
Export Data : By clicking the 'Export Data' menu, the windows standard save dialog will appear, type a file name in order to export. The export file will be in binary format with .dat extension. The file contains only the data, which are different from the original application data.
For EXE application the export option works for changed data only. If you want to export non-changed data just make copy-cut and paste exactly at same place for such data.
-
Import Data: By clicking the 'Import Data' menu, the following dialog will appear.
Select the file you want to import for your application, it will import the values into cells, if you would like to see the imported values in different back ground or font color, you may choose the colors before importing.
If you would like to import data into original xls file then go to the Excel main menu ->DoneEx ->XCell Compiler -> Load external data
Please note that data in cells, where the imported data come, will be rewritten.
If you would like to import data into EXE application then please go Excel main menu ->DoneEx ->Application name ->Import Data.
The following warning appears in case if you made export data from EXE with one control sum inside and import data into EXE with another control sum..
The control sum calculates from all formulas of xls during compilation.
If you change even one symbol in any formula of your xls model then the control sum after compilation will be changed. In another words the Compiler detects that the data were taken from one workbook and are trying to be imported into another workbook.
Dim mainCmdBar As CommandBar
Dim dnx As CommandBarPopup
Dim appBtn As CommandBarPopup
Dim loadBtn As CommandBarControl
Set dnx = mainCmdBar.FindControl(, ,"DoneEx_MainMenu_Item_Tag")
If Not dnx Is Nothing Then
For i = 1 To dnx.Controls.Count
If dnx.Controls.Item(i).Tag ="DoneEx_Package_Submenu" Then
Set appBtn = dnx.Controls.Item(i)
Exit For
End If
Next
If Not appBtn Is Nothing Then
Set loadBtn = appBtn.Controls.Item(2)
If Not loadBtn Is Nothing Then
loadBtn.Execute 'load data
End If
End If
End If
End Sub
Private Sub Export_Click()
Dim mainCmdBar As CommandBar
Dim dnx As CommandBarPopup
Dim appBtn As CommandBarPopup
Dim expBtn As CommandBarControl
Set mainCmdBar =Application.CommandBars.Item("Worksheet Menu Bar")
Set dnx = mainCmdBar.FindControl(, ,"DoneEx_MainMenu_Item_Tag")
If Not dnx Is Nothing Then
For i = 1 To dnx.Controls.Count
If dnx.Controls.Item(i).Tag ="DoneEx_Package_Submenu" Then
Set appBtn = dnx.Controls.Item(i)
Exit For
End If
Next
Set expBtn = appBtn.Controls.Item(1)
If Not expBtn Is Nothing Then
If expBtn.Enabled Then
expBtn.Execute 'save data
End If
End If
End If
End If
End Sub
Use Advanced Protection
"Advanced protection" option works the same way as Excel's workbook/worksheets data protection and repeats the Excel way of protection you may set in original xls file by using 'Main Excel menu' -> 'Tools' -> 'Protection'
"Advanced protection" does not affect XCell Compiler algorithms (as cells formulas and VBA code) protection, because formulas are always protected after compilation and vba code is protected by using "Protect VBA" option.
"Advanced protection" option allows to protect data on your worksheet from accidental changes by customers.
For compilation XCell Compiler requires the workbook and all worksheets to be unprotected and after that sets the same protection options in "Advanced protection" form as you use in your original xls.
If you set the "Advanced protection" option ON then the compiled EXE will behave exactly the same way as your original xls with worksheets/workbook protection.
In case if you have VBA code in your model then, before applying "Advanced protection" option, you have to check the compatibility of your model with this option. For that purpose you need to set workbook/worksheets protection in original xls (exactly the same options you are going to use in "Advanced protection" form for compilation and for the same worksheets) and test your xls with this protected mode. If your original xls works as expected with workbook/worksheets protection then you need to unprotect workbook and all worksheets (even hidden) and compile it with the XCell Compiler. Otherwise you need to adjust your original xls model to let it work correctly with workbook/worksheets protection.
If your VBA code uses Workbook.Protect/Unprotect or Worksheet.Protect/Unprotect commands then make sure that you use one password in all cases of usage of these commands, and enter this password into "Custom password" field on "Advanced protection" form before compilation.
-
Protect structure:To protect the structure of a workbook so that worksheets in the workbook can't be moved, deleted, hidden, unhidden, or renamed and new worksheets can't be inserted, select the 'Protect structure' check box.
-
Protect windows: If you want to lock size and position of the windows, then select the 'Protect windows' check box.
-
Protect drawing objects: To prevent making changes to any drawing objects, select this option.
-
Protect content: To prevent making changes of the content, select the 'Protect content' check box.
-
Protect scenarios: To prevent making changes to your scenarios, select the 'Protect scenarios' check box.
-
Protect user interface only: To prevent making changes on user interface, select this option.
-
Allow to select locked cells: To allow selection the locked cells, use this option. By this option ON the user will be able to select the locked cells content.
-
Allow to select unlocked cells: To allow selection the unlocked cells, use this option. By this option ON the user will be able to select the unlocked cells content.
-
Allow to format cells: To allow format of the cells, use this option. By this option the user will be able to do formatting cells.
-
Allow filtering: To allow filtering of the cell or row contents, use this option.
-
Use custom password: You can enter your password for protection otherwise by default XCell Compiler will create random password for you.











