Contents - Index


Using Unicode Filenames and Paths


 

  

Beginning with VCLZip 4.50, VCLZip is able to store Unicode filenames and paths as well as use Unicode in archive filenames and paths.

 

There are 3 possibilites when compiling VCLZip depending on which Delphi/BCB compiler you are using and whether you want Unicode Support:

 

 

IMPORTANT: If you are using Delphi or BCB 2009 do not create the following conditional define.

 

In order to allow VCLZip to implement Unicode filenames, you must create a compiler define if you are using Delphi/BCB 6 through 2007...

 

When you install VCLZip 4.50 the following should already be done.  But to verify that it is done, open up the VCLZip package with the package editor.  In Project | Options, select the Directories/Conditionals tab and if it is not there already, type  IMPLEMENT_UNICODE into the conditionals text box and save.

 

In order to implement Unicode, VCLZip uses WideStrings wherever filenames and paths are used.  Defining IMPLEMENT_UNICODE will cause VCLZip to compile all such strings as WideStrings and cause WideString functions to be called instead of the normal Ansii String functions.  When IMPLEMENT_UNICODE is not defined, VCLZip is compiled as it always was in earlier versions using regular Ansii strings and functions.  

 

When compiling under Delphi/BCB 2009, regular strings are defined as UnicodeStrings.  Your application will require few if any changes to work with VCLZip 4.5.  The one change you will have to make is anywhere that the Password property is used (including event declarations) you will have to use an AnsiString.  The Password cannot be a UnicodeString.   

 

VERY IMPORTANT

 

 

            http://www.tmssoftware.com/site/tmsuni.asp

 

The VCLZip Zip Utility Example uses TMS Unicode controls for all but Delphi/BCB 2009, but does not include the TMS controls themselves. You will have to purchase TMS Unicode if you do not already own it for the example project to work.  However, it is not needed for VCLZip itself to support Unicode, nor is it needed for Delphi/BCB 2009.