User Profile
Collapse
-
Well, I'm supposed to be getting some upgrades on my computer in the next week or two (new hard drive, more ram, and a new processor), so I'll probably just let it be for now since I'll have to install it on the new hard drive anyways. -
The execution window is definitely not open, a lot of the times that it's happened was when I just wanted to build my current code to make sure there aren't any compile/linker errors and I don't run it at all and I still get the error (it also happens on the first build of the program when there wasn't even a previous execution window). And the project has not been moved at all since creation. When the problem kept starting up, I created a new empty...Leave a comment:
-
Strange Error Message, help please
Ok, First of all, I'm using Microsoft Visual Studio 2005, and I've been getting this problem when making c++ projects starting from an empty project. I haven't tried other project types yet, so I don't know if this is affecting them as well.
Anyways, this problem is not isolated to any individual program, it seems to just happen to all of them, some of the time. This is the error message I've been getting, it pops up after the "Embedding... -
The main reason I was going to re-create it was because I'm not entirely familiar with browsing through the various namespaces to find things and figuring out how they work, and what I needed was relatively simple. So thanks for pointing me in the direction of where to find the type of structure I needed.
However, in my attempt at making my own, I tried to use the delete statement on a handle, but it just gave me a compiler error that...Leave a comment:
-
Parentheses are only needed if you need to override the normal order of operations. Multiplication and division have higher priority than addition and subtraction, so
P = w + x/y - z
is the same as
P = w + (x/y) - z
which is the same as
P = (w + (x/y)) - z
Basically, without any parenthesis, the program will first divide x by y, then it will add that to w and...Leave a comment:
-
For one thing, your swap variable is always true, it's initialized to true, and nothing in your code ever makes it false, so the way you use it as a loop control variable means that you're going to get an infinite loop.
Also, even though you pass the length of the array to the sort function you never actually use it. length should be the loop control variable, the swap variable isn't necessary.
Finally, a bubble sort...Leave a comment:
-
Linked List Question
Ok, first of all I'm not sure if this is the correct forum for this question or not. But hopefully someone can help me or at least point me in the direction of the forum this belongs.
First of all, I am using C++, however it's managed C++ or visual C++, or whatever microsoft calls it. I'm using MSVS2005, and working on a Windows Forms Application project from the C++ projects tab. I'm pointing this out because apparently the syntax... -
Except that those are actually wrong. They should be:
C = (F - 32) / 1.8
The parentheses are important, other wise it divides 32 by 1.8 and subtracts that from F, and the second one should be
F = C * 1.8 + 32...Leave a comment:
-
Well, to your comment that you would have just used C# instead of C++.Net, I didn't really have a choice. I'm enrolled in a degree program and take the courses that are a part of that program. I knew that C++.Net wasn't exactly the same as standard C++, however I wasn't entirely sure of exactly how similar they were, which features they shared and which ones they didn't.
I just came here looking to find out if get/set properties were...Leave a comment:
-
Without using the derivative, you'd need to continue the loop without bounds, and have it end when fxnext is less than fx. I'd suggest initializing both of these so that fxnext is greater than fx, and then use that as your while condition, so that you can repeat it indefinitely (at least in theory). Something like this:
Code:int main(void) { int x=0; int fx = 0; int fxnext = 1;
Leave a comment:
-
I have 3 C++ books, the only one that even mentions properties only covers Windows Froms Applications projects, and that syntax doesn't work in Win32 projects (tried it).
Is it really that big of a thing to explain how to include a get property in a class definition? Just an example equivalent of what I used in my initial post would be fine, and I'd work it out from there. Basically, I just want a get property called EXP that would...Leave a comment:
-
Well, In VS 2005, the windows form project that I'm talking about is listed under Visual C++, not under Visual C#. Basically the project-type "tree" has 3 main nodes, Visual C++, Other languages, and Other Project Types. Visual C# is a subcategory under Other Languages. And the project type I'm talking about is Windows Forms Application, and is the first one on the list of Visual C++. And In my programming class that I learned windows forms...Leave a comment:
-
get properties in standard C++
Is it possible to implement get and set properties in a class in standard C++ (such as a Win32 project)?
For example I know that in VS 2005 in a windows form application project I would define a get property like this:
[CODE=cpp]property int VALUE
{
int get()
{
return //desired value;
}
}[/CODE]
Can these types of properties be used in standard C++, and if... -
-
-
declaring managed arrays in VS2005?
I'm making a Windows Forms Application on MSVS2005. In this program I defined a ref class named BaseStat. I need an array of these objects available to my application, but can't seem to declare the array. I guess technically I need an array of pointers to this type of object.
In MSVS2003 I would do it like this:
[CODE=cpp]private: static BaseStat *myArray[] = new BaseStat*[498];[/CODE]
How would I do this in ... -
Try this, remove sumpositive1 - 10 and sumnegative1 - 10 and just use the single sumpositive and sumnegative that you initialized to 0, like this:
[CODE=cpp]#include <iostream>
using namespace std;
int main()
{
double num1, num2, num3, num4, num5, num6, num7, num8, num9, num10, sum, sumpositive=0, sumnegative=0, mean;
cout<< "Enter 10 Numbers:";
...Leave a comment:
-
MSVS2003 to MSVS2005 changes??
I have a program that I wrote in VC++ using MS Visual Studio 2003, however I've recently run into a problem where 2003 no longer wants to compile the code that it generates itself. That's not a big deal for me though because I have MSVS2005 and would rather use the newer version, but I leaned VC++ on 2003 and have run into a number of problems with changes in the syntax, and would like some help on the appropriate syntax and keywords that I should... -
Magnacarta, so far in every one of your posts, you also forgot the ; at the end of your prototype in line 5:
void display(int A[] [],int m, int n,)
should be
void display(int A[] [],int m, int n,);...Leave a comment:
-
Your forgot a ( in your while statement at the end of your do loop....Leave a comment:
No activity results to display
Show More
Leave a comment: