Convert VB6 app to HTML5 in minutes with Thinfinity VirtualUI

Convert a desktop application written in Visual Basic 6 to the web

In previous articles, we mentioned how simple it is to convert VB6 applications to HTML5 using Thinfinity VirtualUI.
But a simple integration is not always enough; you want to keep all of the functionalities of your application even if you are accessing it through the browser from a remote computer.
Once you have your VB6 application ready to be published on the web, as shown in this article, you may allow users to download files to any remote machine.
The “ThinfinityVirtualUI.DownloadFile” method for VB6 works in a unique way regarding its overload.
DownloadFile([in] BSTR LocalFilename, [in] BSTR RemoteFilename, [in] BSTR MimeType);
[in] BSTR LocalFilename: Name of the local file to be sent.
[in] BSTR RemoteFilename: Name of the file in the remote machine.
[in] BSTR MimeType: content-type of the file. If specified, the content will be handled by the browser. Leave blank to force download.
It’s use
First, we’ll make the following declaration In General – Declarations
have your VB6 application published on the web
This way, we can instantiate the VUI object next.
have your VB6 application published on the web
NOTE: We enabled standard dialogs to let the user select the file from the host in “VUI.StdDialogs = True”. StdDialogs is set “False” by default.
Let’s now create a button to call the “DownloadFile” method in our VB6 application:
have your VB6 application published on the web
This is what we code to open a dialog and let the user get the file. In this case, we will allow the user to select the path in his machine and the file type in case he needs to change it since we passed the second and third parameters both blank.
Convert VB6 application to HTML5
NOTE: This is how the DownloadFile method firm should be coded:
DownloadFile c:\path\filename.ext, newname.ext, application/binary
Free demo:
This VB6 application demo will help you understand how the Virtual Thinfinity UI’s “DownloadFile” method works. You can also use it to replicate the process in your application.
See how this method works with other languages and don’t forget to check Thinfinity Virtual UI’s documentation here.
Should you have any questions about how to convert VB6 software into a web app, contact us at [email protected].

Leave a comment

Privacy Preferences
This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.