how to package and deply a VFP OlePublic (COM Object)? - installshield

How do I deploy a VFP OlePublic dll to a Windows Server 2016 machine that is called via COM Interop from .NET hosted in an IIS website? What other bits do I need to deploy beside my VFP dll?
I would think I would use InstallShield Express Visual FoxPro Limited Edition (included w/ the install of VFP9), no?
Define Class miked As Session OLEPUBLIC
FUNCTION HelloWorld as String
RETURN "Hello World"
ENDFUNC
FUNCTION Echo(thingToEcho as String) as String
RETURN thingToEcho
ENDFUNC
Enddefine
InstallShield MSI package
I included the following redistributable packages in my installer:
GDI Plus Redist Module
Microsoft C Runtime Library 7.1
Microsoft Visual FoxPro 9 Runtime Libraries
I'm able to manually register the dlls from an admin PowerShell prompt w/ regsv32 so that part seems ok.
I get the following when trying to instantiate an instance of this COM object.
Retrieving the COM class factory for component with CLSID {A55C4127-DDCB-4E5F-B69C-A7EAC83A83DC} failed due to the following error: 80004005 Unspecified error (Exception from HRESULT: 0x80004005 (E_FAIL)).
On my additional test server, I installed VFP 9 w/ SP2 and my error went away but doesn't seem right. I probably shouldn't have to install the IDE to deploy the DLL.

