473,387 Members | 3,750 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

COM StdPicture-to-Image conversion and Bizarre GAC behavior

We're authoring a VS 2005 app that includes several EXE's and DLL's and also
uses a COM component (a customer requirement). The COM component provides a
graphic image to be used by the .NET app; the graphic is supplied as a
"StdPicture" (AKA, IPictureDisp). The only way I have found to convert this
to a .NET Image is:

Microsoft.VisualBasic.Compatibility.VB6.IPictureDi spToImage

Is that the only way to accomplish this conversion? How would a C# app do
it?

OK, so I build my app and want to try an installation on a clean test
machine (XP SP2). I install the v2.0 framework, copy all relevant files to a
target folder (including the Interop wrapper DLLs VS creates for the COM
libraries), and register the COM components. The app runs OK, until it tries
to generate the graphics (from the COM server). The following error occurs:

"Could not load file or assembly 'stdole, Version=7.0.3300.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its
dependencies. The system cannot find the file specified."

Hmm, I open Windows Explorer on the test machine, navigate to
C:\Windows\assembly, and I get the "special view" of the GAC that Explorer
provides. Like the error message says, stdole is not there. So, still
working on the test PC, I navigate in Explorer to my dev machine across the
LAN (via "My Network Places"). I go to C:\Windows\assembly on my dev
machine, and I'm shocked to see that stdole is not there either - how the
heck is this working on my dev machine?

So I walk over to my dev machine, open Windows Explorer and navigate to
C:\Windows\assembly, and darn it - stdole.dll IS THERE. What the ?????

OK, still in Windows Explorer at my dev machine, I navigate across the LAN
to the test machine, and look in its GAC, and guess what - stdole.dll IS
THERE TOO.

Just as I start to doubt my sanity, I look more closely at what else is
there - checking the title bar and confirming that I am in fact pointed to
the GAC of the test machine, not the local folder. I see entries for
software that is NOT installed on the test machine - components that are
only installed on my local dev machine.

Conclusion - somehow Windows Explorer is always showing the contents of the
local GAC, regardless of the folder to which you have navigated. Perhaps its
a side effect of the "special view" of the GAC the Explorer provides, but it
sure is bizarre. Anyone else ever see this behavior ??

So, I guess I should be installing stdole.dll as part of the app's setup
kit, but I imagine it does not necessarily have to go in the GAC.

Any comments or suggestions would be welcomed and appreciated.

-Mark
~ This space intentionally left blank ~
Apr 28 '06 #1
0 1933

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Geoff | last post by:
In this code I am trying to pass an image, as a parameter, out of the procedure PickCard. The code will not support this. How do I pass an image as a parameter? Thanks again Geoff
17
dbanning
by: dbanning | last post by:
I am trying to save the contents of a form as a bitmap and am unsure how to do this. I can use the savepicture command to save the form as a bitmap but the contents is not intact as you would expect....
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.