%MODULE% 
Author Message
 %MODULE%

Hi all,
In VC 5, the %MODULE% was expanded to the long file names, in VC 6 is
expanded to short file names (with "~1"). This is very unpleasant for me. Do
you know how to change this?
Regards,
Remus


Fri, 29 Jun 2001 03:00:00 GMT  
 %MODULE%
The offending code is in the registration code in atlbase.h. For example
CComModule::UpdateRegistryFromResourceS() (and other places) however, before
you override this to use a long file name look at the comment:

 TCHAR szModule[_MAX_PATH];
 GetModuleFileName(_pModule->GetModuleInstance(), szModule, _MAX_PATH);

   // Convert to short path to work around bug in NT4's CreateProcess
   TCHAR szModuleShort[_MAX_PATH];
   GetShortPathName(szModule, szModuleShort, _MAX_PATH);

I don't know if the bug is present in SP4

Richard

--
Dr Richard T Grimes
http://www.grimes.demon.co.uk
Author "Professional DCOM Programming",
"Professional ATL COM Programming",
Coming in Jan 1999  "ATL Programmers Reference"
see http://www.wrox.ocm

Quote:

>Hi all,
>In VC 5, the %MODULE% was expanded to the long file names, in VC 6 is
>expanded to short file names (with "~1"). This is very unpleasant for me.
Do
>you know how to change this?
>Regards,
>Remus



Sat, 30 Jun 2001 03:00:00 GMT  
 %MODULE%
Thanks,
remus


Sat, 30 Jun 2001 03:00:00 GMT  
 %MODULE%

Quote:

>Do you know what the NT4 CreateProcess bug is? I posted this question to
the
>ATL mailing list but got no response.  I also searched the MS KB and didn't
>have any luck there, either.

I can't remember the complete details, but when I was writing "Professional
DCOM Programming" I found that I had to keep the path length down to about
80 characters (I can't remember the exact amount) I occasionally exceeded
this and my servers failed to launch. Obviously using the short name will
keep the path length down.

Richard
--
Dr Richard T Grimes
http://www.grimes.demon.co.uk
Author "Professional DCOM Programming",
"Professional ATL COM Programming",
Coming in Jan 1999  "ATL Programmers Reference"
see http://www.wrox.ocm



Mon, 09 Jul 2001 03:00:00 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. Help Linking Assembly Modules with C Modules

2. %s defined in module %s is duplicated in module %s

3. HELP: x defined in module y is duplicated in module z

4. Module scope variables visible in other Modules?

5. HELP: Linking 16-bit obj-modules and 32-bit obj-modules together

6. MFC Module & Command Line Module

7. Windows module & command line module

8. Help! C# modules talk to C++ modules?

9. How do I call a 16 bit module from a 32 bit module?

10. BC4: Error: ...module OwlMain... in module winmain??

11. RAR Module Needed

12. Modules for zipping and raring files

 

 
Powered by phpBB® Forum Software