49,761 Topics

Member Avatar for
Member Avatar for kesh1000

dear people recently i have been given with this assignment where i have to read from a txt file and then print out the following. the full class list. the class list sorted by gpa the class list sorted by name initial the user enters the class average gpa. i …

Member Avatar for Ancient Dragon
0
101
Member Avatar for yashyash

Dear experts I have a large file with this format: [CODE] 1 7252 0.1613 1 7253 0.1613 1 7254 0.0645 1 7255 0.0409 1 7256 0.0394 1 7257 0.1872 1 7258 0.1872 1 7259 0.0986 ...... [/CODE] and I want to change this file to the binary format but it …

Member Avatar for Ancient Dragon
1
179
Member Avatar for killdude69

Dear DaniWeb, I am working on a source code editor using Scintilla and am currently having some issues with the CreateFile() function. It does not return an error when I am saving as a new file, but when I am saving changes to the current file, it returns INVALID_HANDLE_VALUE. I …

Member Avatar for Yiuca
0
4K
Member Avatar for killdude69

This is a very simple problem, but for some reason I can't get it to work. I need to empty a variable ( char fileName[MAX_PATH] =""; ). It needs to be to where when I use this that it sees if it equals "", this wont work if it equals …

Member Avatar for killdude69
0
377
Member Avatar for Daria Shmaria

I'm trying to traverse to the end of a linked list, but I get a segmentation fault when my while loop checks to see if the "next" pointer is null. Any suggestions on how to perform this check without causing a segmentation fault would be greatly appreciated.

Member Avatar for ArkM
0
454
Member Avatar for abhishek2301

Hello, I need to implement the following situation in C++: I have a counter which I want to increment with a certain probability. I am giving a pseudo code which will clear: counter = 0; prob = 0.5; for i <- 1 to 100 if(prob) // want to increment the …

Member Avatar for ArkM
0
137
Member Avatar for Ameerah

Hi for ever can any one help me [COLOR="Red"]only give me idea[/COLOR] of this question Write a program that reads from a file list of unsorted names and sort the names automatically and then asks the user whether he/she would like to print the names in the output screen or …

Member Avatar for ArkM
0
196
Member Avatar for gretty

Hi I am making a program that takes in a date (dd mm yyyy) & returns the day of the week(eg monday) of the input date. My problem is that my fuction [B]day_of_week[/B] is not returning the variable [B]dayString[/B] into main. So dayString is not being output in main. Any …

Member Avatar for ArkM
0
125
Member Avatar for Carrots

Hi, Hoping someone can tel me where I'm going wrong, or what I should do. I'm trying to use some pure virtual functions on some polymorphic classess but am unsure how to do it correctly. Hiopefully this code will explain it a bit better: vehicle.h : [code=C++] using namespace std; …

Member Avatar for Carrots
0
187
Member Avatar for rtwister

it keeps saying theres an error on line 17, it says: "no match for 'operator!=' in 'a != password'" [CODE] #include <iostream> #include <cstdio> #include <cstdlib> using namespace std; int main() { string password; cout << "Type in a password: "; cin >> password; char a; a = 'A'; cout …

Member Avatar for tux4life
0
133
Member Avatar for Behi Jon

Hi . What is the problem of this : template < typename B > ostream &operator << ( ostream &out, const Array < B > &a ) The compiler say "Link error" and ...

Member Avatar for Ancient Dragon
0
184
Member Avatar for Abderian

I made a program in Visual Studio that reads an End-Of-File signal. When you run in the debug mode, sending the signal closes the program. Running without debugging with ctrl + F5 means you can send the signal. However, when I compile in release mode and run the exe it …

Member Avatar for Abderian
0
197
Member Avatar for Daria Shmaria

I am writing a program to compute the fastest/shortest path between locations (stored in a directed graph represented by an adjacency list). I am trying to create this adjacency list ("al") as an array of pointers to Vertex class objects, but I get the error " 'al' was not declared …

Member Avatar for Daria Shmaria
0
149
Member Avatar for wnrqkflwnrqkfl

Hi all, I asked about this question few days ago, and I have tried few things other experts told me I think i got overcame problem where i can read the tab spaced file but now the output is the problem..... When i run my program it outputs: Enter filename: …

Member Avatar for daviddoria
0
79
Member Avatar for thumizee

