HeaderPane
Main
Hide
Share Link
Print

Upgrading To Version 6.0

Converting an Existing Application

The conversion is not automatic, but takes just a few minutes for a project.

Only a minimal conversion is required when upgrading from SftBox/OCX 5.0 to SftBox/OCX 6.0. SftBox/OCX 6.0 is virtually 100% source compatible with older releases of SftBox/OCX. Your application(s) must be recompiled to use SftBox/OCX 6.0. SftBox/OCX 6.0 and older versions of SftBox/OCX can coexist on the same system and can be used in the same application.

Make sure to back up your current projects, before converting your projects. Please read the conversion process specific to your language carefully BEFORE converting your project. After converting, once the control saves updated property settings, you will not be able to return to SftBox/OCX 5.0.

.NET (Managed Languages)
Visual C++ (Unmanaged C/C++)
HTML
Other Development Tools

.NET (Managed Languages)

While most other languages offer a fairly easy conversion, .NET and its languages require a bit more effort, but in most cases it is limited to the steps documented below.

Existing Forms (.cs, .vb Files):

Updating the forms to use SftBox/OCX 6.0 is quite straightforward:

  • A reference to SftBox/OCX 6.0 needs to be added to the project. This is easily accomplished by adding a SftBox/OCX 6.0 control to any form of your project. It is located in the toolbox group Softel vdm, Inc. For information about this, please see "Using SftBox/OCX with .NET". As soon as this new control is added to your form, the references are added to your project. The Solution Explorer window now shows two new references to AxSftBoxLib60 and SftBoxLib60. Once these references are added, the new control can be deleted from your form. The references remain.
  • If you are upgrading from a version prior to 5.0 also perform the following step:
  • Close all forms.
  • Open each form, one at a time, using the View Code menu entry in the Solution Explorer window. The popup menu is accessed by right-clicking on a form name. If you accidentally open a form in design mode, close it without saving, as your current control settings for this form are most likely lost.
    • Edit all occurrences of SftBoxLib50 and replace them with SftBoxLib60. This also replaces AxSftBoxLib50 with AxSftBoxLib60. If you are upgrading from a version prior to 5.0, the name reflects that version (for example SftBoxLib45).
    • If you are upgrading from a version prior to 5.0 also perform the following steps:
  • The existing references to SftBox/OCX 5.0 (or older) can now be removed. If the Solution Explorer window shows references to AxSftBoxLib50 and SftBoxLib50, these can be removed.
  • If your project includes the source file OLEConvert.cs (C#) or OLEConvert.vb (VB), remove it now. It is no longer needed.

The forms can now be opened and the project uses SftBox/OCX 6.0 exclusively. You will not be able to return to SftBox/OCX 5.0.

Visual C++ (Unmanaged C/C++)

Resource Files

After installing SftBox/OCX 6.0, all your projects will continue to use SftBox/OCX 5.0 until you make the following change in each dialog resource that defines a SftBox/OCX control. Before opening the resource script (RC file), make sure to close the project in Visual C++, then edit the RC file using a text editor and make the following changes:

IDD_MFC_DIALOG DIALOGEX 0, 0, 320, 200
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
EXSTYLE WS_EX_APPWINDOW
CAPTION "MFC"
FONT 8, "MS Sans Serif"
BEGIN
 DEFPUSHBUTTON "OK",IDOK,260,7,50,14
 PUSHBUTTON "Cancel",IDCANCEL,260,23,50,14
 CONTROL "",IDC_SFTBOX1,"{{C5F14F4A-FA60-40b9-9109-609D83030E40}}",
 WS_TABSTOP,7,41,123,12
END

The ClassID in the CONTROL line describing SftBox/OCX 5.0 should be replaced with the following:

CONTROL "",IDC_SFTBOX1,"{{D2BBC473-1878-49DD-8AE8-B5164ED8D956}}",

Only change the ClassID (i.e., C5F14F4A-FA60-40b9-9109-609D83030E40), do not change the rest of the line.

You can copy this information directly from this page. The ClassID must be copied as-is, without any modifications.

Once the RC file has been saved, you can open the project in Visual C++ and the project is now using SftBox/OCX 6.0. The controls will save updated property settings, so you will not be able to return to SftBox/OCX 5.0.

Make sure to change ALL occurrences of SftBox/OCX to version 6.0, otherwise you will not be able to open the resource script (RC file).

#import Statements

The #import statement used with SftBox/OCX 5.0 must be replaced with an #import statement for the new version:

Version 5.0:

#pragma warning(disable : 4192) // automatically excluding 'Ixxx' while importing type library 'stdole2.tlb'
// For information about the following construct, please see Microsoft's
// KnowledgeBase entry Q224610
#import <SftBox_IX86_U_50.OCX> rename_namespace("SftBoxNameSpace") rename("LoadImage", "LoadImageSftBox")
#if _MSC_VER >= 1400 // need at least Visual Studio 2005
# pragma comment(lib, "comsuppw.lib") // avoid link error in VS2005
#endif
#pragma warning(default : 4192)

using namespace SftBoxNameSpace;

New for SftBox/OCX 6.0:

#pragma warning(disable : 4192) // automatically excluding 'Ixxx' while importing type library 'stdole2.tlb'
// For information about the following construct, please see Microsoft's
// KnowledgeBase entry Q224610
#ifdef _WIN64
#import <SftBox_x64_U_60.ocx> rename_namespace("SftBoxNameSpace") rename("LoadImage", "LoadImageSftBox")
#else
#import <SftBox_IX86_U_60.ocx> rename_namespace("SftBoxNameSpace") rename("LoadImage", "LoadImageSftBox")
#endif
#if _MSC_VER >= 1400 // need at least Visual Studio 2005
# pragma comment(lib, "comsuppw.lib") // avoid link error in VS2005
#endif
#pragma warning(default : 4192)

using namespace SftBoxNameSpace;

HTML

SftBox/OCX 6.0 does not include a control for use with Internet Explorer or cabinet files. Web pages that use SftBox/OCX 5.0 (or older) cannot be upgraded to SftBox/OCX 6.0.

The methods provided for Internet Explorer/VBScript, whose names end in V (such as GetPositionV, HitTestV and FindCellDataV), are no longer available. Applications that call them from other environments use the methods of the same name without the V suffix instead.

Other Development Tools

Most development tools allow access to the ClassID used for controls on a form or dialog. Sometimes this may be accomplished by using a text editor and editing a configuration file, or possibly the development tool allows direct modification of the ClassID.

Generally, the ClassID used for the prior release C5F14F4A-FA60-40b9-9109-609D83030E40 must be replaced with the new ClassID D2BBC473-1878-49DD-8AE8-B5164ED8D956. Once this step is completed, opening the project is sufficient to allow SftBox/OCX to convert the stored property settings.

For specific instructions or help, please see your development tool's documentation.


Last Updated 11/22/2026 - (email)
© 2026 Softel vdm, Inc.