all groups > dotnet interop > february 2004 > threads for february 8 - 14, 2004
Filter by week: 1 2 3 4
API Help please - How do I find the owner of a file or folder using
Posted by John Regan at 2/13/2004 1:23:31 PM
Hello All
I am trying to find the owner of a file or folder on our network (Windows
2000 Server) using VB.Net and/or API. so I can search for Folders that don't
follow our company's specified folder structure and naming conventions and
then send a Net send message to those users telling them t... more >>
Excel on a Form?
Posted by Roman at 2/13/2004 12:04:46 PM
Need to dispaly an excel file on a windows form. Is there
any control that does it?... more >>
Outlook Automation using VB.Net
Posted by Leo at 2/13/2004 7:56:05 AM
Hello and thanks for the Help in advance
I am trying to move code from VB to VB.Net and having some trouble with the Restrict method
I have attached the VB6 code as well as the VB.Net code I have started
What I am trying to do is I have a program which displays information based on a Job. On... more >>
How do I make a C# class available to VBScript?
Posted by johan de smedt at 2/13/2004 5:43:45 AM
I want to make a managed (C#) class available for VBScript
developpers.
After generating the dll, I used regasm with the /tlb
option. I also registered the (strong named) dll with
gacutil.
The registry shows may class.
However, when trying to use that dll in VBScript:
- CreateObject:... more >>
OLE Container
Posted by Yannick Desjardins at 2/12/2004 10:17:36 AM
Is there a way to bring the old VB6 OLE Container in the .Net world using
COM Interop? Using the web browser control is not an option for us, since
most of our OLE object are saved and loaded from a database.
... more >>
delegates are always stdcall?
Posted by teds NO[at]SPAM intex.com at 2/12/2004 9:16:59 AM
Hi,
My C function takes a CDecl function pointer. I am using delegates
as my function pointer and it seems that this requires that my
C function pointer be declared as stdcall. Is this correct? Or is
there a way to change the calling convention of the delegate?
Thanks,
Ted... more >>
Exposing VB.NET object to COM in the old C format using Interop
Posted by Doug at 2/12/2004 6:21:08 AM
I need to make the VB.NET object callable from a program called Trade Station. It is a stock analysis and trading tool that is very importiant to my company. They have a scripting languge called easy language that is built into the system. It is supposed to be capable of extending itself by calli... more >>
Return an array of bytes to VB6 caller from C#?
Posted by Bert Hyman at 2/12/2004 6:03:34 AM
I've managed to get this far in life without learning anything about
COM or VB6. I'm sure the technique for doing what I need is well
known, but I apparently don't know the right words to use when
framing a Google search.
I've got an MMC snapin written in VB6 which uses a number of dotNet
ob... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Namespace " already contains a definition for 'Word' ????
Posted by BBFrost at 2/11/2004 4:17:07 PM
This is NOT my month. Everywhere I turn our C# apps are tossing hair balls!
In this case I was cleaning up my development machine and dumped an old
version of the Net Framework and reinstalled the latest version of Net
Framework 1.1 because of another problem.
Now the word interop program I... more >>
unsafe code
Posted by XingZheng at 2/11/2004 2:33:42 PM
Hi
How to set size of array in C#.
In C++
public class MyArray
{
public int a[3];
public int b[3];
}
MyArray* a = new MyArray();
In C#, I get the pointer of the variable that I allocate in C++.
public struct MyArray
{
public int[] a; //I Can't set the size of array. C... more >>
interop without tlbimp
Posted by Chris Brooksbank at 2/11/2004 12:42:11 PM
I want to read the method names from a typelibrary.
I can already do this but I need to manually run tlbimp on the win32 exe
which contains the type library.
Then I add reference to my VS project then I can :
methodNameList = new ArrayList();
Type AppServerType =typeof(Skycssrv.SkynetCSApplic... more >>
DllImport into C#
Posted by Tim Mulholland at 2/11/2004 11:45:24 AM
Whats the correct C# datatype (or marshalling function or something) to use
when you're importing a function that has a signature similar to
char* FuncA(char c[])
?
Assuming you know that both the parameter for the function and the return
value are c-style strings?
Thanks in advance!
... more >>
unsafe code
Posted by XingZheng at 2/11/2004 10:50:49 AM
Hi
I get an error "Cannot take the address or size of a variable of a managed
type" when I try to get an object from IntPtr. How can I fix this error.(I
don't want to change Example from class to struct)
public class Example
{
public int index;
}
public class ExampleApp
{
pu... more >>
Excel won't Close - Common issue with a twist
Posted by mgorman NO[at]SPAM pgtv.com at 2/11/2004 6:54:02 AM
Background: I wrote a VB .NET class that can be passed a form. Any
datagrids on the passed in form are listed to the user and the user
can select which ones they want exported to Excel. Each grid is
exported to a different worksheet within the same workbook.
The Excel file is created succe... more >>
pInvoke
Posted by XingZheng at 2/10/2004 8:56:56 AM
Hi
I'd like to convert C++ data type to .Net data type. In C# I use pInvoke to
call a method in C++ to get an instance of Example class. How to convert
Example class in C++ to C#.
In C++
public class Example
{
public:
float fCenter[4][2];
}
Thanks
XingZheng
... more >>
why do these 2 ways of invoking an external C function work?
Posted by teds NO[at]SPAM intex.com at 2/10/2004 7:23:16 AM
Hi,
I'm using P/Invoke to call a C function from a DLL in my C# class.
My C function is this
char * icmo_version_chk( const char *version )
I've tested both these declarations and both work.
public static extern IntPtr icmo_version_chk(
[MarshalAs(UnmanagedType.LPS... more >>
Forcing a .NET obj exposed as COM to use StdCall instead of CdCall
Posted by Doug at 2/10/2004 6:21:07 AM
Does anyone know how to force interop to use a stdcall interface on the COM objects it creates instead of the cdcall interface that is standard
This is very importiant for my project. I need to reference a VB.NET based interop COM object from an outside program. The program will only interact wi... more >>
How do I interop this?
Posted by Wei Wang at 2/10/2004 12:07:27 AM
I need to control a PCI device which has an FPGA on it. The driver API takes
this really complicated structure:
#pragma pack(1)
struct COMMAND_BLOCK
{
unsigned char command;
unsigned char byte2;
void* pCommandData;
int commandDataSize;
void* pResultData;
int resul... more >>
Programming OLE Structured Storage in .Net
Posted by rifferte NO[at]SPAM netscape.net at 2/9/2004 7:09:04 PM
I was hoping someone out there can point me in the right direction.
I am trying to develop a .Net component that can read OLE Structured
Files. I have perused the MSDN documentation - but it is too hard on
facts and little on explanation.
Does any one recommend a site or book that explains t... more >>
Replacing merge fields in headers/footers
Posted by AP at 2/9/2004 5:21:02 PM
Hi,
I'm trying to programmatically update merge fields in headers/footers of a
word document. I iterate through the merge fields in the header/footer, and
set the result text to the text I want, then save the document, but when I
open it the merge field does not appear updated. If anyone can s... more >>
Marshaling a HBITMAP...
Posted by Paul Colton at 2/9/2004 5:03:33 PM
Is it enough to use: bitmap.GetHbitmap() to marshal a .NET bitmap into a
native HBITMAP (via the returned IntPtr) or do I need to do more? It doesn't
seem to be working.
Paul
... more >>
"advanced"? interop
Posted by Daniel Jin at 2/9/2004 4:01:10 PM
how to interop this
NTSTATUS IoGetDeviceObjectPointer
IN PUNICODE_STRING ObjectName
IN ACCESS_MASK DesiredAccess
OUT PFILE_OBJECT *FileObject
OUT PDEVICE_OBJECT *DeviceObjec
)
the problem is PFILE_OBJECT* and PDEVICE_OBJECT*. I don't want to declare them in C# becau... more >>
ADO Recordset, .NET component, and function/sub -- what's going on??
Posted by RN at 2/9/2004 1:49:23 PM
I'm having problems figuring this out...I have a .NET component that I am
passing a recordset to from plain-vanilla ASP code. The component sits in
the GAC.
The component has 2 methods, a Function and a Sub
Sub ExportRecordset(ByVal rst As Recordset)
Function ExportRecordset2(ByVal rst As Re... more >>
How to create COM wrapper for IActiveDesktop
Posted by Simon at 2/9/2004 12:57:19 PM
Hi
When I use tlbimp on Shell32.dll there is no reference to IActiveDesktop or
to the CoClass which implements this interface. Can anyone tell me why this
should be the case? Will I have to hand-craft the COM wrapper or is there a
quicker way?
Many thanks
Simon
... more >>
from COM to .NET
Posted by jano at 2/9/2004 12:46:07 PM
Hi all
My company are slowly migrating from vb6/com environment to a .net/web service environment. At the moment we have a financial system running on our intranet that allows user to request and retrieve reports- we have a .Net web service that retrieves these requests and passes them on to a COM... more >>
VB6 Interface implemented in C#
Posted by Raghu at 2/9/2004 11:52:08 AM
I need to implement an interface that is created with VB6 in my C#
component. It is not an option to redefine the interface in C#.
Will be there be any threading issues associated with VB6 in my C#
component?
Thanks.
Raghu/..
... more >>
How to find the startup folder for an Shared Add-In?
Posted by Peter at 2/9/2004 10:56:09 AM
Hello
Thanks for reviewing my question. I have written a C# shared Add-in program for Excel. At run-time, I would like to know how can the shared Add-in find out which directory it is in? My goal is to have a configuration file in the same location as my Add-in. I know in Win32 you can use Get... more >>
How can I use a C# Dll in old-fashioned ASP Sites...
Posted by Mirco Kaffsach at 2/9/2004 10:48:40 AM
Hi @all,
I've written a C# DLL to connect to a MS SQL DB.
For migration purposes I have to use this C# DLL in my old-fashioned ASP
WebSites.
Can you give me a detailed description how to make this C# DLL usable in old
ASP Sites.
Thanks in advanced...
Mirco
... more >>
Setup Project
Posted by Stefan at 2/9/2004 10:26:57 AM
I have a basic question about deploying my .NET dll for
COM. My project generates the dll that is deployed on the
user's machine using a setup application. I have a couple
of questions:
1. On a test machine with the .NET framework installed,
after the installation, I had to run the following:... more >>
Call void* C func from C#...
Posted by Paul Colton at 2/9/2004 9:34:25 AM
I have a function that needs to call down into a C .dll and have that C code
change the values of my C# struct. I had this, but it doesn't work:
public static extern int my_func(string guid, string message,
[MarshalAs(UnmanagedType.AsAny)]object data);
I then tried this, but this doesn't work ... more >>
Opening word document
Posted by John at 2/8/2004 7:51:45 PM
Hi
I am using the code given at the end to open a word document from within
vb.net. It works fine the first time but the second time I get the error;
Unhandled Exception: System.Runtime.InteropServices.COMException
(0x800706BA): The RPC server is unavailable.
at Word.ApplicationClass.get_Do... more >>
Calling LogonUser() and CreateProcessAsUser() from a service
Posted by C Kindel at 2/8/2004 3:11:54 AM
I am writing a Service (in C#) that can lanuch processes in the interactive
desktop of the currently logged on user. I almost have it working, but even
after reading all the results of a gazillion google searches I'm still
stumped. Hopefully someone can point out what I'm doing wrong.
If the p... more >>
|