49,756 Topics

Member Avatar for
Member Avatar for Exelio

hi all, I am using ORCA to validate the product key in C# 2005 windows application. i am using the following C++ code in a dll to be added to the MSI for validation. [code] UINT __stdcall ValidateSerial(MSIHANDLE hInstall) { TCHAR szPidKey[PIDKEY_LENGTH]; DWORD dwLen = sizeof(szPidKey) / sizeof(szPidKey[0]); ///retrieve the …

0
93
Member Avatar for Queue

After writing out the main functionality for my templatized data structure, I am stumbling with the syntax to allow for Compare (so the user can provide a definition for less). If I am not mistaken, I need to add at least another constructor. I tried reading the STL implementations for …

Member Avatar for Queue
0
197
Member Avatar for balla4eva33

If I have a const char * of "bad,cold,new" how can I count just the number of commas? Do I need to convert it to string? If so, how do I do that? Do I need to convert all the commas to zeros first? How do i do that?

Member Avatar for balla4eva33
0
152
Member Avatar for White-Gandalf

Introduction: I already tried to post this on the dev-c++ - forum at sourceforge, but didn't check for the far too low frequency at that forum (about two questions per week). Thus i tried t find a better visited one and found this here. I use: Dev-C++ 4.9.9.2 Windows XP/SP2 …

Member Avatar for White-Gandalf
0
119
Member Avatar for Tell Me

hi may I bother you a moment :icon_redface: the follow program is without compilation error but whin I running , load error appear can you help me what is the error :( :( [CODE]#include <iostream> #include <string> using namespace std; bool function () { int ascii; string s1= "word" ; …

Member Avatar for iamthwee
0
83
Member Avatar for manster

I'm stuck because I recieve these errors when I try to compile - pim.cpp: In method `void PIM::search(class basic_string<char,string_char_traits<char>,__default_alloc_template<false,0> >)': pim.cpp:101: member `firstname' is a private member of class `Person' pim.cpp:101: member `lastname' is a private member of class `Person' pim.cpp:105: no matching function for call to `PIM::print (Person &)' …

Member Avatar for vmanes
0
176
Member Avatar for ryuhou

the questions is the following: Write a program that prints a table of the binary, octal and hexadecimal equivalents of the decimal numbers in a particular range the program should be somthing similar to the follow: 1. Convert a Decimal Number to Binary Number 2. Convert a Decimal Number to …

Member Avatar for zandiago
0
160
Member Avatar for kv79

#define ID_FILE_EXIT 40001 #define ID_FILE_OPEN 40002 And all other things like this which have these number .Which number i can use for my own ID 's ? And where i can find all of this? I try a MSND but it took me too much time so i ...?

Member Avatar for kv79
0
178
Member Avatar for nicz888

[code=c++] // Stopping input with an empty string #include <iostream> using namespace std; #include <cstring> int main() { int i = 1; char temp[80]; char string[80]; // room for 255 strings cout << "\n\nEnter some strings - (blank to exit)" << " \nfirst string: "; cin.getline(temp, 80); while (temp[0] != …

Member Avatar for neosomosis
0
124
Member Avatar for Fedien

Hello, so I'm a student in college and I'm new with C++ and I'm trying to make this program that allows me to read in names from a file, first name then last name, in Cstrings. Then I have to change it so that the output is "lastname, firstname". There …

Member Avatar for Salem
0
106
Member Avatar for alcoheca

Hi, I am storing strings in '|' delimited format in a text file. Each new line represents a new record. for instance [CODE]|Name|Age|Favcolour| |Name2|Age2|Favcolour2|[/CODE] I'm using a string vector to hold the tokens as they're pulled from the ifstream, However if one of the fields has not been filled in …

Member Avatar for alcoheca
0
91
Member Avatar for Nbkrooney

I am looking to make a small program that will cut down the repetetive need to insert BB tags in to achievements lists on a site I work for. So far I have got the algorithm sucessfully reading the first line of the file, and outputting it using cout. The …

Member Avatar for Lerner
0
161
Member Avatar for haelly

modularize program code by using functions. You will produce two solutions: a) using global access functions, and b) using classes and member functions. a) Using Access Functions Write five Invoice access functions: setInvoice(), computeAmount(), getAmount(), printData() and a global client function computeAmount(). Function setInvoice() has five parameters of types Invoice, …

Member Avatar for Narue
0
337
Member Avatar for rajatC

i want to calculate the exact run time of my program in [B]seconds[/B]....i used [B]clock() function of time.h library...[/B] what i did is that i made two [B]clock_t [/B]type objects... initialized one of them in the start of main() function and the other in the end.. and calculated the difference..as …

Member Avatar for Narue
0
190
Member Avatar for abhi_elementx

Hello folks! I have just joined this forum. This is actually my first Thread on the internet and need help with using STL sort function. I searched the forum but no related answer was found. Okay...here's my code; [CODE] #include<iostream> #include<vector> #include<algorithm> using namespace std; struct MyStruct{ int array[10]; }; …

