49,757 Topics

Member Avatar for
Member Avatar for ziggystarman

Hello I'm looking for the correct method/way for reading & writing raw JPEG image binary data. I am obtaining the raw data via TCP stream, the official JPEG specs say that the raw JPEG image data starts at HEX value 0xffd8 & ends at HEX value 0xffd9 as below... [CODE]Start …

0
107
Member Avatar for myk45

Hello. Can anyone please tell me if there are any sites where i can practice programming? i mean sites like TopCoder, SPOJ, CodeChef. But i needed a site where there is an explanation for problems(so that i can understand the basic algorithmic concepts) and then go on practicing it. i …

Member Avatar for Fbody
0
216
Member Avatar for ziggystarman

Hi I'm looking for good tutorial/s about using boost::regex with c++ code examples any links would be really helpful... Many Thanks Steve PS not tuts about setting up boost, done that already.

Member Avatar for ziggystarman
1
229
Member Avatar for Nemo_NIIT

HI Friends i have create this simple code in visual C++ [CODE]#include<iostream> int main() { std::cout<<"Hello World!!"<<std::endl; system ("PAUSE"); return 0; } [/CODE] can anyone help me to write log file on base of this please

Member Avatar for Nemo_NIIT
0
3K
Member Avatar for i_luv_c++

Hey guys, I just reinstalled MS Visual Studio C++ Express and I am having this weird problem with the complier. So for example if I add a source file name file1 and run it it works fine..however if i delete the file1 from current project and add file2 it will …

Member Avatar for Milton Neal
0
110
Member Avatar for Annettest

Hello everyone: I'm a C++ newbie. I have written code for performing calculations that needs data from another code. These data are in text files. I know how to read in an ENTIRE text file, but I can't figure out how to extract certain pieces of it. I would very …

Member Avatar for Greywolf333
0
244
Member Avatar for aaronmk2

I am using an overloading operator to add two polynomials. I have gotten it to work, but I am wondering if I can improve on my if statement by not changing the value of degree for the rest of my program. The if statement is used if the second polynomial …

Member Avatar for caut_baia
0
159
Member Avatar for crodriguez08

