I have one C++/CLI project, a GUI application, which is compiled in mixed mode (managed+unmanaged).
Now I want to write a custom user control using C# and compile it to become CSharpA.dll.
my question is: Can this dll be used by my C++/CLI project easily? How would I do that?
...
is there any opensource or free license Control project that has fantasy looking and feel just like DevExpress?
could you give some links.. if it isn't opensource, free licensed DLL is ok.
thanks
...
I currently have a C function that I'd like to use in .NET (C#).
I can see two ways of achieving this:
Compiling it (I think this is possible) with /clr on VC++.NET, having implemented "façade" managed methods that call the C code.
Compiling the C code as a DLL and then making API calls.
What do you find best? How to do the first of...
As in the question Creating simple c++.net wrapper. Step-by-step
I am tring to use C++ classes in .NET
but I am having problems building in Visual Studio (2008).
I have an unmanaged class A (C++ compiled with /clr).
I created a C++/clr class 'Class1' which wraps A and with matching
method delegates to A's methods.
If I include class ...
Update: Albert D. Kallal has kindly started the discussion off, and to get some more opinions I'm adding a bounty.
This is a nontrivial question about maintenance of a legacy application myself and two other developers support. We are not the original developers, and the code base is 300,000 lines of MFC and business logic tightly co...
I have a C++/CLI library that calls many native C++ methods. I have read many threads stating that you should not mix managed and unmanaged code. I couldnt find any that says how to avoid those switches and why it will cause a performance issue. Can someone share best practices.
...
I created A project, and in the A project, i created a Form named bform and a user control named cComtermizedCtrl , and i compiled the project successfully ,but I coundn't find the cComtermizedCtrl control in toolbox. why?
...
Hello,
I have bunch of native C++ objects and classes contains DTL maps, maps of maps and lists and vectors.
I need to call managed C++ functions from C++ native code and need to pass these native objects and STL containers(lists,maps , maps of maps) to C++/CLI. It needs to marshal or some how serialize these objects. How can I do that...
I am writing a C++-CLI library in VS 2008, it highlights only the keywords. I would like to have highlighting for CLR types and the types that I define as well. Tried Tools->Options->Environment->Fonts and Colors doesnt seem to work. Can someone let me know how to do it in VS without using any plugin (happy to use if the plugin is free)....
Hello all,
As the title says, this question is about targeting an older version of the C run time in my mixed-mode C++ dll. I realize that the proper way to do this would be use an older version of Visual c++ but for whatever reason, this is the correct route for us. The dll is built in Visual Studio 2008.
Is there a version of the CR...
Native C++ library that I am using in C++/CLI project raises events giving me results,
If I try to handle the event by extending the unmanaged event, it says the ref class can only extend ref class.
I then tried to create a native event but have manged object inside it to collect the results, but I get the error cannot declare managed...
I'm really frustrated with this one. I'm trying to extend a C# created interface in C++/CLR. The interface has one method and I've declared it in my class, but the compiler keeps telling me that I must still provide an implementation for the interface method. What more can I do? What am I missing!?
Does anyone have any examples of h...
Blob is defined as follows:
unsigned char* blob=new unsigned char[64];
We then try using the immediate window
blob+12
0x084F8854
*blob+12: 0x75 'u'
blob+13
0x084F8855
*blob+13: 0x11 ''
blob+14
0x084F8856
*blob+14: 0x94 ''
blob+12,3
0x084F8854
[0]: 0x75 'u'
[1]: 0x0 ''
[2]: 0x0 ''
Why doesn't blob+12,3 displa...
hello,
I am writing a wrapper for a class written in C++. I must have an template interface class and inherif a wrapper class for a certain type of variable.
this is the code
template<typename T>
public interface class IDataSeriesW
{
property T default [int]
{
T get (int Index);
void set (int Index ,T val);
}
};
publi...
Provide comparison between Array, Link List and Stack data structures
...
The Setup
I have a PDF API which has a native function that is defined below.
typdef void* PDF_DOCUMENT;
unsigned long PDF_GetMetaText(PDF_DOCUMENT document,
const char tag,
void* buffer,
unsigned long bufferlen)
//Calling it "natively" in C++/...
My WPF4 XAML has bindings that reference objects in my C++/CLI .dll. In VS2010 the XAML passes verification, but Blend 4 is very borked. It can't find the namespace within the CLI dll.
In the 2008/.NET 3.5 days I could remove the project reference and replace with the compiled .DLL in Blend and go on my merry way but this doesn't work ...
Hello everyone.
I have a question regarding C++/CLI vs Native C++ speeds. I have written a little test application and I am seeing very surprising results.
It seems that the unmanaged C++/CLI code is significantly slower. Basically I created two console apps. One a standard win32 console app and a CLR console app
Here is the code I di...
{Form constructor}
this->KeyDown += gcnew KeyEventHandler(this, &Form::Form_KeyDown);
...
void Form1::Form_KeyDown(Object^ Sender, KeyEventArgs^ E)
{
MessageBox::Show("Key = " + E->KeyCode.ToString(), "Test");
}
The above event handler never fires. But the form's child controls' handler does. What would be the problem ?
...
Hello,
I need to develop some classes that should be callable from VB6 with Managed C++ (C++/CLI).
I've developed first a sample in C# and I can use the assembly through COM without problems
just using the setting "Register for COM interop" and "Make assembly COM visible" (and using the attribute [ClassInterface(ClassInterfaceType.Aut...