Hi Hutch,

I had a major PC disaster on 02-28-2003, I won't go into the gory details.

Aynhow I had to rebuild my systems from scratch and I'm about 85% done.
I had to download your Masm32 V8 package for my AsmEdit package,
(I lost all of the previous versions) and I can no longer assembler any of my
programs that use the IShellFolder Interface it looks like all of the IID_Ixxxxx
references are gone from the Shell32.lib file.

Was there a reason for that?

I had someone send me a previous version of your Include/Lib files and they
work ok.

I was going to try to patch something together, but I can not figure out where
you found the IID_Ixxxxx input when you built the Shell32.lib file.

I hate to start getting a bunch of emails from folks saying they can not assemble
some of my programs after they updated the Masm32 package to V8.

Thanks for any help.

Ewayne
Posted on 2003-03-18 19:07:33 by Ewayne
Ewayne,

I think I know what has happened, to get the package size down, I build the libraries from the include files but the include files only contain exported API function calls so the iShell interface will not be in the library.

If you have access at a standard Microsoft issued library, try running it instead and produce an include file from it if you need the API function prototypes.

If this is not the problem, let me know and I will try and find something else.

Sorry to hear about the crash, I had a fatal one in 1999 that lost 6 months work on me so I have been doing multiple backups across different machines and writing CDs since.

Regards,

hutch@movsd.com
Posted on 2003-03-19 01:31:56 by hutch--
These IID_ externals should be found in UUID.LIB
Posted on 2003-03-19 01:56:34 by japheth
To japheth:

The IID_ externals are not in my UUID.LIB.

Thanks,

Ewayne
Posted on 2003-03-19 08:34:00 by Ewayne
To Hutch:

I do not have access to a standard Microsoft issued library.

I'm a little confused (not unusual), in the previous version of Masm32
Include/Lib files that someone sent me the shell32.lib has the IID_externals
but the Shell32.inc has no reference to them. How did the lib build program
get the information for the IID_externals?

I think I can build a seperate .lib file with the IID_externals in it, but I would
like to know how you did it with the previous versions of Masm32.

I know you put a ton of work in Masm32 V8, but don't you think you should
put the IID_externals back in in case someone wants to write a program
using the IShellFolder Interface and IID_externals? (just wondering)

About my disaster I had two internal drives and one large external scsi
fixed drive and one 2gig removable scsi drive and I could boot from all four.
I thought I was safe (wrong)

The three fixed drives got toasted and I got lazy backing up the the removable.

I got three new drives for the old PC and I bought a new 2.8GHz 1gig mem PC,
setup with three drives and I have a cdRW drive for both PC's plus a remote backup.

If I do my daily backups like I should maybe I'll be safe this time.

What bug's me is that I was writting a RichEdit control to replace M$ RichEdit and
it was in the final stage and I lost most of that work.

Thanks,

Ewayne
Posted on 2003-03-19 09:13:38 by Ewayne
I have versions 7,5,4, right on my backup drive.

Just let me know and I will post what you need.

Regards, P1
Posted on 2003-03-19 09:20:50 by Pone
To Pone:

Thanks for the feedback.

I have my AsmEdit package working with a previous release of the Include/Lib files
that someone has sent me.

I can use Masm32 V8 except I think only the Shell32 files need to be changed.

Lets wait for Hutch's response.

Thanks again.

Ewayne
Posted on 2003-03-19 09:46:25 by Ewayne
Ewayne,

Here are the two libraries from the PLATFORMSDK for win2k. They are shell32.lib and uuid.lib.

What I need you to do is try them out one at a time to see if this is the problem. I think what has happened is that the technique I use to build thwe libraries in MASM32 v8 only builds normal exported API function calles that use the STDCALL convention. I added the wsprintfA prototype manually and it is included in the normal lib as well.

This means that function accessed in other way are not in the library and this is probably what the problem is. If the code works with the Microsoft libraries it verifies what the problem was.

Please let me know what happens with these libraries.

Regards,

hutch@movsd.com
Posted on 2003-03-19 20:03:53 by hutch--
To Hutch,

The Shell32.lib that you sent works great on the programs that I could not assemble
with the Masm32 V8 Shell32.lib, I'm not using any functions that are in the Uuid.lib so
I didn't need to use it.

Thanks,

Ewayne
Posted on 2003-03-19 20:43:16 by Ewayne
Ewayne,

thats a good result as it identified the problem straight away. I would enclose the library with your package so that the problem does not occur with users at all. It is from the Platformsdk so its should be legal to do so.

