49,757 Topics

Member Avatar for
Member Avatar for iansane

Hi, I am trying to learn how to read the binary of a file, such as a jpg. I got something going here but at run time in windows it says there is an error and the file must close. I'm not even sure if I'm going in the right …

Member Avatar for Ancient Dragon
0
879
Member Avatar for Vallnerik25

I have seen that I can use a variable as the specification for the dimension of a one-dimensional array to be allocated by the "new" keyword. The book I'm reading explains that this can be extended to two or more dimensions but with a restriction, only the left-most dimension can …

Member Avatar for Vallnerik25
0
106
Member Avatar for GGAB

Hi, I've searched far and wide but I haven't found exactly what I need. I have to programs communicating through named pipelines (windows XP). One is sending strings to another. The one who's recieves inserts them into an array. Now, here's the problem: this program is multi-threaded, each thread has …

Member Avatar for GGAB
0
140
Member Avatar for Shaun32887

My boss has recommended a hash table, but I'd like some second opinions as to what you think the best way to accomplish this task is. My problem is that I don't know C++, so I've been learning things as I needed them to finish this project. I'm kind of …

Member Avatar for Shaun32887
0
114
Member Avatar for Domino

I need to do a lookup to a table in Oracle from a dll. Can anyone tell me what's wrong with this line: pRs->Open(ptrQuery, "DSN=MY_DSN;UID=MY_ID;PWD=MY_PWD;", adOpenForwardOnly, adOpenReadOnly, adCmdText); The code compiles without error, but when invoked by the target application, the application errors out. (It works fine when not calling …

Member Avatar for Prabakar
0
109
Member Avatar for Q8iEnG

Hi guys :) Thanks first for the help, yesterday.. I really did well in my exam :), thanks a lot again :) Well, I guess I need a little bit help in this I have a file, and I want the whole paragraph in the file to be inserted in …

Member Avatar for Q8iEnG
0
115
Member Avatar for &rea

Hello! I have got an image and I want to change the value of his pixels and paste it into another image. pixel(r,c): is actual pixel b: changes from 0 to undetermined number, for example 100. The problem comes for example when b=2;I think that the method doesn't understand the …

Member Avatar for Prabakar
0
191
Member Avatar for mike issa

Im writing a code and included many library files (.lib) with it , when i compile all is fine 0 errors and 0 warnings , but when i built i got problems. when using VC 6.0 i got this warning [CODE]LINK : warning LNK4098: defaultlib "MSVCRT" conflicts with use of …

Member Avatar for mike issa
0
334
Member Avatar for mod_motox

Hi All, I work on C++, and I am using an number of hash maps in my code. The problem is that, erasing of all the map iterators does not work, I get segmentation faults. If I dont erase the iterators, then everything works fine. I am afraid if I …

Member Avatar for Duoas
0
173
Member Avatar for Beemer

Hi all , I have a program I have written for a question , but it has one problem I dont seem to be able to solve , the last part has to calculate the average hours spent on each module , yet it keeps coming up with answers I …

Member Avatar for Beemer
0
104
Member Avatar for flash121

Greetings, I'm trying to write a function which gets two pointers as parameters. The first one "points" to the start of the first linked list, the second one is currently on null, but it will later serve as a pointer to the start of another linked list. The function is …

Member Avatar for flash121
0
95
Member Avatar for cam875

Ok, a few questions on fstream with C++ and winsock 1. Is it possible to search all the tagged lines that say Item I.D. for a specific value that is a variable such as CharacterItemID is 108 than search all the tagged lines that say Item I.D. for 108 and …

Member Avatar for cam875
0
182
Member Avatar for bjaanes

Hi =) I am very new to c++ and have started messing around with some lines of code, but I am totaly stuck on this one: [CODE] #include <iostream> #include <string> #include <sstream> using namespace std; int main() { int antnames; cout << "How many names do you want to …

Member Avatar for Nick Evan
0
145
Member Avatar for integer*09

Hi all, the while loop in my code dont seem to be working as i wanted it to. I wanted it to constantly check if new data is available in the sample.txt but curently after the button click it just finished with one try. is it i put everything into …

Member Avatar for Ancient Dragon
0
137
Member Avatar for all blacks

The program i am working on currently need to read a file and write into multiple files. Basically i am supposed to separate all the classes in tat file so i actually added an comment line to the file, i extract the classes according to the comments. Now i would …

Member Avatar for mitrmkar
0
145
Member Avatar for Dannyo329

