|
The designers in C++/CLI are one or more version behind C#. In .NET 1.0, there was no Windows Forms Designer. If you change the name of the form's class without making other manual changes, the designer will cease to work.
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|
|
Hi George,
I was not aware of that, but then I don't use C++ very much.
Thanks for the info.
Luc Pattyn [Forum Guidelines] [My Articles]
this weeks tips:
- make Visual display line numbers: Tools/Options/TextEditor/...
- show exceptions with ToString() to see all information
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
BuckBrown wrote: I don't want to recreate the 50 controls on the Form
Perhaps you shouldn't develop a form with 50 controls on it?
|
|
|
|
|
how do a person run an outside exe(application) inside a C++ form?
like making is a child thread of that form?
thanks in advance
|
|
|
|
|
I use System::Diagnostics::ProcessStartInfo. Ex below
<code>Diagnostics::ProcessStartInfo ^pInfo;
if ( String::IsNullOrEmpty(SoundString) == false )
{
if ( System::IO::File::Exists(SoundString) == true )
{
pInfo = gcnew Diagnostics::ProcessStartInfo();
pInfo->Verb = "play";
pInfo->FileName = SoundString;
pInfo->CreateNoWindow = true;
pInfo->UseShellExecute = false;
Diagnostics::Process::Start(pInfo);
}
else
LogDebugInfo(String::Format(L"SoundString file {0} does not exists", SoundString));
}
else
{
LogDebugInfo(L"SoundString string was empty");
} </code>
Programmer
Glenn Earl Graham
Austin, TX
|
|
|
|
|
i need a project on c++. can somebody suggest me a web site from where i can avail a good one.
|
|
|
|
|
|
|
boost !
http://www.boost.org
|
|
|
|
|
I am trying to learn C++. I am trying to write a program that will allow a 5 digit number to be input and then print the digits seperated by three spaces. I have the following, but when I try to compille it I am getting an error. I would defenitely appreciate any help.
#include <iostream>
using std::cout;
using std::cin;
using std::endl;
int main();
{
a = number1 / g%;
b = a / g%;
c = b/ g%;
d= c/ g%;
e = d/g;
g = 10
cout << "Enter a five digit number : ";
cin >> number 1;
cout << "a b c d e" << endl;
system("PAUSE");
return 0;
}
keep getting the following errors, when trying to compile the program
How would I fix this?
expected ';' unqualified-id before ‘{‘ token
expected ’;’ or ‘;’ before ‘{‘ token
jada 23
|
|
|
|
|
Hi,
error messages normally contain line numbers, and Visual and other IDEs are capable of
displaying line numbers in the left margin, so how hard can it be?
seems like you add and forget to add semi-colons...
Luc Pattyn [Forum Guidelines] [My Articles]
this weeks tips:
- make Visual display line numbers: Tools/Options/TextEditor/...
- show exceptions with ToString() to see all information
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
Seems tough if you have never written a progrma before.
the line error is for line 8.
I am wating to understandd why I am getting the error.
jada 23
|
|
|
|
|
By the time you posted this, I had explained it.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
This is the managed C++ forum, the visual C++ forum was the right place for this question. You may think I'm a Nazi for saying so, truth is, a lot more people will see your question ( and therefore can help you ) if you post in the right place.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
jada0923 wrote: int main();
Oh, and you didn't forget a ;. the ; in this line is in error. It means you're announcing your intent to write a main method, elsewhere, and everything that follows is therefore a method without a name, which is the error.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Thanks for the tip. I will post in the correct place in the future. This shows how new this is to me.
jada 23
|
|
|
|
|
Sure - like I said, just trying to help you get better help here in the future. It's not a big deal.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
hi all... i am using ICC_BAR_CLASSES to initialize controls to create toolbar....
but i am getting one error
[linker error] undefined reference to `InitCommonControlsEx@4'
code creating problem is...
//-----------------------------------
INITCOMMONCONTROLSEX InitCtrlEx;
InitCtrlEx.dwSize = sizeof(INITCOMMONCONTROLSEX);
InitCtrlEx.dwICC = ICC_BAR_CLASSES;
InitCommonControlsEx(&InitCtrlEx);
//-----------------------------------
As structure INITCOMMONCONTROLSEX and function InitCommonControlsEx(..) are defined in commctrl.h i included this in my program.....earlier INITCOMMONCONTROLSEX this was also giving same error then i opened the header file commctrl.h and there i found these lines
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
typedef struct tagINITCOMMONCONTROLSEX {
DWORD dwSize;
DWORD dwICC;
} INITCOMMONCONTROLSEX,*LPINITCOMMONCONTROLSEX;
#endif
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
BOOL WINAPI InitCommonControlsEx(LPINITCOMMONCONTROLSEX);
#endif
//--------------------------------------
so in my program before header file in included
#ifdef _WIN32_IE
#undef
#endif
#define _WIN32_IE 0x501
and also
#ifdef _WIN32_WINNT
#undef
#endif
#define _WIN32_WINNT 0x501
now INITCOMMONCONTROLSEX is working fine... but i am getting error with InitCommonControlsEx(...)
error is
[linker error] undefined reference to `InitCommonControlsEx@4'
i am using Dev-C++ 4.9.9.2 compiler
can someone suggest me something...
thanx in advance....
bye have a nice day.....
|
|
|
|
|
hey its working now...
what u need to do is just link library....
in case of devc++ ists libcomctrl32.a
bye have a nice day.....
|
|
|
|
|
hi all... i am using ICC_BAR_CLASSES to initialize controls to create toolbar....
but i am getting one error
[linker error] undefined reference to `InitCommonControlsEx@4'
code creating problem is...
//-----------------------------------
INITCOMMONCONTROLSEX InitCtrlEx;
InitCtrlEx.dwSize = sizeof(INITCOMMONCONTROLSEX);
InitCtrlEx.dwICC = ICC_BAR_CLASSES;
InitCommonControlsEx(&InitCtrlEx);
//-----------------------------------
As structure INITCOMMONCONTROLSEX and function InitCommonControlsEx(..) are defined in commctrl.h i included this in my program.....earlier INITCOMMONCONTROLSEX this was also giving same error then i opened the header file commctrl.h and there i found these lines
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
typedef struct tagINITCOMMONCONTROLSEX {
DWORD dwSize;
DWORD dwICC;
} INITCOMMONCONTROLSEX,*LPINITCOMMONCONTROLSEX;
#endif
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
BOOL WINAPI InitCommonControlsEx(LPINITCOMMONCONTROLSEX);
#endif
//--------------------------------------
so in my program before header file in included
#ifdef _WIN32_IE
#undef
#endif
#define _WIN32_IE 0x501
and also
#ifdef _WIN32_WINNT
#undef
#endif
#define _WIN32_WINNT 0x501
now INITCOMMONCONTROLSEX is working fine... but i am getting error with InitCommonControlsEx(...)
error is
[linker error] undefined reference to `InitCommonControlsEx@4'
i am using Dev-C++ 4.9.9.2 compiler
can someone suggest me something...
thanx in advance....
bye have a nice day.....
|
|
|
|
|
I'm taking my first steps in .NET and I have some legacy code in C++ that I need to use in .NET code. Any thumb rules or generic way of doing that?
|
|
|
|
|
dedil wrote: I'm taking my first steps in .NET
I would argue that you are skipping the first steps in introducing yourself to .NET and jumping right into a project. IMHO that is not advisable.
|
|
|
|
|
I agree, but it's out of my hands.
Regarding this specific question, the .NET form is not an issue; It should be a blank that just calls a method from a class in the legacy code.
|
|
|
|
|
dedil wrote: that just calls a method
Nice ASSUMPTION? What institution did you study at? I want to make sure to warn people away from it.
|
|
|
|
|