49,761 Topics

Member Avatar for
Member Avatar for daviddoria

I realize this question may be impossible, but I'm pretty confused so I'm drawing at straws. I'm trying to use a class from a big library. If I do this: [code] TheClass imageIterator(image, region); [/code] everything works fine. However, if I do this: [code] TheClass imageIterator; imageIterator = TheClass(image, region); …

Member Avatar for daviddoria
0
249
Member Avatar for sudhisandeep

i have entered this particular code in vc++ 2010: [CODE=c]#include<windows.h> int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPInstance,LPSTR i,int j) { MessageBox(NULL,TEXT("HELLO"),TEXT("SAMPLE"),0); return 0; } [/CODE] showing error like this: [CODE=text]1>LINK : error LNK2001: unresolved external symbol _WinMainCRTStartup 1>D:\projects\sandeep\Debug\sandeep.exe : fatal error LNK1120: 1 unresolved externals [/CODE] please help me. how do i …

Member Avatar for WolfPack
0
100
Member Avatar for fpsasm
Member Avatar for GamerDJX

OK so here's my problem. I am a really new programmer, and my instructor has been giving us assignments that most of us are not exactly ready for. We have this assignment, and I honestly have NO IDEA where to even begin. Bottom line, I need help. Here is the …

Member Avatar for jonsca
0
162
Member Avatar for electrox73

Hi, I am able to create a clock in a console c++ app...like this one show UTC hours:[CODE]#include "stdafx.h" #include <iostream> #include <windows.h> #include <stdio.h> void main() { SYSTEMTIME st, lt; GetSystemTime(&st); GetLocalTime(&lt); std::cout << st.wHour << std::endl; std::cin.get(); }[/CODE] But I am not able to create this with the …

Member Avatar for jonsca
0
294
Member Avatar for c+-

can i make a prototype for a class member function outside of the class declaration? i tried this: but it didnt work [CODE]class cls; void cls::dosomething(); class cls { public: void dosomething(){} };[/CODE] thanks

Member Avatar for template<>
0
510
Member Avatar for SolidSora

I need to make a program that outputs a name based on the users input. For the middle name I'm only supposed to show the middle initial. But the way I have my code written causes an error. [CODE]#include<iomanip> #include<iostream> #include<string> using namespace std; string firstName; string lastName; string middleName; …

Member Avatar for template<>
0
113
Member Avatar for geekme

Hello need help in traversing a b tree from down node to utmost parent node and how can you code for a leaf element, as it has an adjacent node as well apart from no child. REgards

Member Avatar for template<>
0
62
Member Avatar for Taibah

Hello, I started to learn c++. i followed most of the basic things console programming of c++ like loops functions and more but where can i learn now the structure of programming and how i need to think. Are there tutorial about that. because you can not create a program …

Member Avatar for template<>
0
489
Member Avatar for VanHackman

Hello, I'm trying to make draggable a borderless form developed using Visual C++. How ever, I'm not having look with it, and I had been unable to find an example about how to do it around the web. This is the code I'm using currently, and which is not working. …

Member Avatar for jonsca
0
710
Member Avatar for triumphost

Is this possible to embed a console into the gui like the picture below?? If so I wanna know how. [img]http://img229.imageshack.us/img229/6995/cmdahk.jpg[/img] found it here: [url]http://www.autohotkey.com/forum/topic45935.html[/url]

Member Avatar for paulmooreparks
0
190
Member Avatar for scarlettmoon

Hi ~ My program seems to work perfectly with the exception of validating user input. I do not want someone to do the work for me, I don't learn anything that way. I need to know why it works not just what or how. I just need a push in …

Member Avatar for scarlettmoon
0
364
Member Avatar for aaronmk2

