199,114 Archived Topics
Remove Filter ![]() | |
Included file not found during compile time. This must be an easy question for you to answer. I have a header file (basetsd.h) that is located in the C:\Program Files\Microsooft Visual Studio\VC98\Include directory. Where do I set the path to this header file? I don't want to hard code it … | |
Hi, I'm doing a VC++ project, which requires me to create multiple CWnd objects and put them into one dialog box for viewing. For example, I need to create 100 buttons with 1-100 written on them, and put them into one dialog box. Of course the dialog box can't show … | |
Hi, I am trying to convert a string length to a char and store it in an array. For some reason, even though its not giving me any error, when I try to print the array out, the place where I store the strlen is blank. Here's my code: [code] … | |
# include<iostream.h> int main() { int ar[2]={8,2}; // (1) int var1=66; //(2) int var2=111; //(3) int* ptarray[5]; //(4) ptarray[0]= ar; //(5) ptarray[1]= &ar[1]; //Address of second element of array ar // (5) ptarray[2]= &var1; //(6) ptarray[3]= &var2; //(7) ptarray[4]= &ar[0]; //(8) // To keep code small I use a loop … | |
Hey! I'm looking for some help on what I'm doing wrong as I'm new to C#. I'd really like it if you can explain why my code isn't working and then offer some help on how to fix it without "making it easy" for me ;o) I have to understand … | |
I have a group project of designing the old board game "CLUE" in my C++ class that can be played by 1 person against the computer. If someone would help me get started it would help a bunch. I think this could be a neat project, but have no clue … | |
Would somebody chck this code please. I am a struggling C++ student and need all the help I can get. Thanks, Curt [COLOR=#008000]Here are the directions: [/COLOR] create a function that check's the number, put's out whether it's odd or even and adds it to the total variable [code] [COLOR=#0000ff]#include[/COLOR][COLOR=#800000]"stdafx.h" … | |
I wrote a simple program that sums the square of integers m -> n. If sum is declared as [B]double[/B] it gives something like 4.16..x10^10 for integers 1 -5000. However, if sum is declared as an [B]int, [/B]for the same range it reports -1270505460. Obviously this has something to do … | |
Hi Guys, I know this will be easy for anyone here and it might take 2 minutes to right the code. I wonder if someone can help me to right a loop using strtok() to be able to extract the words form a string like "various systems analyze the model … | |
I ve read that iostream is a derived class of fstream ,so including the "fstream" header is all sufficient to perform console i/p and o/p(ie cin and cout) .this worked fine as long as I used Turbo C++ compiler but now I ve switched to Bloodshed Dev C++ compiler and … | |
I am doing a mazetraversal program that inputs a .dat text file. Im having trouble taking in account of the whitespace. Here is my code and were the ?????? is where it needs to go. I think its just a small "if" statement taking it in account. [CODE]#include <iostream> #include … | |
Hello, :) I have chosen to go with getch() for my keyboard input. However, when I went to experiment with it, I got some unexpected results. The 'Y' in 'Your word was ' is missing in the command prompt when I run this program after I compile using gcc, and … | |
Im planning in buying this. Is this all I need to start coding? Thanx Overview [B]The Visual Studio® 2005 Standard Edition from Microsoft®[/B] is a comprehensive, high productivity professional development environment for individual developers for building enhanced performance, multi-tier applications for Windows®, Web, and common consumer mobile devices. It allows … | |
I have a 2 part problem. 1) In circleTypeImp.cpp I am being returned incorrect values for circum and area variables. I have tried using both float and double variable type with no luck. Any pointers? 2) I have read over how to derive a class a number of times and … | |
I have to use a variable of type double to store and manipulate a value for an amount of years. This means I have to ensure that the data input by the user is an integer. The program will accept a non-integer value, but I want it to continue reprompting … | |
I am using filepointer in C. when I compile the code and run it for the first time the filepointer works fine and logs are written into log files. But during next hits there is an inconsistency in logs getting written. sometimes getting written and someother times not written. But … | |
Hello, I am trying to develop something that, when you press a character on the keyboard, puts a char into a char-type variable. Should be easy right? Well, I don't want to require the user to have to press ENTER when they press the key. Maybe scanf isn't the right … | |
hi, in my code i am creating a tree, which have a 20 levels and and each level we have 10 nodes. i.e every node can have a 10 children. for them i am allocating memory for each node. each node is stracuture which occupies the memmory around 40 bytes. … | |
this is a program that i have to write. followed by the code i already written. Design Specification You are to write a program called “StockAnalyser”. Your program will read a text file that contains historical price of a stock. The program will allow users to query the stock price … | |
Predict the output of the following code: #include < IOSTREAM > int main() { char weekdays [7][10]= { "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" }; cout<<**weekdays; } Could any one let me know answer and also the explaination if possible | |
I allready asked a question about this inside JoBe's Thread about the stl <map> ([URL]http://www.daniweb.com/techtalkforums/post252520-10.html[/URL]), but maybe it's better if i make a new thread about it. The problem is, when i try to use <map> inside my project i get 2 errors: C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\map(16) : error C2143: … | |
Hi Guys, Just wondering I'm newbie writing C programs and I don't expect to get the entire code here but I was allocated a task/assigment to create a C program that emulates a search engine so I was given a bunch of text files that contains HTML data and I … | |
I am trying to write a simple program in c++ to take a beginning delivery time in 24 hour time and an ending delivery time then taking 25% off that time(making the end time 25% sooner). For example, i'd have a user enter in 0900 for start time and 1030 … | |
Here's a really simple problem. I understand the basic search algorithms however, is there a difference when implemeting them in regards to vectors or strings? I want to determine if a certain value using a sequential search, the code would look something like this; [code] #include <iostream> #include <fstream> #include … | |
Hi can anyone help me in doing the following Given n Boolean variables x1,x2,…..xn, we wish to print all possible combinations of truth values they can assume. For instance, if n=2, there are four possibilities : true, true; false, false; false, true; true, false;:-| | |
:?: haiii iam a student from engg college... i juz have a lab on compilers.. i have a program called conversion of Regular expression to NDFA.. can u plz help me with de source program... in C:?: :?: :idea: | |
I am a newbie to C++ and I'm not sure of anything at this point in time however,I got a problem with the starting phase of this program that well prompt the user to input a single character and output a inter4national Civil Aviation Word !!!!! The prolem that I … | |
Hi, I am in need of some help with a small portion of my program. I have an input file as follows: [CODE]10 9 15 program1 11 1 30 important 12 11 10 junk program 14 15 5 other program 17 6 20 another program[/CODE] I need a function to … | |
:confused:I got this assignment to write a program using the switch statement or the functional decomposition, that inputs a letter and outputs thr corresponding international Alpabet. A Alpha B Bravo C Charlie so on and so on Is there anybody that can help me with this program? | |
I'am new to wingdi. As I tried to include my wingdi.h in my borland C++ 5.5 program, the compiler shoots the following errors: Error E2303 C:\BORLAND\BCC55\INCLUDE\wingdi.h 269: Type name expected Error E2139 C:\BORLAND\BCC55\INCLUDE\wingdi.h 269: Declaration missing ; Error E2303 C:\BORLAND\BCC55\INCLUDE\wingdi.h 270: Type name expected Error E2238 C:\BORLAND\BCC55\INCLUDE\wingdi.h 270: Multiple declaration … | |
I have a question about the map-question JoBe asked at the start of this post. I'm also trying to build a program using <map>, but when i compile i get error that point to code inside the MAP-file. I saw your post here, and i tried your small program, but … | |
I'm creating a code which will map two distict strings. I used two ways for that: 1) created a MAP and added raw data to it from file. It is not that efficient.:sad: 2) created an object holding mapped values: eg. class c { string str1,str2; public: /// opearations }; … | |
I need to know how to get change in 5c 10c 20c 50c $1 $2 $5 $10 $20 $50 $100 in the smallest possible denomination. In AUS dollars. | |
CString Convert to LPCTSTR i write DLL file,it is static dll i want CString type Convert to LPCTSTR but error Code: <<<<<<<<<<<Dll File>>>>>>>>> <<<<<<<A.H>>>>>>> class AFX_NOVTABLE dll { public: __declspec(dllexport) LPCTSTR Fun(); }; <<<<<<<A.Cpp>>>>>> LPCTSTR dll::Fun() { CString Rxg=_T("rxg"); LPCTSTR lpszStr=Rxg.GetBuffer(); return lpszStr; } <<<<<<<<Exe>>>>>>>>> #pragma comment(lib,"dll.lib") #include "A.h" .................. … | |
I'm doing a dialog application in C++ to calculate something, but I want the result to be with 2 decimal number, how to do this? here is the function: [CODE]void CCalculatorDlg::Oncalc() { // TODO: Add your control notification handler code here UpdateData(TRUE); if ((m_amostras >= 1) && (m_elementos >= 1) … | |
I'm new to these forums,and really new to C++,but here is what i need to know.I made a simple calculator in C++ and i was wondering what i need to be able to keep useing it without opening the program everytime... [code]// simple calc // Chris Wilson #include <iostream.h> int … | |
Hi, can you please indicate me some ebooks about C for beginners, thanks | |
Hi guys. Hope all is well. There's another concern too. If one is to write a code in which a number would be changed into its binary equivalent, and the binary equivalent would be printed, how does one untie this knot? [CODE] #include<stdio.h> main() { int n; /* the number … | |
I got a Link error 1181 with fresh code from source safe. It is looking for a dll that is in the windows/system32 directory and cannot find it. [QUOTE] Linker Tools Error LNK1181 cannot open input file "filename" The linker tool could not find "filename" because it does not exist … | |
Hello, everyone. Since I am new to this site, I have both a question to ask regarding the subject tags, and also about a while exercise I am working on. However, before I state the while exercise, I first need to know exactly how one uses the subject tags to … | |
So I have a question regarding ifstream and reading a file. I have to read in this file, but some of the lines of the file will have missing sections of data. These lines I want to just throw away and then continue reading the file on the next line … | |
[code] int main() { int var; char string[50]; (var, string); (0); (0, 1, 2); return 0; } [/code] Reply ASAP Thanks in advance Govinda Attal. | |
hey guys, i am trying to get my code to count the number of characters in a file. However, the program is continuously going through the characters (so it goes from a-z thousands of times) when i want it to say how many times 'a' occured and 'b' and so … | |
How to store a 64 bit value into 2 unsigned long variable (of 32 bit)? Let, [code]: unsigned long a; // variable 'a' will be incremented regularly and 'll be stored in b void fun(void) { unsigned long double b; // It may be a global variable b += a; … | |
I am getting this error: .c:28: warning: assignment makes integer from pointer without a cast -any fixes thank you [code]#include <stdio.h> #include <string.h> void addValue(); void changeId(int data, char *name); int main() { addValue(); changeId(2, "Bill "); getchar(); return 0; } struct Node{ int data; char *name; }node; void addValue() … | |
unsigned int a =0xffff; ~a; printf("%x",a); gives output ffff Complementing function works here. What's use of 0x in 0xffff as unsigned int is of 2 bytes only??? Can anybody suggest??? | |
[IMG]file:///C:/Documents%20and%20Settings/Curtis%20Bridges/My%20Documents/My%20Pictures/Dinosaurs/scan.gif[/IMG] | |
I got stumped can someone please help ? I’m working on this home work assignment and can’t get past this point. Here is how far I’ve got: [CODE] #include <iostream> #include <iomanip> using namespace std; using std::cout; using std::cin; using std::endl; int main() { int numbers,to,Enter,odd,even; int integer,positive,a; cout << … | |
It may not be the problem of my own procedure, because no matter what new projects I create, I got those 15 errors. who can copy his winuser.h file and send to me? I am using VC6.0++ Thanks a lot! my email: <<email snipped>> | |
[code] //The following example overloads the + operator to add two complex numbers and returns the result. // operator_overloading.cpp// compile with: /EHsc #include <iostream> using namespace std; class Complex { public: Complex( double r, double i ) : re(r), im(i) {} Complex operator+( Complex &other ); void Display( ) { … |
The End.