Solutions
Corporate
about Megaphat
legal
contact us
support
solutions
Frequently Asked Question
In this page we have attempted to answer many of the questions typically associated with vbExport, it's use, what it is and how-to-do's. If you have any questions not answered in this FAQ, please feel free to fill out a survey contact at the bottom of this page.
Q: What is vbExport?

A:vbExport is an add-in tool for Visual Basic programmers which provides them the ability to create exportable functions or subs from public functions into a DLL or EXE. Using a method called Native Exporting Technology, developers can create functions in projects, which can be called using the Windows API. This used to be something only languages such as Visual C++ and Delphi did and now it is available to Visual Basic programmers as well!

Q: Is it hard to export a function?

A: Not at all. Simply just create the function you want to export in a global file (BAS) and be sure that you decalre it as Public.

 Q: Do I need to distribute anything with the DLL/EXE I compiled with vbExport?

A:The only requirements are the standard visualbasic runtimes and controls your project references, vbExport does not add any requirements.

Q: Why can't I find the vbExport interface in my Visual Basic References?

A: If you do not see the Megaphat Interface for vbExport in your references, you may have to add the reference manually. To do this, simply hit browse and select where you installed vbExport. You should see the object reference file there. If you do not, please contact Megaphat Industries for further instructions.

Q: Whenever I export a function using a string as a parameter or the return value, I get a GPF from my application. Why does this happen?

A:This is simple. Since Visual Basic passes a reference to a string to it's memory space, the run-time library interprets where the actual string value is stored. This is a dynamic allocation and cannot truly be passed because vbExport cannot go past the Visual Basic run-times. However, there are workarounds that work just fine. One workaround is by using a fixed-length string which pre-allocates the memory space required. Another workaround is by using a Variant. Either of these methods have proven effective.

Q: I need a DLL which returns an array of UDTs. How does vbExport handle this?

A: vbExport can return an array of UDTs just fine. Just be sure to define the array not only in your application, but in the vbExport'ed DLL as well.

Q: Is the DLL generated using vbExport thread safe in the WEB development environment?

A: Yes. The DLL is will be loaded by the actual thread of the web process. We do suggest using a separate process for the web if you have further concerns. This will ease the load on the actual inetinfo process and allow you to monitor the application process.

Q: Will vbExport work on Visual Studio .NET?

A: VS.NET uses a different method for compiling Visual Basic.NET projects and at this time, vbExport v2.0 will not work with VS.NET.


Q: I created a simple ActiveX DLL similar to the one in the examples provided. Upon following the instructions, I tried compiling the executable. vbExport never gave me an option to export my function as the sample previously indicated. What can I do about this?

A: Typically, this would be caused by an incomplete configuration of vbExport. This can be remedied by simply selecting vbExport as your compiler type in the vbExport startup dialog. This can be found in the vbExport program group.


<- Back to previous page