|
What is the ways to use vb and c# code in vc++.net application program? Thx.
|
|
|
|
|
Make an assembly and then reference it from another project.
led mike
|
|
|
|
|
What is the assembly you mean? Is it a module(.def) or dll?
|
|
|
|
|
|
Member 4542272 wrote: Can somebody tell me step by step how to build an on-screen keyboard or what should i learn to make it?
I don't understand. Certainly you know how to make a button with a single letter for the text label right?
led mike
|
|
|
|
|
I have connected my application with the Microsoft Access database, via ADO.NET OLEDB. I can insert and edit data, but I have no idea how to search the database, or just to select some record and to insert that into some string.
Here is a example for inserting a new record
String ^strData = "INSERT INTO Continents VALUES('Abcd',12345678,87654321);";<br />
OleDbCommand ^cmdDatabase=gcnew OleDbCommand(strData, oleDbConnection1);<br />
cmdDatabase->ExecuteNonQuery();
Please help.
|
|
|
|
|
Select, Insert, Search ,.... are all SQL commands. Please try a book about Sql.
Sourie
|
|
|
|
|
Hi i'm wondering if the console could be viewed in windows forms?
I'm not sure what the line would be to view the console.
|
|
|
|
|
gman2008 wrote: The code that connects to the server was originally a console application and I have incorporated that code into the interface.
gman2008 wrote: I'm just not sure why the console is not showing up.
Because there isn't one since you just took the code and put it in a Windows Forms application.
gman2008 wrote: I don't want this information to be displayed to the user on the form but as a background job in a windows console.
Ok but it doesn't need to be a Console. You can just create a 2nd form and display it there. David Crow has sort of explained that already without the 2nd form part. Based on your apparent beginners level you will likely have some difficulty doing this in any way you attempt to do it. You probably want to do some reading[^] on creating multiple forms, particularly Modeless forms.
led mike
|
|
|
|
|
First off - a bit of background:
For a project i'm working on I need to distribute objects to groups of users based on a number of different algorithms, my idea was to store the state for each algorithm inside their respective functions using static variables. This was to be done in C# until I realised C# doesn't support this functionality but i know C++ does. Sooo ...
Does Managed C++ support static variables inside functions in the same way as standard C++ does or is it a limitation of the CLR that means this functionality isn't available in .NET?
Thanks
Richard
Richard Green
modified on Thursday, January 24, 2008 7:43:20 AM
|
|
|
|
|
Never mind, I refactored my code so each algorithm is inside its own class and can now use static class members to store current state.
Richard
Richard Green
|
|
|
|
|
That is the right way to do it, whatever language you choose. State belongs to an object,
not to a function.
Luc Pattyn [Forum Guidelines] [My Articles]
This month's tips:
- before you ask a question here, search CodeProject, then Google;
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get;
- use PRE tags to preserve formatting when showing multi-line code snippets.
|
|
|
|
|
Yeah, it was just one of those mornings eariler - took a 5min break came back and realised I was going about it backwards
Richard Green
|
|
|
|
|
I want to develop a c++ application through which i can activate and deactivat my network connection in Fedora.
Thanks in advance
|
|
|
|
|
tassadaque wrote: I want to develop a c++ application
A .NET application? That's what this forum is for. If not you are in the wrong forum.
led mike
|
|
|
|
|
Hi,
I am a "hobby" programmer with a lot of familiarity with pre-.NET C++ programming in Windows, but not too much with .NET. I've written a Form based Windows application and want to set it up so that the app monitors changes to clipboard data. Therefore, I need to call the Win32 functions SetClipBoardViewer, etc. (Or is there another way to do this in .NET that I haven't found)?
As far as I can tell, I need to use the PInvoke mechanism with declarations something like:
[DllImport("User32")]
static int SetClipboardViewer(int hWndNewViewer);
(I would think these should be HWND's, but the above is what I found.)
My problem is that I don't know the correct declarations for these functions, and I don't know how to set up the calls to them. I found an example for C# that shows how to do the whole process of setting up a clipboard monitoring application, but I really want to learn how to do this in C++.
Any help would be appreciated!
Thanks,
Tom
|
|
|
|
|
|
largenqcd wrote: As far as I can tell, I need to use the PInvoke mechanism
Not if you are using C++/CLI. You can mix native code with managed code. There are some caveats of course. See the Introductory articles here on CodeProject for C++/CLI developers. They should clear much of your questions up.
led mike
|
|
|
|
|
The problem I’m having is when the user selects a menu item it should execute code in protocol_test.cpp
In Windows Forms the code for the interface is written in a header file “frmIndex.h”
<br />
<br />
private: System::Void pANGUToolStripMenuItem_Click(System::Object^ sender, System::EventArgs^ e) {<br />
<br />
pangu_server();<br />
<br />
int *pan;<br />
class protocol_test;<br />
<br />
pan::pangu_server();<br />
<br />
}<br />
The protocol_test.cpp was part of a console program which connects to server. This class had a main in it but I renamed this to int pangu_server().
The protocol_test.cpp does not have a header file but when I create a header file for it I still can the same error.
Even I have even created a simply class and header that would just write to the console which doesn’t work.
|
|
|
|
|
How can i change the system date style formate through code.
I have a project when it starts it compare the current date withe the condition date is the date formate is wrong it give error plz help me out.
|
|
|
|
|
Don't cross post, it's considered rude
|
|
|
|
|
I post the same question at C# and C++ community, because may be C++ developer answer my question.
I maximum i post question at C# post.
What make you rude plz explan
|
|
|
|
|
If you double post, you may get the same answer in two or more locations by different people. So, you are hogging these people time and effort from other posters who want their question answered also. You are the rude person!
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|
|
Hey i'm new to visual C++ and i'm using windows forms but that forum doesn't seem to get answered.
I'm wondering how to call a method from a class in the form1.h?
so for example:
form1.h
private: System::Void testToolStripMenuItem_Click(System::Object^ sender, System::EventArgs^ e)
//Not sure how to call the test method
{
Class test
void test()
{
//Code here
}
|
|
|
|
|
newkid wrote: that forum doesn't seem to get answered
Sure people answer in that forum. You have to give them time.
"I guess it's what separates the professionals from the drag and drop, girly wirly, namby pamby, wishy washy, can't code for crap types." - Pete O'Hanlon
|
|
|
|