I used to include assembly functions in vb6 projects using a Add-In called VbInLineASM, which uses masm to link the assembly code with the executable (I guess). It worked fine in Windows XP
Now, I am trying to build the same vb6 ide enironment in Windows 7, so I installed masm and VbInLineASM, configured the Add-In, all looks OK, I build the executable, no problem no errors, and the asm functions just do nothing!
Can anybody help me with that?
Related
A client has recently given me some work involving their (old) VB6 program. I've successfully installed VB6 in a VM with Windows XP (32 bit), and it works just fine. The problem is when I try to open the client's program. The following messages pop up:
crystl32.ocx could not be loaded--Continue Loading Project?
FM20.DLL could not be loaded--Continue Loading Project?
After that there are a bunch of warnings cause of crystl32.ocx.
So I tried to register the dependencies with regsvr32, but it said that the modules couldn't be found, even though they were right there. Googling the problem took me to download Dependency Walker and find which dll files were needed for those files, which were:
msvcr100.dll
IEShims.dll
wer.dll
crpe32.dll
After downloading these dll files, I tried registering the first one, but it said that the "dllregisterserver entry point was not found". So I tried to unregister it first, but it couldn't find the module.
I've reinstalled VB6 several times, to no effect. Any ideas on how to make this work?
Crystl32.ocx and Crpe32.dll are Crystal Reports run time files.
FM20.DLL is Microsoft Form 2.0 Library with some standard GUI controls like label, text box, check box etc.
Msvcr100.dll is a part of
MS Visual C++ 2010 Redistributable Package
If there is an installer of your client's program you should run it before opening the source code with VB6 IDE. That way you’ll get all the dependencies required by VB6 program.
If not, please post the vbp file of your VB6 application.
thanks for all the help! The solution in the end was the installation of the CR 4.6 that the client later provided me with (as #BrianMStafford suggested), of VB6 SP6 and of Office 2007, together with SP3.
With that I've managed to get the project running, so thanks to everyone!!
I have a win32 console project that have successfully compiled in 'Release' mode. I wonder if I can just deploy that stand-alone exe or should I have a setup program. If I do need to set up program, could someone help point to some helpful tutorial for setting up such a project. The project is compiled with 'Use MFC in a Static Library' setting.
Any help would be great.
First, you'd better check which platform your project compile for. You can prepare both x86 and x64. Then, for each platform, find correspond runtime dlls, such as msvcr120d.dll, mfc110d.dll and distribute them with your standalone exe. To find all necessary dlls, you can execute your standalone exe on another clean computer, and lost file name will be on message. An easy way is to use Visual C++ Redistributable, but it is a little bit large.
I wrote a C++/CLR Windows Form program and it works fine on the compiler computer but not on any others. The target computers have .Net4 and the C++ redistribution pack. I really don't understand how the settings need to be set and the info on the web concerning this stuff is very confusing for a beginner. How do I need to have my compiler set so that I can get this program to run? If I need to link .dll's how do I go about doing that. Here are the key settings as I know:
The Runtime Library is set to /MDd; MFC:Standard Windows Libaries; ATL:Static Link to ATL; CLR:/clr:pure.
Edit: If I install VS on taget computers I can open the .exe without a problem, not even opening VS or loading any source files. It seems it's still dependent on VS somehow, any idea's on this and how to over come it?
/MDd specifies a dynamic debug CRT, this won't be installed by the standard CRT redistributable MSI
Try putting a release build on the target machine instead.
Assume I have source code for a lib/tool that works on gcc compiler. Can I use the same code and compile it in visual studio. will that be possible at all? If it is possible, how do I do it?
if you are just using all the standard C/C++ library like stdio.h, stdlib.h, etc. it should work fine. Pure console program should work fine. If you used some GUI related library (especially if you are porting over from unix to window) then it might not work.
To do so, you can simply just create a new project in visual studio and add the existing source code into the project workspace. Compile it, if you encounter any error, just post here or try solve if you know how
It depends on your code, GCC support a variant of C (C99) which Visual Studio doesn't support yet.
If your trying to compile a Unix program on Windows you best bet will be to use Cygwin.
Check this question for pointers on using Cygwin in Visual Studio.
I am currently working on a platform indepedent project and we have frenquently come across the following problem:
When the Windows guys work on code that is not called by any other part of the code base it will not be compiled and will therefore not trigger compile errors. Once this code is uploaded to a svn server and Linux programmers pull and compile this code they will get build errors. It seems their compiler compiles everything that is included in the code base whereas Visual Studio will only compile used code.
Is there any way to force Visual Studio to compile even unused code as long as it belongs to the project I am currently working on? Or just every code file belonging to the solution would be helpful as well.
EDIT:
Forgot to mention, in case it is relevant:
We are using: Visual Studio 2008 prof. ed.
C++
cmake to create the solution
Windows 7 x64
Thanks for your time!
Regards,
Jan
How about working with preprocessor definitions? I do also work on a cross-plattform project. There are some UNIX methods I cannot use and there are some Win API calls UNIX cannot use. So we have something like that:
void DoSomething()
{
#ifdef WIN
// do Windows specific code
#else
// do UNIX specific code
#endif
}