I 've linked the two files together, main.cpp and myClasses.h, I've declared a variable, but what I'm asking is can you access a variable from myClasses.h? Here's a example of what I got so far: [CODE] //main.cpp #include "myClasses.h" #include <iostream> using namespace std; int main() { ClassOne myClass_instance; s …

Member Avatar for Dannyo329
0
103
Member Avatar for TeCNoYoTTa

hello all i don't know what is the problem with this code when i choose a p for prof ........all the objects be prof objects and when i choose s for student all objects be student objects [CODE]#include <iostream> #include <fstream> #include <string> #include <vector> using namespace std; class person …

Member Avatar for TeCNoYoTTa
0
108
Member Avatar for himsymcpp

hi friends, I am working with file IO in C++, but there are some serious issues i am facing: 1) Initially I create some files(4 files), if they dont exists. 2) Then I read one file entirely i.e each record within the file, there are 30000 such records - 1 …

Member Avatar for himsymcpp
0
246
Member Avatar for vivek.m

Is there any way to directly post (using HTTP POST in winInet or using windows sockets) my login information like username and password to web servers like gmail? My query is more general - when we receive the data back from the web server in response to our GET request, …

0
42
Member Avatar for integer*09

Im able to copy the entire content of say file A to file B but the last line of file B end with several unwanted tttttt. I suspected the number of "t" is related to the number of line if read and written. Any advise will be greatly appreciated. file …

Member Avatar for integer*09
0
171
Member Avatar for crioto

I have some number: [code] int i = 43; [/code] I need to divide this number in to two digits. For example - 43, to get a 4 and 3. Help me pls)

Member Avatar for crioto
0
84
Member Avatar for Noxes

I just recently started programming about 3 weeks ago and I have to say, I really enjoy it. My question for this would be, what programs would you recommend for a novice programmer to begin writing? Which type of programs did you write? Any advice would be great. I do …

Member Avatar for Alex Edwards
0
92
Member Avatar for TheBeast32

Hi, is there a data type larger than unsigned long long int except double? I don't want double or float because I need to keep it as precise as possible. I also need it to be able to do modulus. How would I do this?

Member Avatar for TheBeast32
0
106
Member Avatar for TheBeast32

Hi, I am making a simple screen shot program. I need to be able to capture the entire screen, or if possible, a region of the screen (like a rectangle from point (25, 60) to (300, 456)). I also need to be able to save it to a bitmap file. …

Member Avatar for TheBeast32
0
1K
Member Avatar for SteveDB

My previous step hs been resolved. Now it's on to the next component. As previously stated, I am using a do-while loop with a switch-case. I've figured out how to state the functions that I'm calling to, and it now allows me past the main menu. Once I'm in however, …

Member Avatar for SteveDB
0
148
Member Avatar for SteveDB

Hi all. A while back I'd posted regarding a do-while routine, using switch. It appears that my main is working, and my switch.... it just keeps looping around my main menu. I'm not entirely clear on why either. Here is the code. (One responder to a previous post told me …

Member Avatar for SteveDB
0
81
Member Avatar for berge

Hi guys. I wrote a Win32 C++ program that uses C++ streams to open and read files. I log on a machine using a specific user (USER1) and password. It is supposed that this user has access to files spread across the network (file sharing). Therefore I'm using sentences like …

0
54
Member Avatar for Jennifer84

I wonder if it is possible to call the function void OneFunction() inside the buttoncontrol. [code] namespace Test1 [COLOR="Green"]{[/COLOR] public ref class Form1 : public System::Windows::Forms::Form [COLOR="green"]{[/COLOR] private: System::Void button1_Click(System::Object^ sender, System::EventArgs^ e) { // Is it possible to Execute/Call OneFunction() here ? } [COLOR="green"] }; }[/COLOR] void OneFunction() { …

Member Avatar for Jennifer84
0
110
Member Avatar for Jennifer84

I am trying to write an Interpreter but are not really sure about the methods that are used for this. What I think I have understood is for the example below, I will have to parse out 3 things from the string. "Number1", "==" and "2" and associate these to …

Member Avatar for Jennifer84
0
158
Member Avatar for scratchnloved

i have a few questions: 1. is there a way to change the window attributes on a console application? 2. is there a way to send commands to other windows/applets, like changing their attributes or closing them? 3. is there any way to cut console input to 1 keystroke, like …

Member Avatar for scratchnloved
0
117

The End.