Hey there, I'm having trouble getting my program to read the last instruction of the file, and so far, I haven't been able to figure out why. Any help would be appreciated. [CODE]/* The Simpletron Machine Language Program. The purpose of this program is to simulate a primitive computer. This …

Member Avatar for crodriguez08
0
188
Member Avatar for gee1288

hey need some help with my loan program i have two problems how do you add the total of the variable sumtin from a while loop and i need to show the inital loan first then after the calculations are done show it again like i want it to show …

Member Avatar for marbie 05
0
173
Member Avatar for aaronmk2

I am multiplying two polynomials and cannot figure out how to add the exponents. The loop is to multiply the coefficients and degree is for the total degrees used in the polynomial. But I can't figure out what I should use to add the exponents. [CODE] Poly Poly:: operator*(const Poly& …

0
73
Member Avatar for Talguy

I have recently voluteered to be a mentor for a local inexperienced FIRST robotics team. The main area I will be mentoring is the programming aspect of the competition. The controllers for last years robot was programmed using LabView but they also can be programmed in C++. The better teams …

Member Avatar for N1GHTS
0
117
Member Avatar for davyboi91

#include "stdafx.h" #include <iostream> using namespace std; void main(); int _tmain(int argc, _TCHAR* argv[]) { double sum_positive=0,sum_negative=0,sum_total=0,num; int total_negative_number=0,total_positive_number=0; cout << "Enter number.\n" << endl; for (int i=0;i<10;i++) { cin >> num; sum_total +=num ; if (num>0) { sum_positive+=num; total_positive_number++; } else { sum_negative +=num; total_negative_number++; } } cout <<"Sum …

Member Avatar for Milton Neal
0
133
Member Avatar for aaronmk2

I am writing a program where the user inputs two polynomials, then the program adds them, multiplies them, and evaluates one of them. I am having two problems. First, I can't think of how to add the exponents in the overloaded method for *. Second when the two polynomials multiply …

0
63
Member Avatar for frank754

Forgive me again, I'm a complete noobie at Visual Studio, even though I have been using PHP for years. I need this for my new job and the classes (public, private, etc) are really a bit confusing. Suppose I'm trying to make a new windows form, and I have various …

Member Avatar for frank754
0
167
Member Avatar for Christ1m

If I have 4 person. How do I create a function that can determine the oldest person below? Person p1("JAck","Spice","48); Person p2("Burn","Side",53); Person p3("Leppy","Doopy",20); Person p4("Jimmy", "Dean", 32); I need someone to help me explain how "for" loops work.

Member Avatar for prvnkmr449
0
121
Member Avatar for hq1

I have an assignment that i need to do and i have no idea how to do this, I was hoping someone would be nice enough to help me out, its a begginner program that needs to be done in visual stdio c++: Heres the assignment: Try to write a …

Member Avatar for Fbody
0
451
Member Avatar for Jennifer84

Hi, I have a button control where I retreive 2 strings with 2 URL like in the code below. What I wonder how it is possible to do, is how to open up [B]1 browser [/B]window with 2 Tabs where 1 Tab is [url]http://www.google.com[/url] and the other [url]http://www.yahoo.com[/url] How can …

0
51
Member Avatar for kshaaban

Hi everyone, So this is my first post :S and as you will probably tell from my code, I'm pretty new to coding in c++. My main areas are web and online video streaming and encoding etc. however I have taken it upon myself to learn c++. This is part …

0
88
Member Avatar for aaronmk2

I am trying add two polynomials by overloading the + operator. When I run the program it only adds the first coeficients. I cannot figure out why it is only returning the first coeficient. [CODE] //header file #include <iostream> using namespace std; #ifndef _POLY_H #define _POLY_H const int CAPACITY =100; …

Member Avatar for gerard4143
0
120
Member Avatar for unclepauly

hi, i have this code: [inlinecode] HINSTANCE hComponent = ::LoadLibrary("Component1.dll"); [/inlinecode] i get this compile error: Error 1 error C2664: 'LoadLibraryW' : cannot convert parameter 1 from 'const char [15]' to 'LPCWSTR' c:\Documents and Settings\Administrator\Desktop\Component1\Client1\Client1.cpp 9 so i changed the code: [inlinecode] HINSTANCE hComponent = ::LoadLibrary((LPCWSTR)"Component1.dll"); [/inlinecode] however GetLastError returns …

Member Avatar for memphis.ray
0
972
Member Avatar for Sirovica

Hello everyone this is my first post on the daniweb community. Currently I am home sick with a nasty cold so I was trying to solve a programming problem on a wonderfull sight called Project Euler. The problem is as follows: If we list all the natural numbers below 10 …

Member Avatar for frogboy77
0
148
Member Avatar for mrickert

Hi- Trying to rename a file using the rename() function. It works, but it appends an '@' to the end of the renamed file. Here's my code: [code=c] char oldname[] ="file1.csv"; char newname[26]; newname[0] = '3'; newname[1] = '1'; newname[2] = '1'; newname[3] = '3'; newname[4] = '3'; newname[5] = …

Member Avatar for Fbody
0
123
Member Avatar for marsh_mallows11

please give me a code for this problem..... Objectives: To implement retrieving of data from text file to a record To implement storing of updated data from the record to a text file Procedure: 1. Create a structure for a simple telephone directory system named struct telDirectory{}composed ofchar username[20], long …

Member Avatar for SgtMe
-1
183
Member Avatar for SpiritualMadMan

I am getting the following error when I try to access my Resource Files in Visual C++ v6 "The file is already open in an editor." I've tried closing all windows in the IDE and closing the project, even tried logging out and back in. All to no avail. A …

Member Avatar for SpiritualMadMan
0
407
Member Avatar for MikeThras

Hello to everyone, Well I'm a noob to C++, I just started two weeks ago, I'm trying to get a good head start before I start college next semester. I've done simple programs, but now I'm trying to create a body fat percentage calculator I guess you could say. but …

Member Avatar for MikeThras
0
265
Member Avatar for frank754

Re: Visual Studio 2008 adding/deleting portions of the form: I'm sure this has been asked before, but if I create a new project and add buttons, text boxes, etc. from the designer (the GUI portion), and click on each element, it creates a class for it in the .cs view. …

0
60
Member Avatar for SgtMe

Hi just a simple n00b question. I need to split a string (from a .obj 3D model format) into a list of three doubles (the vertices). example string: v 0.200006 -0.093641 0.584690 I want to make it into an array of (for example): {0.200006, -0.093641, 0.584690} I can get rid …

Member Avatar for SgtMe
0
167
Member Avatar for Christ1m

Create a Person class to represent a person's contact information. Your Person class must consist of the following: PRIVATE members: string firstName,lastName; birthDate //you get to choose the data type, but the type you choose must be able to maintain a // 1 day resolution PUBLIC members: 1. Default constructor …

Member Avatar for Christ1m
1
1K
Member Avatar for Tguid24

I'm taking a computer science class, but I do not have a very good professor. He does not explain anything. We have an assignment to : Write a complete C++ program in stats.cc to read an arbitrary number of real numbers(one value per input record) from a specified input file …

Member Avatar for Tguid24
0
186
Member Avatar for Rayanjaha

i want to write a program can caulate the area of a circle and squar using overloaded functions, i tried but it didnt work , what i missing here ? [CODE]#include<iostream> using namespace std; class math { int r; double d; public: void set_value(int t) { r = t; } …

Member Avatar for gerard4143
0
105

The End.