Page 1 of 2

Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 12:00 am
by rconn
I'm having a problem with the VC++ integration. I tried compiling your VC++ example, but the compile fails:

1>------ Rebuild All started: Project: TextPipeEngineDemo,
1>Configuration: Debug Win32 ------ Build started 2/29/2012 1:34:55 AM.
1>_PrepareForClean:
1> Deleting file "Debug\TextPipeEngineDemo.lastbuildstate".
1>InitializeBuildStatus:
1> Touching "Debug\TextPipeEngineDemo.unsuccessfulbuild".
1>ClCompile:
1> stdafx.cpp
1>d:\datamystic\textpipe engine\vcpp\stdafx.h(44): error C4772: #import
1>referenced a type from a missing type library; '__missing_type__' used
1>as a placeholder
1>
1>Build FAILED.

The line in stdafx.h it's complaining about is:

#import "libid:C48067D1-B25E-43A8-BC49-E016D3482B7B" raw_native_types, named_guids, rename_namespace("TPEngine")

This is with Visual Studio 2010 -- I don't have the older version (2003?) that you apparently used to create the example.

Any idea how I can get this working?

Thanks for your help.

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 12:14 am
by rconn
Update:

I tried changing the line:

#import "libid:C48067D1-B25E-43A8-BC49-E016D3482B7B" raw_native_types, named_guids, rename_namespace("TPEngine")

to:

#import "d:/datamystic/TextPipe Engine/textpipeengine.dll" raw_native_types, named_guids, rename_namespace("TPEngine")

which gets it past the compile error, but it then fails when trying to create the textpipe engine instance:

hr = spApp.CreateInstance(TPEngine::CLSID_Application);

returns "0x80040154 Class not registered".

Thanks for your help.

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 8:29 am
by DataMystic Support
The installer is meant to register the engine dll, but it appears this has not happened.

Please run
Regsvr32 textpipeengine.dll

That should fix the 'Class not registered' error.

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 8:47 am
by rconn
I had thought of that, and tried registering the engine dll manually (I had to run a command session as administrator to do it in Windows 7), but it still returns the "Class not registered" error when running the vcpp demo app.

Is there another COM dll that textpipeengine.dll is trying to access?

(Note that I don't have any problems running the full TextPipe Pro.)

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 11:54 am
by rconn
I had the dll's in the demo app folder. I just tried putting them in the c:\windows\syswow64 folder (it’s a Windows 7 x64 system), and I get the same result.

Have you tried building the demo app with VS 2010 and/or Windows 7? (Just trying to figure out if it’s a local configuration problem or the demo app project won’t work with VS2010 and/or Win 7 x64.)

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 12:10 pm
by DataMystic Support
3.1 Required DLLs and DLL locations
textpipeengine.dll - The TextPipe Engine
Required. MUST be either in your application's folder, or in the WinNt\System32 folder.
borlndmm.dll - The Borland memory manager
Required. MUST be either in your application's folder, or in the WinNt\System32 folder.
stdvcl40.dll – The Borland standard visual controls.
Required. MUST be either in your application's folder, or in the WinNt\System32 folder.

In all cases above, where WinNt\System32 is specified, you can also substitute Win95\System32 or whatever the appropriate folder is for your operating system.

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 01, 2012 2:56 pm
by rconn
Hi Simon:

All of the dll's are in the required locations. Still get the "class not registered" error message.

Has any other user here managed to get the textpipe engine working with VS 2010 and Windows 7?

Re: Can't compile TextPipe Engine example

Posted: Fri Mar 02, 2012 3:30 am
by rconn
Interestingly, if I replace this line:

#import "d:/datamystic/TextPipe Engine/textpipeengine.dll" raw_native_types, named_guids, rename_namespace("TPEngine")

with this one:

#import "d:/datamystic/TextPipe/textpipe.exe" raw_native_types, named_guids, rename_namespace("TPEngine")

Everything works! (But it's only a short-term fix -- I can continue to test textpipe with my apps, but I can't distribute textpipe.exe to my beta testers.)

Something about textpipeengine.dll that VS 2010 and/or Windows 7 x64 doesn't like.

Re: Can't compile TextPipe Engine example

Posted: Mon Mar 05, 2012 2:28 pm
by rconn
I tried one more experiment (to make sure that it wasn't a problem solely on my development system).

I created a new Windows 7 VM, installed VS 2010, then TextPipe and the TextPipe Engine (and nothing else). Built the solution, and it failed in exactly the same way.

So I'm fairly sure it's not a configuration issue, or a conflict with some other app.

Re: Can't compile TextPipe Engine example

Posted: Mon Mar 05, 2012 2:41 pm
by rconn
I also tried monitoring the demo app with Process Explorer, to see if it loaded textpipeengine.dll and the problem was with a subsequent load.

But textpipeengine.dll never loaded -- a couple of Windows RPC dll's loaded at spApp.CreateInstance(TPEngine::CLSID_Application), but nothing else (and the CreateInstance failed).

Re: Can't compile TextPipe Engine example

Posted: Tue Mar 13, 2012 1:25 pm
by rconn
Have you had a chance to look at this yet?

Re: Can't compile TextPipe Engine example

Posted: Tue Mar 13, 2012 2:49 pm
by DataMystic Support
Sorry, not as yet. We've had a long weekend here, so still cleaning up the backlog.

Re: Can't compile TextPipe Engine example

Posted: Thu Mar 15, 2012 11:48 pm
by rconn
I just downloaded 9.1, installed "tpengine_full9.1.exe" and tried TextPipeEngineDemo again (Windows 7 Ultimate x64, VS 2010, C++).

The behavior is a little different -- now the VC++ compiler doesn't complain about the import:

#import "libid:C48067D1-B25E-43A8-BC49-E016D3482B7B" raw_native_types, named_guids, rename_namespace("TPEngine")

But the program still fails at:

hr = spApp.CreateInstance(TPEngine::CLSID_Application);

which still returns "0x80040154 Class not registered".

Re: Can't compile TextPipe Engine example

Posted: Fri Mar 16, 2012 12:11 am
by rconn
Curiously, if I try to use the import from textpipe.exe instead (which did work in 9.0), it now returns "E_NOINTERFACE". (Regardless of whether I use the libid or the filename.)

Re: Can't compile TextPipe Engine example

Posted: Fri Mar 16, 2012 11:19 am
by DataMystic Support
That's strange.

In v9.0, we changed the auto-registration of textpipe.exe so that it only registers its COM object during install and for the /REGSERVER
command line option - preventing errors on less-than-admin use.

We still include the .tlb file with the install, in the same folder as textpipe.exe.

Did you do a clean install?

We loaded up VS2010 last night so hopefully we will have some feedback for you later today.