|
Hi all,
i have a DLL named as "AxInterop.ECLActiveX.dll" but i dont know is it "activex control" or "simple com DLL".
I have to use this DLL in my application which is console base application in managed code.
this DLL export some function like "compreesFile" etc.
can anybody tell me how can call function from that DLL.
please reply me.
thanks
bankey
|
|
|
|
|
Hi,
Just read 'Interop Marshaling' on MSDN.
Regards
|
|
|
|
|
How do i gcnew a arraylist to array? I have initialised the variables under the ref form function and i need to create a method to call and new the variable to array and display them in a treeview control. How Do I Need To Do???PLS HELP!!!
Sample coding is below of what i have done so far. Basically i need to drag drop a icon to panel and once it displays there, the trewview control will show. In this Case i haf 1 base Station which is the parent and many subscriber station which is the child. For 1 base station there will be many Subscriber station. So i need to pass in the string variable.
public ref class Form1 : public System::Windows::Forms::Form
{
public:
Form1(void)
{
InitializeComponent();
baseStationNode = gcnew ArrayList();
baseStationNode->Add(baseStationNode);
subscriberNode = gcnew ArrayList();
subscriberNode->Add(subscriberNode);
//
//TODO: Add the constructor code here
//
}
protected:
private: ArrayList^ subscriberNode;
private: ArrayList^ baseStationNode;
private:
///
/// Required designer variable.
///
System::ComponentModel::Container ^components;
//TreeNode^ baseNode;
//array<treenode^>^ subNodeArr;
//static int count=0;
#pragma endregion
private: System::Void add_baseNode()
{
baseStationNode = gcnew array();
// baseNode = gcnew TreeNode(String::Format("Base Station"));
// treeView1->Nodes->Add(baseNode);
}
Pls Help Me check and gif me a sample codes of where i need to add in and how and y. THANKS A LOT!
|
|
|
|
|
I dont really understand what you are attempting to do but your code is a bit all over the show
fairose wrote: baseStationNode = gcnew ArrayList();
baseStationNode->Add(baseStationNode);
What is this supposed to be doing?
System.IO.Path.IsPathRooted() does not behave as I would expect
|
|
|
|
|
This part is that i am trying to initialise a variable call baseStationNode into the arraylist and newing it.
private: ArrayList^ baseStationNode;
this is where i set the the variable to be a arraylist.
|
|
|
|
|
pleaaaaaase, Read the posting guidelines[^], then edit your message, and place your code into <pre> tags. this will format your post regarding Codeproject's style sheet.
thanks.
|
|
|
|
|
To SendMessage how to send a string as argument
and how to recieve and display that string
lets say in a edit box i have some text ABCD , i want to capture this text to a CString and pass this CString to Sendmessage as Wparam parameter to other remote process(iam using sockets for remote connevtion). and at remote Application i will capture this wparam and display the message
how to do this using send message.
Thanks in advance
abhi
|
|
|
|
|
abhiramsss wrote: and pass this CString to Sendmessage as Wparam parameter to other remote process(iam using sockets for remote connevtion).
umm you don't use SendMessage to communicate to another process using a socket.
led mike
|
|
|
|
|
I am confused that why we have to pass a reference of same class type into a copy constructor? I searched a lot but i am not able to find out the exact answer.So,plz if anybody can forward me the relevant answer of this question then plz forward it as soon as possible.Please specify the reason.
thanks..
|
|
|
|
|
When you are copying objects, you need a source and a destination. The destination or "new" object must be able to access the data of the source object to copy its data and perform any necessary resource allocation.
ref class Foo
{
int value;
String ^string;
public:
Foo() {}
Foo(const Foo %f)
{
value = f.value;
string = f.string;
}
...
};
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|
|
He is interested in knowing why need of passing parameter as reference.
|
|
|
|
|
|
Thanks!
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|
|
|
Because that's just how the copy constructor works. The parameter has to be a reference. If it weren't a reference, how could you make a copy of the input object? (You don't have a copy constructor yet, you're writing it!)
|
|
|
|
|
I am creating a console app that starts NOTEPAD.EXE but then needs to emulate the user accessing the menu.
I have started the process by using
Process::Start("NOTEPAD.EXE");
Now I need to simulate a user pressing 'Alt F' to access the file menu - how do I achieve this ??
Pete
|
|
|
|
|
Off the top of my head....
Use the non static version of Process::Start() so you have a Process object
Call Process.MainWindowHandle() to get a handle to the window
Then use Win32 functions or MFC to send messages to the window using the handle
System.IO.Path.IsPathRooted() does not behave as I would expect
|
|
|
|
|
Thanks Josh,
See how we go.....
Pete
|
|
|
|
|
I woud like to have an example, how to encryipt String into md5 hash.
Coud md5 encryption produce same hash as md5 from php?
Thanks in advance
|
|
|
|
|
Look up MD5CryptoServiceProvider on MSDN.
Here's some sample code from MSDN :-
private:
array<Byte>^ MD5hash( array<Byte>^data )
{
MD5^ md5 = gcnew MD5CryptoServiceProvider;
array<Byte>^ result = md5->ComputeHash( data );
return result;
}
|
|
|
|
|
I already saw it, but i wan't to hash my String (password). I can't use Byte as an imput.
this is php example:
<?php
$string = "secret";
echo md5($string);
?>
the output would be: 5ebe2294ecd0e0f08eab7690d2a6ee69
how can i achive this in c++/cli?
|
|
|
|
|
Found an article abaout it here on CP:
http://www.codeproject.com/dotnet/MD5FunctionPHP.asp
Now it works, perfectly
|
|
|
|
|
Hi All,
My following code shows how I am starting a process, in this case it's NotePad.
Process^ myProcess;
myProcess = Process::Start("Notepad.exe");
How do I then control the Window State - for example, if I want to Minimize the window, how is this achieved ?
Pete
|
|
|
|
|
Use this overload :-
Process^ Start (ProcessStartInfo^ startInfo)
Set the WindowStyle property of the ProcessStartInfo object to ProcessWindowStyle::Minimized
|
|
|
|
|
G'Day Nish,
Thanks for that - all sorted out now.
Pete
|
|
|
|