49,761 Topics
| |
What are some hints or tips on writing efficient functions? I read about converting the code to assembly, and I've also read about the stack and functions. However, I fail to understand how data stored higher can be accessed before the end on a FIFO stack, as any local variable … | |
Hey again ...:P Now i have problem with save & load from/to text file. [CODE]private: System::Void zaĆadujPlaylisteToolStripMenuItem_Click(System::Object^ sender, System::EventArgs^ e) { OpenFileDialog^ dig = gcnew OpenFileDialog(); dig->Filter = "PlayList(*.PLS)|*.PLS"; if(dig->ShowDialog() == System::Windows::Forms::DialogResult::OK) { listBox1->Items->Add(IO::File::ReadAllText(dig->FileName)); } } private: System::Void zapiszPlaylisteToolStripMenuItem_Click(System::Object^ sender, System::EventArgs^ e) { SaveFileDialog^ dig = gcnew SaveFileDialog(); dig->Filter = … | |
So, this is probably a bit abstract, and I apologize if the title was imprecise: I have a simulation class, which contains a vector of objects of class A, the member functions of which depend on parameters a,b,c: [CODE] class SIMULATION { vector<A> array; }; class A { A(a,b,c); } … | |
2D vector data types should be different or same only .. for ex:: for one sub script with int data type and with another subscript with class name is it possible to declare with diff. data types | |
Hi! my dear all. [CODE]#include<iostream.h> #include<stdlib.h> #include<fstream.h> #include<conio.h> #include<stdio.h> class payroll { private: char address[50]; float basic,allowence,deduction; public: void add(void); }; void payroll::add(void) { clrscr(); int e_no,choice; char name[50],ch; payroll e; cout<<"Enter Employe Number: ";cin>>e_no; cout<<"Enter Employe Name: ";gets(name); cout<<"Enter Employe's Address: ";gets(e.address); cout<<"Enter Employe's Basic Salary: ";cin>>e.basic; cout<<"Enter Employe's … | |
Hi pals, I try a code in my Dev -C++ Environment v 4.9.9.2 in Windows XP. I save file as "satwant_mysql.cpp" in E:/C++/ Directory.... [CODE] #include <mysql/mysql.h> #include <stdio.h> int main(){ MYSQL mysql; MYSQL_ROW row; MYSQL_RES *result; unsigned int num_fields; unsigned int i; mysql_init(&mysql); if (!mysql_real_connect(&mysql,"localhost","root","","MyDatabase",0,NULL,0)) { fprintf(stderr, "Failed to … | |
Hi everyone. I'm facing a tricky problem with keyboard hooks in visual c++ (MFC). I have two global keyboard hooks set in my application and everything works smoothly when windows explorer is running. But my application needs to run without windows explorer (in kiosk mode), so i replace explorer.exe with … | |
Hello. How can I protect my application against Memory Editors? Like, Cheat Engine, Debuggers, etc. | |
Hello everyone. I've been trying to implement a linked list in C++. I found this implementation on the web, where they created a struct for the list's nodes. When trying to add a new node to the list, I get this error: [B]List.C: In member function `bool Linked::addNode(Point)': List.C:23: error: … | |
Dear all, I need your help on tis programming assignment I have. I need to save all the atrributes information to a signle file. I need to have 2 options : Save to a default name backup.bak and to a users filename choice. I have found this code in an … | |
i have this and i can not solve it plz l do not have time :( Write a program that print the prime factorization of all the number n between 2 and 100 .if n is a prime , your program writes that it is so . otherwise it should … | |
Hi everybody, I really need that code, I have a text file 32 4 12 13 4 12 0 0 0 0 0 3 2 3 4 and I want to convert it vector or array like A[2]={32,4} B[4]={12,13,4,12} C[9]={0,0,0,0,0,3,2,3,4} The size of the vector or array can be changed … | |
i cannot find any information on this topic, but im curious as to the point in chaining hardware breakpoints and how it can be done! any information is greatly appreciated! -thx | |
Allright dudes ,listen up .. i am programming C++ about 2 days now , so i am not into it , in any way , so the problem is that the preproceccor macro #define should trigger the constructor , but the problem is that i got that annoying compiler error … | |
I need to calculate the network bandwidth in LAN. But i don't have any idea about it .Help me how to calculate it. Thanks in advance. | |
how i make this prog i am trying my best but did,t make [ICODE]**** * * * * ****[/ICODE] and ths [ICODE] 1 123 12345 54321 321 1 [/ICODE] pls send me at [I]<<snip>>[/I] | |
We have been working to solve the issue early in the morning. This is a sample code to clearly show the situation. There are also more than 100 tables are waiting to get their records to calculate the results . Any idea ? conn.h #include "stdafx.h" static double global ; … | |
I'm not used to getting this deep in c++, but all these pointers are making my brain boil. I'm trying to get a str_replace working [CODE]VOID str_replace(PCHAR Dest, PCHAR Find, PCHAR Replace) { PCHAR New=(char *)malloc(sizeof(CHAR)*MAX_STRING); PCHAR Found = Dest; PCHAR Temp = Dest; strcpy(New,""); while(strstr(Temp,Find)) { Found = strstr(Temp,Find); … | |
Hello, [font=courier new][u]Brief Tutorial Revision[/u]: All examples can be compiled successfully in your compiler. Also, each example is compatable using the [b]-Wall[/b], [b]-pedantic[/b], [b]-ansi[/b], and [b]-std=c89[/b] GCC flags. Also, a few paragraphs have been modified, and code examples improved. Previous tutorial, Pointers #2, has been combined in this revision.[/font] [b][u]Introduction[/u][/b] … | |
hi I have been working in this code for a while and I need to know what's wrong with it ASAP. here: [CODE]#include<iostream> using namespace std; class Node { public: int value; Node * next; Node(); Node(int); }; Node::Node():value(0),next(NULL){} Node::Node(int v):value(v),next(NULL){} bool AllPositive(next * h) { bool test = false; … | |
I am using ADODB for connecting ms-access database from a vc++ application.I want to insert record in access database;but if the record already exists in the access table then update query should run instead of insert query. the above task can easily be done with stored procedure, but since ms-access … | |
Dear all, I am a newbie in this side and I need your assistance. I need to delelop a compiler that accepts text as input. I need to manipulate this text as follows. Where there is title to center the text and make it bigger font. We dont know where … | |
Hi, I am newbie to c++. I would like to en quire on how to calculate the number of same alphabet in a string that we enter? For example if let say i have entered ABAAGAYHAUIJA and it should return 6. Here's my code. [CODE]#include <iostream> #include<conio.h> using namespace std; … | |
I cannot copy random numbers without repeating in a map. Unhandled exception at 0x0040115e in file.exe: 0xC0000005: Access violation writing location 0xabababaf. [CODE]int **map; int randomize(int numberToSelect,int range,int counter){ int* remainingNumbers = new int[range]; int* chosenNumbers = new int[numberToSelect]; for(int i = 0; i < range; i++) remainingNumbers[i] = i; … | |
I have a project with a bunch of different options that you can turn on and off sprinkled throughout many files. You comment and uncomment the options you want, much like the php.ini file in PHP file, though this is actual code. It looks something like this: [code] //#ifndef _OPTION_1 … | |
when i compile program then error are show in program that #include<iostream.h> or #include<conio.h> are not find. i also changed my directory that c:\tc\include or c:\tc\bin also but program not run error show that unable to with file include iostream plz tell solution of this. | |
salaam,hope u will be fine,can anyone help me how to do coding for a scientif calculator which perform only the following function.Addition,Subtraction,Multiplication,Division and calculte different values for cos,sin and tan. | |
Dear all, Maysomeone help me with this functions? I have entries in my classes and I need to initialize entries into other classes. To be more specific: I have Customers and Flights and I need to use this fuction to insert customers to random destinations. |
The End.