All you would need to do is have some instructions so that the user can place the library correctly and everything will work.

I am stuck with the idea of building the libraries as it produced a 40% bandwidth drop with the MASM32 package. The download rate has been very high and it was straining a number of servers from members who have been kind enough to help out so I had to change how it was done.

Regards,

hutch@movsd.com
Posted on 2003-03-20 01:32:16 by hutch--
Ewayne,

Do you have the actual prototypes for the functions you were after from the shell32.lib library ? The toy for building the libraries can handle both STDCALL and C calling conventions so if its C calling, all I need to do is add the prototypes manually and the functions will be included in the library.

Regards,

hutch@movsd.com
Posted on 2003-03-20 04:30:25 by hutch--
To Hutch:

The following are the only prototypes that I use.

CLSID_ShellDesktop
CLSID_ShellLink

IDD_IUnknown
IID_IContextMenu
IID_IContextMenu2
IID_IShellExtInit
IID_IShellPropSheetExt
IID_IExtractIcon
IID_IShellLink
IID_IShellCopyHook
ID_IFileViewerSite
IID_IFileViewer
IID_IEnumIDList
IID_IShellFolder

I have tried adding them in your V8 Shell32.inc and bulding
a new Shell32.lib the entries show up in the Shell32.lib, but
it does not work. (I must be doing something wrong)

Thanks,

Ewayne
Posted on 2003-03-20 08:44:33 by Ewayne
Ewayne,

problem is I have no way of testing what these functions do but give this a try if you have not already done it.

For each function in the list, try it with the C calling convention with VARARG.

IID_IShellFolder PROTO C :VARARG

I had a look through the shell32.lib and there are a big pile of functions including the ones you require that do not have parameter data like STDCALL ones but they still appear to only be export entries, not static code in a library so its worth trying them as C calling.

I would be interested to see if this works.

Regards,

hutch@movsd.com
Posted on 2003-03-20 17:38:33 by hutch--
To Hutch:

The:

IID_IShellFolder PROTO C :VARARG (Works ok)

IID_IContextMenu PROTO C :VARARG (Does not work ok)

The program assembles and links ok, but when you try to execute
it I get an:

Error Starting Program
The xxxx.exe file is linked to missing export SHELL32.DLL:IID_IContextMenu
message.

Looking in my Windows.inc I can not see where there should be a difference
between the IID_IShellFolder and the IID_IContextMenu.

Any other suggestions?

If you would like I could put together a little program that uses the two
interfaces and send it to you.

Thanks,

Ewayne
Posted on 2003-03-20 20:22:55 by Ewayne
Hi Hutch,

these IID_xxx definitions are references to COM interface IDs. When referencing such an external, the linker includes such an IID (which results in 16 data bytes included, i.e.: {12345678-1234-1234-01293940596696}) .So I would suggest to define it with EXTERNDEF in include files ("externdef stdcall IID_xxxx:IID"), not with PROTO statement. But inside the lib these 16 bytes must be defined!

Japheth
Posted on 2003-03-21 03:24:56 by japheth
To Hutch:

I've tried 37 different ways of writing a Shell32.asm and then
creating a Shell32.lib, I can get it close, but I still can not get
the IID_IContextMenu interface to work.


I usually don't give up on a problem, but it looks like there is
something I don't know about.

So for the time being I will just include your Masm32 V7 Shell32.lib
with AsmEdit.

But what are you going to do with your package if someone wants
to write a program using a IID_xxxx interface?

Thanks,

Ewayne
Posted on 2003-03-21 21:53:11 by Ewayne
Ewayne,

The suggestion that Japheth made is an interesting one but I don't know how the original Microsoft library was made with the COM interface. The EXTERNDEF part makes sense but I don't know enough about the COM interface to try and emulate it in ML.EXE to build the import library.

Regards,

hutch@movsd.com
Posted on 2003-03-21 23:58:38 by hutch--
Hi,

most of these shell IID are made public in SHLGUID.H from SDK. So to define a public IID_IContextMenu for example this may work:



DEFINE_SHLGUID macro name, l, w1, w2
s&name textequ <{l, w1, w2, {0C0h,0,0,0,0,0,0,046h}}>
endm

DEFINE_SHLGUID IID_IContextMenu, 0000214E4h, 0, 0

IID_IContextMenu GUID sIID_IContextMenu
public IID_IContextMenu


Japheth
Posted on 2003-03-22 06:43:15 by japheth