|
I saw this sample in also MSDN and tried many times, but compiler says AboutForm and f are unknown identifiers. Is there anything else i missed ?
|
|
|
|
|
I said 'if your about form is called 'AboutForm'. I have no idea what it's called, and obviously it needs to be in scope where you're trying to call it.
If you don't understand these things, you should stop playing with Managed C++, and also with any sort of GUI code, and work through a basic C++ book.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Of course, i modified the codes u send with respect to my Form's name, but there is still same error... Unknown identifiers...
|
|
|
|
|
Then your problem is probably to do with your #include settings. It's impossible to say, based on what you've told me, I'd need to see the code.
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
I am trying to run this packet logging/sending program for a game; which is coded within the Microsoft Visual Studio 6.0 C++ enviorment, however when I try executing it says's "This application has failed to start because the application is incorrect. Reinstalling the application may fix this problem.” any idea's?
-h7h7
|
|
|
|
|
h7h7 wrote: which is coded within the Microsoft Visual Studio 6.0 C++ enviorment,
This means it was not written using Managed C++, and you're in the wrong forum
When you find the right one, no-one can help you based on what you've said, you need to set breakpoints or otherwise work out where the program is crashing, so we can see some code to comment on.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Can anyone please recommend a book that is a good guide for beginners to the STL Library. I purchased one book that was supposedly for beginners, the C++ Standard Template Library, and it is so confusing i cant understand it. I would appreciate someone's help with this.
|
|
|
|
|
The book you've bought is the standard reference on the topic. However, there are lots of more elementary texts on the topic. There are also heaps of tutorials on the web ( I wrote a few on this site ). Work through the stuff on CP, then go back to your book.
And, in future, managed C++ means .NET C++, which does not include STL. Use the Visual C++ forum, if you're not using Managed C++ or C++/CLI.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
thanks for the advice. Can you please reference an elementary text on the stl library. I cant seem to find a good tutorial on the web. So there are some on this sight? I would appreciate any help you can give me. Thanks much
Seth Isaacks
|
|
|
|
|
|
Is there any way I coud manage a connection to an mdb database without using ODBC?Because I'm making a small program to store info like phone numbers and such, but I would rather not having to rely on the user having the ODBC for mdb databases, and I've been told that I can manage the connection by only adding a few things to the project, and no need to use ODBC.
I would appreciate any help you could give me.
|
|
|
|
|
Well, as you're asking in the managed C++ forum, I guess you can use the .NET framework classes for database connections. If you posted in the wrong forum, then I'm not sure what your options are, but you should move the question where it belongs, in order to find out.
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
No, I actually don't use .NET, I was told that I could access an mdb db from my app by only adding some library to it, and I'm pretty sure it was not a .NET library...
|
|
|
|
|
can anyone walk me through the sequence of events in the following code execution? thank you.
main()
{
int x=20,y=35;
x=y++ + x++;
y= ++y + ++x;
printf(“%d%d\n”,x,y);
in my guess this is what happens...
x = 20; y = 35;
x = 35 + 20; y = 35+1;
x = 35 + (20+1);
x = 56; y = 36;
y = 37 + 57; x = 57;
x = 57; y = 94;
so output is: 5794
i got it printing 5794 but is my analysis correct? thank you
|
|
|
|
|
As i see
x=20; y=35;
x = (35+1) + (20+1) // y has nev value 36
x = 57
y = (36+1) + (57+1);
y = 95;
y++ // this is add 1 to y;
++y // this 1+y, but doesn't increase y for 1.
ps: You are posting in wrong forum, you shoud Visual c++
|
|
|
|
|
bsaksida wrote: ++y // this 1+y, but doesn't increase y for 1.
|
|
|
|
|
int y=1;
x = ++y; //x is 2, y is 1;
x = y++//x is 2, y is 2;
y++; // increase y by 1
|
|
|
|
|
bsaksida wrote: x = ++y; //x is 2, y is 1;
No ! y is 2 here,too. And 2 will be assigned to x.
bsaksida wrote: y++; // increase y by 1
y will become 3 here.
|
|
|
|
|
j11Software wrote: x=y++ + x++;
Here, x(20) is added to y(35) and assigned to x(55). And then incremented(++) with 1 ie.e x is now 56. Y is incremented to 1. Y is 36 now.
j11Software wrote: y= ++y + ++x;
x(56) is incremented for 1 now x is 57. y is incremented for 1. Y is 37 now. Both are added to eqate to y. i.e. y is 94 now.
|
|
|
|
|
Very close.
This is the C equivalent of what the Microsoft compiler produces:
x = 20; y = 35;
x = y + x; // 35 + 20 = 55
x = x+1; // 56
y = y+1; // 36
y = y+1; // 37
x = x+1; // 57
y = y + x; // 94
I would like to note that you should not write code like "y = y++ + x++" because the results are undefined by the language. That is the results of a statement like "x = x++" is considered undefined and it is up to the compiler vendor to decide how to implement it.
The following C equivalent code may be produce by a different compiler:
x = 20; y = 35;
tx = x+1; // 21
ty = y+1; // 36
x = y + x; // 35 + 20 = 55
x = tx; // 21 (unexpected result)
y = ty; // 36
y = y+1; // 37
x = x+1; // 22
y = y + x; // 59
One other thing I would like to point out is that other languages, that have the '++' operator, interpret it differently.
For furthur information, try searching the Net for "i=i++".
INTP
"Program testing can be used to show the presence of bugs, but never to show their absence."Edsger Dijkstra
|
|
|
|
|
The postfix operator returns the value before the operation, if i == 20, i++ returns 20, ++i return 21.
x=y++ + x++;
y= ++y + ++x;
This sort of code is an interesting exercise, but you should never write code that looks like this, in the real world.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Hello ,
I have written a program in VC++.Net 2003 on a laptop,
when I try to run the setup on a desktop, there is a change in the
forms size, location (appearence settings).
For e.g. On the laptop the form appears to be full screen,
but on a desktop the form is smaller.
How do I make sure , that the settings are the same independent of
the machine.
Thanks in advance for your help.
Minad
|
|
|
|
|
Users control the screen resolution as part of their "Display settings". Your form is the same "pixel size" on both machines.
led mike
|
|
|
|
|
hi all,
anybody tell me where i can find readymade library for maintaing log?
payable or not doesn't matter.
please,if anybody idea share with me.
thanks & regards
bankey khandelwal
|
|
|
|
|