all groups > dotnet interop > july 2004 > threads for july 22 - 28, 2004
Filter by week: 1 2 3 4 5
How to Marshal a Variable Length Structure
Posted by Charles Law at 7/28/2004 4:49:40 PM
Sorry for the cross post, but I have just realised that this might be a
better place for this question.
Can anyone suggest how I would marshal a variable length structure back from
an API call. Specifically, I am looking at the WaitForDebugEvent function,
which returns a DEBUG_EVENT structure.... more >>
Help with PIA's and Office 2000
Posted by Frank Bacon at 7/27/2004 9:26:32 PM
I wrote an app that transferred data from Excel to Access (Office 2000 on XP
Professional).
I had it in release form and it was working fine. I installed PIA's to
develop another
App and now I get an error on the first App informing me of an unhandled
Exception of the
type "System.InvalidCast... more >>
Web Browser control: navNoHistory flag doesn't work
Posted by rsmith_666 at 7/27/2004 6:38:04 PM
I've created a project with a web browser control according to KB article 325079 (C#). The BeforeNavigate2 event fires correctly, but I'm not able to prevent the URL's from going into the browser history. I've tried to modify the Flags parameter in BeforeNavigate2 event but that had no effect and ... more >>
binary compatibility support for .NET assembly
Posted by someone at 7/27/2004 6:16:38 PM
Suppose that I have a class in an assembly that is delivered to the user,
what can I do to change the class so that it doesn't break the
binary compatibility? That is, user application can run with recompiling
and relinking.
I know that if I define an interface, and only expose the interface ... more >>
strong naming DLLs
Posted by DotNetJunkies User at 7/27/2004 3:15:22 PM
I created a .NET (DLL) called DBWrapperNET.DLL. It uses ADO 2.8 for the DB access.
This DBWrapperNET.DLL is to be used by multiple VB6 applications. I wanted to "strongly name" this DLL so that it can be shared by different VB6 applications (like we created other DLLs and register them).
I am n... more >>
COM Object Lifetime when called from VB.NET
Posted by Greg Doherty at 7/27/2004 12:02:28 PM
Hi,
I have a C++ COM class that I instantiate from VB.NET, but the object never
gets released. Is there something that I need to do to force the
destruction of the object?
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button2.Click
Dim Im... more >>
Using VB.Net or C#, utilizing the clipboard object, how to copy an MS Excel graphic from the clipboard to an image control and obtain its source refer
Posted by TC at 7/27/2004 9:39:21 AM
Hello,
Here is what I'm trying to do:
-- Make sure both MS Excel and MS Word are running
-- Create an Excel chart
-- Save the Excel file
-- Copy the Excel chart onto the clipboard using Ctrl + C
-- Go to Word and look under Edit > Paste Special
-- Note there is a source reference and an o... more >>
Marshaling Fixed Length Strings in Structure
Posted by Tom Wells at 7/26/2004 4:09:38 PM
I trying to pass this structure to a dll:
<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Ansi, Pack:=1)> _
Public Structure udtINTER01
<VBFixedString(8), MarshalAs(UnmanagedType.ByValArray, SizeConst:=8)>
Public action As Char()
<VBFixedString(7), MarshalAs(UnmanagedType.ByValArra... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Help with Excel and Interop?
Posted by cduden at 7/26/2004 2:40:36 PM
I'm linking an excel workbook programmatically to a powerpoint presentation
via an add-in written in C#. When opening the presentation, I check the
document to see if it is the latest version, refresh the object if it isn't,
and powerpoint spawns an Excel process that never goes away, which
effe... more >>
Problem calling unmanaged API Functions
Posted by Brent at 7/26/2004 11:11:13 AM
Hi guys,
Here is my problem:
I have a C DLL function I need to ccall from VB.Net.
long PBFNProcess(void *Reserved1, void *Reserved2, void *Reserved3, void
*Reserved4, void *Reserved5, void *Reserved6, void Reserved7, void
*Reserved8, void *Reserved9)
These are all optional pointers to ... more >>
P/Invoke to Shell32 SHFileOperation
Posted by Brian Reed at 7/26/2004 2:01:01 AM
SHI am trying to use the Shell32 operation FileOperation to send a file to the recycling Bin. I have defined the structure in my class as follows and am hoping my definition is correct. Please let me know if I have it correct:
[StructLayout(LayoutKind.Sequential)]
internal struct _SH... more >>
Internet Explorer Automation
Posted by Adam Stirk at 7/26/2004 1:40:59 AM
Hi,
I have a application that I need to create multiple new "iexplore.exe"
processes (show more than once in taskmanger) and control them using the
shdocvw/mshtml.
I am able control Internet Explorer with instances created with the shdocvw.
e.g.
Activator.CreateInstance(Type.GetTyp... more >>
Best way to implement an object queue for excel interop
Posted by chrismasiero NO[at]SPAM hotmail.com at 7/25/2004 10:38:40 PM
Hi,
I have written a class that intergrates with excel via the com interop
in vb.net.
Everything is working very nicly, no memory leaks and the excel
process comes down gracefully.
The only problem I can see myself facing now is that my web app is
going to be hitting the excel stuff fair... more >>
How to marshal a struct
Posted by Thomas at 7/23/2004 3:01:02 PM
Hi,
I am having difficulty accesing the member data in a struct.
This what I am doing.
In unmanaged code
typedef struct {
char name[20];
int id;
} person;
In C#
[StructLayout(LayoutKind.Sequential)]
public class person
{
[UnmanagedType.ByValTStr, SizeConst=20)]
public string ... more >>
Exception thrown in managed C++ not understood in unmanaged C++
Posted by Mark Traudt at 7/23/2004 6:22:01 AM
The following managed C++ function is called from an unmanaged C++ DLL:
double Divide( double num, double denom )
{
if( denom == 0.0 )
throw new std::exception( "divide by zero" );
return num / denom;
}
The caller calls the function within a C++ try-catch block, with the follow... more >>
How to avoid this problem..
Posted by Henry at 7/22/2004 11:02:12 PM
I have written this code and it worked like a charm without any problem,
DirectoryEntry de = New DirectoryEntry();
de.Path = path;
de.UserName = userName;
de.Password = password;
de.AuthenticationType = AuthenticationType.ServerBind;
de.RefreshCache();
string myName = "Henry";
de.Propert... more >>
.NET and COM Interop
Posted by Stephan Scheidl at 7/22/2004 5:01:35 PM
I have written a class library in c# and want to use it in VB6. Everything
works fine so far but when I try to assign a value (an array of type defined
in c#) to a property definded on the c# side the vb compiler does not want
to compile. Reading access to the property is working.
I added a func... more >>
COM+ and dlls in VB .NET (urgent)
Posted by Reza at 7/22/2004 11:26:51 AM
This looked pretty simple to me at first, and perhaps it still is, but I
havnt been able to find out just what the trick is.
Basically the aim is to compile a dll from VB .NET, which can be read using
previously written Java code (or anywhere else) which reads and executes the
methods within t... more >>
|