could anyone tell me if the last lines of the following are true or false? 1) int arrA[3] = {1,2,3}; int *ptrToarrA = arrA; int *anotherptrToarrA = arrA[0]; 2) int arrB[2] = {1,2}; int *ptrToarrB = arrB; int *anotherptrToarrB = *ptrToarrB;

Member Avatar for tux4life
0
87
Member Avatar for aditya_amb

I am begininner in DLL. I looked at following site to create dll in C. [url]http://msdn.microsoft.com/en-us/library/ms235636(VS.80).aspx[/url] Can anyone explain how to use the Mathfuncdll.dll in VB.net. Here is my VB code Public Class Form1 Public Declare Function MathFuncs Lib "MathFuncsDll.dll" () Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As …

Member Avatar for Teme64
0
315
Member Avatar for thornside

Hi, I need to know how to continue execution of code after throwing an exception. Has it got to do with where I place the throw statement? Thanks in advance.

Member Avatar for thornside
0
10K
Member Avatar for gretty

Hi I have a bool function that should find whether a year was a leap year or not. But the function is not returning the correct years as a leap year. [CODE]#include <iostream> #include <fstream> #include <string> using namespace std; bool is_leapyear(int year); int main () { int a = …

Member Avatar for gretty
0
115
Member Avatar for mirfan00

Hi I faced a very serios problem when I connect c++ with orcale. This is our project. I use c++ at front end and orcale at the backend. If someone know how to create a connection between them Please tell me. Advance Thanks.

Member Avatar for mirfan00
0
194
Member Avatar for ultrAslan

I have an assignment like that and I dont know how to begin... Could you pls help me. [url]http://www.cse.ohio-state.edu/sce/now/221/labs/writeups/lab07.html[/url]

Member Avatar for Ancient Dragon
0
69
Member Avatar for effective

[CODE]#include<iostream.h> #include<string.h> #include<conio.h> const int len=30; enum contract{permanent,temporary}; class Employee{ protected: char name[len]; long int ID; double salary; public: Employee() **} Employee(char n[len],long int id, double s)** strcpy(name,n); ID=id; salary=s;} void setEmp(char [len],long int id,double s) ** cout<<"\nName of Employee: "<<name; cout<<"\nID of Employee: "<<ID; cout<<"\nSalary of Employee: "<<salary; } …

Member Avatar for effective
0
67
Member Avatar for rafaelbrizu

I have that funtion for generate sequence to the style 'hqhzaw', 'ebcpm', 'qtch', etc. (only letters) and according to 'lenght' [code=cplusplus] string random_letter(int length) { string s; for (int i = 0; i < length; i++) { s += char(rand() % 26 + 97); } return s; } [/code] I …

Member Avatar for rafaelbrizu
0
102
Member Avatar for serkan sendur
Member Avatar for DarthPJB

Hello once again, I've continued my engine somewhat and the rendering functions are now working fine thanks to Stinomus (feel free to applaud). However to enable it to load data I must use files containing strings describing objects in the game world. That in turn works perfectly and passes the …

Member Avatar for DarthPJB
0
233
Member Avatar for lyardson

the exact diff between c++ and java technically........need to submit a assignment

Member Avatar for mirfan00
0
268
Member Avatar for dumbncool

Hello, I'm writing a MFC application to move a picture control when i press the "Next" button. (Please see attached screen-captures) There is a dialog box on which there are 2 picture controls. When I press the Next button, the left picture control should move on top of the right …

0
46
Member Avatar for abhishek2301

Hello, I require a help on a basic issue. I have 2 classes and I want to have an interaction among the classes. Suppose my 2 classes are testA and testB. Now I want a handle of object pointer in each class to the other class. Like I want a …

Member Avatar for mirfan00
0
138
Member Avatar for mini programmer

Hi to all I have ADT of the AVL TREE and I need to add some the function to create tree to family. I have logic error in my code.. my code work to find relationship between two nodes (e.g: a parent of b,a and b are Sibling and so …

0
89
Member Avatar for Massena

I hate to be spamming the forums with this, but I've been banging my head at the wall for a few hours now, and I can't really understand what is going on. Here's the full program I'm running: [code=c++] #include <iostream> #include "math.h" int main() { std::cout << sin (3.141592653589793) …

Member Avatar for ArkM
0
119
Member Avatar for hodge-podge

Alright, so I am very new to c++ and I just felt like doing a little encryption experiment. In about ten seconds of thinking I've decided that for my encryption I want to: Get the ASCII value of a string of text entered by the user, and store it in …

Member Avatar for ArkM
0
148

The End.