On my additional test server, I installed VFP 9 w/ SP2 and my error went away but doesn't seem right. I probably shouldn't have to install the IDE to deploy the DLL.
That was not correct. I reset my VM using a checkpoint, performed a fresh install of my app & it worked.
Packaging up a VFP COM dll as described in my question works!
Using Simon's comment & procman I was able to kinda solve my problem.
E_FAIL is a super generic error (but it seems the entry COM .dll is indeed registered otherwise you'd get another error). You can try to run Process Monitor on the machine, filter by .exe, and check registry and possibly file accesses if there are some missing .DLL dependencies
I found some not successes under my exe name trying to load vfp9r.dll:
those files got installed w/ my InstallShield package under C:\Program Files (x86)\Common Files\Microsoft Shared\VFP:
I copied the three DLLs:
vfp9r.dll
VFP9RENU.dll
vfp9t.dll
from C:\Program Files (x86)\Common Files\Microsoft Shared\VFP to my DLL install directory, restarted IIS & it worked 🎉. This off course is a workaround as it is finding those dll's on my other server but that's another question 😊.
restart IIS:

Related

Unable to load DLL 'MFCapturer': The specified module could not be found. (Exception from HRESULT: 0x8007007E) in TokBox

I am making a video sharing tool with the help of TokBox.
This works fine in the Windows 7 / 8 / 8.1
But Same program is giving the
Unable to load DLL 'MFCapturer': The specified module could not be found. (Exception from HRESULT: 0x8007007E) error in the Windows 10.
Is there any way to fix it.
Official documentation OpenTok Windows SDK - for building WebRTC video apps on Windows states:
When creating an installer for your application, add Visual C++ Redistributable for Visual Studio 2015 as an installer package. Use the x86 version, the x64 version, or both, depending on the architecture of your application.
We installed 64-bit version because everything was 64-bit, had same problem as you and reported to vendor.
We observed that even with platform-agnostic .NET code, running on a 64-bit OS required installing 32-bit version of the C++ redistributable on the target.
Edit: download link for both versions https://www.microsoft.com/en-us/download/details.aspx?id=53840

Unable to install VSIX in VS 2012 & Windows 10

I am trying to install RXX(VSIX Isntaller) in windows 10 & VS 2012. But it gives error as below
The extension 'Razor(cshtml) pre-processor requires a version of the .NET framework that is not installed.
It is working properly in Win 7 ( .NET Framework 4.5 ). When I tried to install .NET framework 4.5 in Win 10, its no allowing to do the same.
Can anyone suggest anything for this?
Thanks
I expect the VSIX manifest to reference a specific .NET framework version and doesn't specify a range. Since .NET 4.6 replaces 4.5 it may cause these type of issues.
Extract the VSIX using your favorite extraction tool (it's a zip file), edit the manifest file by removing or updating the dependencies specified and zip it back up.
The only way to install the extension was executing the VSIXInstaller.exe as administrator and passing the VSIX file as parameters. To do that, follow this procedure:
Open a CMD window as Administrator
Go to Common, IDE folder of the VS 2015 installation. In my case:
CD C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE
Execute the installer passing the VSIX file as parameter. In my case:
VSIXInstaller.exe c:\AppBuilder.vsix
Finally, the installer will start the installation!
I hope it helps you
Source

VS2012 Install Shield project building using TFS build definition

I have a VS2012 sln which includes an install shield installer project.
If I build the solution/projects manually via solution explorer everything builds fine.
However when using the TFS build definitions i get the following error:
C:\Builds\1\<NAME>\<Build_Definition_Name>\Sources\InstallSetup\InstallSetup.isproj (29): The imported project
"C:\Program Files (x86)\MSBuild\InstallShield\2012SpringLimited\InstallShield.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk.
Can someone please help with this?
Info:
Using VS 2012
OS - Win 7 x64 Pro
You need to install InstallShield on the machine on which you are running the build.
In-case someone is facing the same issue, I was able to solve it by reading what Flexera mentioned on their website: Link
Brief description: in build definition, process tab, make sure the MSBuild Platform is targeting x86.
I too had 64bit Windows (8.1) running and Team Foundation Server 2013 Express.

DLL load failed: The specified module could not be found on Windows7 32-bit machine?

I am creating dll in windows7 professional 32 bit machine ,same dll registering another 32 bit windows7 professional service pack 1 machine this dll is not registered showing below error.
Unable to load DLL 'coredll.dll': The specified module could not be found.
How to resolve the compatabilty problem?
Regards
Narasimha
Loading a DLL requires that all dependencies of the DLL are resolved. You should use the Dependency Walker to get the list of DLLs that are required. When you copy the Dependency Walker to the target machine it should display the missing DLL immediately.
When you create a DLL from VC++ it requires usually the VCxxRT (Visual C++ run time) DLls. These DLLs come in different versions. When you target machine has not installed the correct version you get this error.
Check the installed version by looking at C:\Windows\winsxs for x86_microsoft.vcXX.crt_*.
EDIT: Hans' comment is correct. coredll.dll is a Windows CE DLL. It makes no sense to run regsvr32 with a DLL that requires coredll.dll at your PC. You can check this with:
dumpbin /headers IPTCExt.dll | find "subsystem"

missing header file on a new installation of visual studio 2012

I just installed visual studio 2012 and tried running my C++ project on it.
compilation fails due to missing "SDKDDKVer.h", "windows.h", etc.
I installed the windows 8 sdk from Windows Software Development Kit (SDK) for Windows 8, but after successfully running the installer with the default components (including the windows headers), I can't find any include folder under C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0 or C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A.
I ran the SDK installer twice + tried to repair and still I can't find any trace of the windows header files.
Did anyone encounter something similar?
what am I missing? my OS is win7 x64. I uninstalled VS2010 before installing VS2012.
thanks,
It's a bug caused by VS2012 using the configuration of VS2010.
You have to manually fix the include libraries to get around this (through the property manager).
The substantial modifications needed are :
adding $(WindowsSDK_IncludePath) to the include paths
adding $(WindowsSDK_LibraryPath_x86) or $(WindowsSDK_LibraryPath_x64)
to the library path depending if your building for x84 or x64.
The same problem also exists when you upgrade a VS2010 project to VS2012.
To me, manually fixing the include dirs (see step 1 in previous answer) took care of the problem.

Resources