Member Avatar for abhi_elementx
0
241
Member Avatar for tonyaim83

Hi.. I m working on Windows-Xp and building my project on Dev-cpp. The program compiles properly and i have also included the required dll file in the same folder of exe but when while running this application from command prompt it gives me following error message :- "[B]This application has …

Member Avatar for dubeyprateek
0
99
Member Avatar for manster

I'm clueless as to how to fix the errors in this contact information manager program. please help. Thanks in advanced [code=cplusplus] #include <iostream> #include <string> #include <fstream> using namespace std; struct Date { int month, day, year; }; struct Address { string street, city, state, zipcode; }; class Person { …

Member Avatar for Nick Evan
0
930
Member Avatar for likeno1

[B]How can I load an image to my code so i can make it as a background or I apply any function on it like rotate and scale only what I need is the function to load a(.jpeg or .bmp) and where to put it in my code[/B] #include "stdafx.h" …

0
60
Member Avatar for revenge2

hello there, i have been having some problems with dev c++. It just cant seem to compile my code. It says source file not compiled when i try to run the "compiled" program. Its like this;- i write my code (simple code stil beginner lol) and i go compile it …

Member Avatar for Nick Evan
0
82
Member Avatar for kv79

Hi to all, Function Information Minimum DLL Version user32.dll Header Declared in Winuser.h, include Windows.h Import library User32.lib Minimum operating systems Windows 95, Windows NT 3.1 How to use user32.dll in Dev-C++? Where to find User32.lib ? I tryed in C:\windows\and Dev-C++. Where is the diffrence in Header betwen Declared …

Member Avatar for kv79
0
81
Member Avatar for ArrogantLegend

[CODE] // War Game made by Jeremy Wayman #include <iostream> #include <cstdlib> #include <ctime> #include <fstream> #include <string> using namespace std; int cardValue[13] = {1,2,3,4,5,6,7,8,9,10,11,12,13}; // Declaring first array string cardType[4]; // Declaring second array ifstream inFile; // Declaring a reading inFile void displayRules(); // Declaring function displayRules bool winner(int …

Member Avatar for Ancient Dragon
0
87
Member Avatar for jrice528

In my program I am using the do-while loop to go through program.. my question is how do I loop the program without the do-while loop... rather that when the user enters menu number 0, it quits the program... Teacher uses a script to grade the programs and on hsi …

Member Avatar for WaltP
0
131
Member Avatar for stokey

I'm trying to get the program to loop back to the friends array and re-compare the two user inputs again and keep doing it until the 2nd input is the same as the first. We haven't covered this yet in my class but could someone help me to find this …

Member Avatar for stokey
0
98
Member Avatar for picklesandmayo

ok, so I have been working all day on this program and I am kinda stuck. The goal is to have a user input several words, then (ignoring case) alphabetize them (using [ICODE]qsort()[/ICODE] only) and count how many times each word was used. This is what I've got so far: …

Member Avatar for picklesandmayo
0
98
Member Avatar for weewee

Can anyone help me how to write the following codes in different ways. I used Linked List. template<class Item> ttt<Item>::ttt() { square=0; board=new node<Item>; for (Item i='9'; i>=1; i--) { list_head_insert(board,i); } } template<class Item> void ttt<Item>::clear() { list_clear(board); square=0; board=new node<Item>; for (Item i='9'; i !='0'; i--) { list_head_insert(board,i); …

Member Avatar for people123
0
959
Member Avatar for jobs

I am looking at the code which has the following: read(conf_fd,conf,100); Can someone tell me what these parameters are passed to read function?

Member Avatar for WaltP
0
89
Member Avatar for xeption12

Hello there :) I have recently started learning lists in C++, and I just do not understand what is the advantage of lists over arrays? I only see disadvantages, like: they're harder to implement, harder to manage, a little bit confusing, and so on... So, i know i'm a n00b …

Member Avatar for Jishnu
0
106
Member Avatar for jobs

I need to create a program and have it create a lock file so that only one instance of the program can be run at any one time. I came across this code: [CODE=c] for (tries = 0; tries != maxtries; ++tries) { fd = open("/tmp/some.lock.file", O_WRONLY|O_CREAT|O_EXCL, 0644); if (fd …

Member Avatar for Duoas
0
144
Member Avatar for balla4eva33

Given main: [CODE] #include <iostream> using namespace std; #include <stdlib.h> #include "minivector.h" #include "bubbleSort.h" #include "Fraction.h" int main() { int arr[]={99, 12, 50, 80, 1, 79, 20}; cout << endl << "bubbleSort ints" << endl; bubbleSort(arr, 7); for (int i=0; i < 7; i++) cout << arr[i]<< endl; double arr2[]={99.2, …

Member Avatar for balla4eva33
0
188
Member Avatar for peeta

hello every one this is first time in this forum and very first post. I am really interested in learning c++. I am mac user and before i start learning c++ could anyone Please tell me if i need different version of c++ complier or i will be fine with …

Member Avatar for darkagn
0
85

The End.