I am reading in from a file and when I use .eof() it read everything from the file the I get a run time error of Exc-Bad-Access. When I run a for loop instead the program runs with not errors. Any hints? [CODE] while (!inputFile.eof()) { inputFile>>number>>lowerRange>>higherRange>>cond>>aFName>>aLName>>phase; active=(cond=='t'); sAds[i] = …

Member Avatar for WolfPack
0
130
Member Avatar for Awesumlewy

Hello, I am currently trying to improve my programming skills and I just can’t get my simple program to work correctly. Here’s the problem: I have managed to allow a user to input 10 numbers then when they insert these 10 numbers, the sum and average is displayed, simple! Then …

Member Avatar for richieking
0
170
Member Avatar for Forthright

Hi I am trying to call a 3rd party method which relies on const char* I want to pass an arbitrary value. The (broken) code below should show what I'm trying to do. [CODE] #include <iostream> #define MAX 1000 // 3rd party stuff void ConstPtrMethod(const char* s) { std::cout << …

Member Avatar for Forthright
0
342
Member Avatar for zacblazic

Hey guys, My lecturer told me that when I have solved a problem, I should always look for ways to improve it. I was wondering if it is okay to post my code here and ask the community to comment and tell me if it can be improved, but I …

Member Avatar for anilashanbhag
0
118
Member Avatar for dav555

I try to transmit an OpenCV IplImage from a Server (Ubuntu x64) to a Client (Win7 x64) The following code works fine if both (Client and Server) are on the same operating system. But when the server is on Ubuntu and the client on Win7 it doesn't work. The image …

Member Avatar for dav555
0
424
Member Avatar for AutoPython

I'm creating a program and I need the class 'Child' in the following code to inherit the value of 'age' from the class 'Mother'. [CODE] #include <iostream> using namespace std; class Mother { public: int TellAge(void); protected: int age; } MObj; class Child:protected Mother { public: void ChildTellAge(void); } CObj; …

Member Avatar for AutoPython
0
135
Member Avatar for andy.apple

Hi, I want to sum up all values within a vector of doubles, let say [4.5 8 5 90 24 32 58 1.8 17 25]. The sum is 265.3 which isnt to difficult. But when using the accumulate function I get 264!? [CODE] #include <iostream> #include <math.h> #include <vector> #include …

Member Avatar for andy.apple
0
139
Member Avatar for se00an

Hello all, Inverting an upper (or lower) triangular matrix is a trivial algorithm, due to the nature of the matrix. I am having an issue getting a part of my upper-triangular matrix inversion function to work, and I would like to get it working soon for a personal project. From …

Member Avatar for se00an
1
2K
Member Avatar for CanaznFTW

This is my first post and I'm sort of new to programming and figured joining this forum to try and get some help. So please excuse me if I happen to miss something. Task: - Create a cylinder specified by my program with the radius and height - Which will …

Member Avatar for CanaznFTW
0
4K
Member Avatar for kas04

Ok so I have the easy part of this problem figured out but the other part is confusing me. Here's the problem: Write a program that reads in a line of text and outputs the line with all the digits in all integer numbers replaced with 'x'. Example Input: My …

Member Avatar for jonsca
0
2K
Member Avatar for ziggystarman

Just started looking into visual c++ express 2010 today, no exp at all with this IDE anybody know how to remove these types of errors from project. [CODE]1>AXIMP : AxImp error : Could not load file or assembly 'Interop.MSHelpServices.1.0, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot …

Member Avatar for ziggystarman
0
165
Member Avatar for jinx0007

hi everyone im new to this and in am having some issues making this work correctly first when i run the debugger it comes out with some stuff joined together like numbers and words and getting it to calculate the 750 pieces of gold with the reminding explorers not coming …

Member Avatar for jonsca
-1
98
Member Avatar for lochnessmonster

any suggestions on this custom array class?(it compiles and works properly) [CODE]// Sequential_Sort.cpp : Defines the entry point for the console application. // #include "stdafx.h" #include <iostream> #include <fstream> #include <Windows.h> #include <WinBase.h> /** * Class: Array * * Custom Array class used to read input from a file * …

Member Avatar for griswolf
0
436
Member Avatar for TriG0rZ

Hi, Im kinda new to creating C++ gui apps. I am using a application called c++ Builder XE and i was wondering if anyone knew of any good tut for creating a GUI application and any other tut that may help using this application Thank you :)

0
35
Member Avatar for triumphost

Hello everyone, I have one question.. should be relatively simple but I just cant seem to find any info anywhere.. maybe Im just looking in the wrong place and need guidance.. Here is my problem.. I have the following code: [CODE] EnableMenuItem(GetSystemMenu(GetConsoleWindow(), FALSE), SC_CLOSE , MF_GRAYED); DrawMenuBar(GetConsoleWindow()); GetSystemMenu(GetConsoleWindow(), FALSE); //Disables …

Member Avatar for triumphost
0
955
Member Avatar for katokato

im new to this c++ thing and windows api thing, and i got most of this code from a tutorial but i modified it alot. how do i retrieve a handle to a dialog box so i can put my menu inside it? (when i put the code for the …

Member Avatar for katokato
0
1K
Member Avatar for prog_newb

[CODE]do{ chatLike("Enter student's full name: "); getline(cin, name, '\n'); //I have my try-catch here }while(error==true);[/CODE] chatLike is a function that i made that produces the cout character per character. program immediately crashes when input is: a)input is space only or a single space b)input ends with one or multiple spaces …

Member Avatar for jonsca
0
177
Member Avatar for Legend32A

I am using the following code to take a screenshot , compress it to jpg and save it. I am trying to compress the image more, e.g. from 200kb --> 100kb. Let's say about 60% of original quality. Could you guys, please help me find out how to do this? …

Member Avatar for WolfPack
0
132

The End.