49,761 Topics
| |
Hi there, I want to read 1 byte of information, in the form of an array of unsigned chars [1], from a file. I then want to use this piece of data to act as a secret key for a message authentication code I will be performing. The key will … | |
Hey all, I'm having trouble with an assignment for my C++ class. The .pdf has the assignment parameters, and the .cpp file has what I've written so far. Right now I've written the program enough to make sure the two strings (LastName and FirstName) get swapped correctly and put into … | |
Hey! I have a string str = "12354" . i want to create another string str2 with only the first two elements of the string str ie i want str2 = "12". can someone please tell me how i can do that? | |
Hi(sorry my english) i used to use a library to manipulate characteres on the screen( like gotoxy() ), also the colors and the background color, but i really didnt like of it, it was very unknow. So, there is a library where i can send any character to a given … | |
Hi! Everybody, I have several c++ sources files as following: main.cpp: [code]#include "A.hpp" int main() { return 0; } [/code] A.hpp: [code]#ifndef A_HPP_ #define A_HPP_ #include "B/B.hpp" #endif /* A_HPP_ */ [/code] B/B.hpp: [code]#ifndef B_HPP_ #define B_HPP_ class Foo { int foo(int val); }; #endif /* B_HPP_ */ [/code] B/B.cpp: … | |
can more variables have the same value in an enum ? eg. [code] enum boolean { true = 1, false = 0, TRUE = 1, FALSE = 0 }; [/code] | |
Hi for my assignment i have to create my own greater than operator for a string class. Basically the class acts as the std string class library but i gotta edit the greater than operator in it. The assignment says upper and lower case should be treated as equal eg … | |
I have heard a lot of talk about hashtables from time to time. They are supposed to be very cool ways of storing data where the index you use to look up the data is somehow the data itself. But hashtables are not part of the C++ standard template library... … | |
I am completely new to C++. I want to know how to make a simple text program that takes user input and performs one of two operations depending on what the user entered. thanks for all help. | |
Hi i got an application that uses the mso.dll and MSOUTL.OLB : [code] #pragma warning(disable: 4146) #import "C:\Program Files\Common Files\Microsoft Shared\Office10\\mso.dll" named_guids #pragma warning(default: 4146) #import "C:\Program Files\Microsoft Office\Office10\MSOUTL.OLB" no_namespace exclude("_IRecipientControl", "_DRecipientControl") [/code] In which I'm trying to create an instance of the "Outlook.Application" in the following way: [code] _ApplicationPtr … | |
Hi everyone, I'm busy working on a program that needs to store settings somehow, and have the settings saved. I don't know how to do this, so I've written a test program. The object of the test program is to enter a 4-digit password, (sort of like a locker lock) … | |
I want to change the results of function deal() below which fills out a string array. In the watch window I can change the result of the memory location that the pointer points to, but not the string that begins at that address. Is it possible to keep the memory … | |
Hi, may I ask for a little help ? I don't know how to type a command for selected radio button. I mean - for example - if radio button is selected do this... I know there is a function KeyPress, but do not know how to use it, thanks … | |
Can Anybody Put Me Through Out To Add Image To My Database? I've Been Trying But Easy. Get Any Solution Pls Reply Me Or <Snipped>. Thanks. | |
A programmer has been asked to implement a simple game that requires the use of a board to position and manipulate some objects represented by symbols. The programmer has implemented the board as a two-dimensional array of characters. The following constants have been declared as global to the whole program: … | |
Hello, Finally I am down to the last issue with my program: text file writing and reading. My file has a function whose ofstream object does work and produces a text file for printing called "print". This function is the printTextFile(fstream &readFromFile ) function. But initially it is supposed to … | |
I have mentioned this before, I have to use turbo c++ in class. [B]Problem:[/B] I wrote the following code & to my surprise the code passed the compilation without any problem. I was even more surprised with the output. I just don't understand whats happening. This code won't compile in … | |
Please, can you help me to solve these problems??? I've compiled codes on linux with make command and.... THANKSSSSSSSSSSSSS trinity@trinity-laptop:~/a-saodv$ make gcc -Wall -pthread -g -DDEBUG -c -o main.o main.c main.c:3:20: error: config.h: Nessun file o directory In file included from main.c:12: /usr/include/linux/wireless.h:660: error: expected specifier-qualifier-list before ‘__s32’ /usr/include/linux/wireless.h:673: error: … | |
I am having some issues. I was trying to use my setToolName function to copy the string into the array – this would check if the string was too long. But then it does not capture 2 words, say if the string is “lawn mower”. So I started to use … | |
hey guys just joined the forum and so far it looks very promising :D got a quick question for everyone that can help, i am trying to organize a txt file to output the "gpa" from highest to lowest. Now this is what i have so far... [code]#include <iostream> #include … | |
Hello, im new to working with windows controls and im trying to create a simple listbox inside a main window. It compiles fine, but when i run it, the listbox is all screwed up and im fairly sure that my error message is trying to pop up (but for some … | |
Dear DaniWebbers, If you would all be so kind to help me, I have a problem here and I am trying to know why this happens... In a large application I am working on, I need to have a struct of some sort with a sub struct-array and the sub … | |
In my development com there's no issue of handling 4MB of text file data but it took about 1-2mins for my program to finish. I got a few questions here: Q1-> how much can this string "line" store? Q2-> should i use sstrm.clear() and line.clear() inside the while loop or … | |
Hello everyone!!, i have a question for you, do you know any libraries to develop wireless network in C/C++ but available for linux/unix?¿ Thanks!! | |
My program reads the data from the infile. But outputs the wrong results accept for lowest temperature -21 which is correct. I have played with the while loop where I believe the problem lies but have been unsuccessful in getting the right results. Can somebody steer me in the right … | |
I am just currently getting into programming, and was curious. I know you wouldnt call C an outdated language, but for someone like me, would it be best to learn c++ instead of starting on C? If im correct, C++ is object oriented and C is Structured correct? So if … | |
how can the searching code be created? i've made a program named address book. now i wanna make a function that can search an existing contact details from the file through 2 ways 1) search by name 2) search by phone No. kindly define me the code in C++ thx | |
Well i know the basic difference which is in C++ this is a pointer whilst Java is a reference to a class... I have a confusion though since am new in Java, can you reference a super class with "this"? more so, is the an underlying difference between the C++ … | |
Does anybody have any idea why the following code causes a memory error? Thanks everybody in advance :D [code=CPP]#include <stddef.h> // some older implementations lack <cstddef> #include <time.h> #include <math.h> #include <stdlib.h> #include <vector> #include <algorithm> #include <list> #include <deque> #include <set> #include <iostream> #include <iomanip> typedef double element_t; using … | |
I am currently working on a project to create a program to test a persons pitch perception. For this i need to be able to process a microphone input to find out what the note that is being sungs pitch is. What would be the best way to go about … |
The End.