我有一个要在Windows 10中运行的VB6 .exe
。我在graph32.ocx
中有gsw32.dll
,gswdll32.dll
和sysWoW64
文件。在regsvr32
上运行graph32.ocx
会产生the module graph32.ocx failed to load
。
我将它们全部移到system32
,结果相同。运行.exe
会导致错误graphs32.ocx or one of its dependencies is not correctly registered
。我尝试以管理员身份在PowerShell中注册。
答案 0 :(得分:1)
从VB6DEP.INI:
[Graph32.ocx]
Dest=$(WinSysPath)
Register=$(DLLSelfRegister)
Uses1=MFC40.dll
Uses2=gsw32.exe
Uses3=gswdll32.dll
您还没有提到MFC40.DLL。确保它存在于路径中。
答案 1 :(得分:0)
尝试将所有文件放在两个目录中;即使 SysWow64 作为 System32 ,您也只能注册 system32 中存在的 int main(){
string line1;
ifstream myfile;
myfile.open("example.txt");
if(!myfile){
cout<<"Unable to open the file."<<endl;
exit(0);
}
while(getline(myfile,line1)){
ReadFile(myfile);
}
}
。>