49,755 Topics
![]() | |
I was given an assignment to complete on database, i have created on but crashes after executing once, check it friends and please help, if you can modify or make it way, i'll be graceful. Please find the coding in attachment section. thanks hope will get good response | |
Hi Everyone, I want to seek advice on how to acquire to strong background in Client-Server Programming, i mean learn it from scratch since having no knowledge about it but with networks Thanks | |
Hi, I use the stl features to deal with string conversions, especially facets. Now, I am faced with the task to lower a string except its first letter. Please note that I am dealing with multi-byte characters and so I cannot simply replace the first character of the string with … | |
i have write that code i m new in programming this code doesnt work in one source file but when i type exact same in other file it start working [CODE]#include <iostream.h> main() { char std1[20], std2[20] cout << "enter your name student"<<"\n"; cin >> std1; cout << "enter your … | |
Hi, I'm trying to link c object with c++ (using QT Library) object and find the following error. tonysun:~/tmp# g++ -c main.cpp tonysun:~/tmp# gcc -c mainlib.c tonysun:~/tmp# g++ -o main main.o mainlib.o [ICODE]main.cpp:(.text+0x64): undefined reference to `para_prep()'[/ICODE] <<main.cpp>> [CODE]#include "mainlib.h" int main(int argc, char *argv[]) { para_prep(); /* Here are … | |
Hi all, I have some code as following. BOOL qw = ExtractResource(AfxGetResourceHandle(), IDR_DLL1, _T("C:\\VBDLL.dll") ); bool ExtractResource(const HINSTANCE hInstance, WORD resourceID, LPCTSTR szOutputFilename) { /*LPTSTR sArgv = argv[1]; LPTSTR sArgv2 = argv[2];*/ TCHAR sResName[5] = _T("#101"); TCHAR sRestype[4] = _T("DLL"); HRSRC hres = FindResource(AfxGetResourceHandle(), sResName,sRestype); if (hres == 0) { … | |
Hi.. I am working with vb.net .. I am new in vc++. I need to write some code in vc++ in some case. I need vc++ for following reason. I created one dll in vb.net and make a tlb file based on vb.net dll. I import physical tlb file in … | |
So with my program I'm trying to count the number of operations it takes to perform a insertion sort/quick sort. And because functions are calling other functions from inherited classes, it gets a bit confusing as to where I can place the operation to increment the number of operations. Right … | |
I have been trying for about 6 hours to get this program to work. It's a C++ program for for loops. I am trying to go through a book, but I don't have source code for how this should be. I need to make a program that looks like this … | |
I have this code written. One of the problems that I am having is in "Test 6". It should be totaling to $1.11 but it is totaling to $1.8 because it is switching the 6 and 3 and I cant figure out why. Another problem is that for some of … | |
So i need to find a way to prompt the user for an answer (cin) while a timer is running. Like if the user doesn't answer in time then... or after a certain period of time passes an event occurs. Please Tell me if i'm being too vague. Thanks | |
[CODE]// test.cpp - Script 6.7 #include <iostream> // Function prototype. // Function takes two arguements. // Function returns no values. void changeVar(int *myVar, int newValue); int main() { // Create a new variable. int myNum = 20; // Print its current value. std::cout << "myNum is " << myNum << … | |
I am creating a Win32 Dll Wrapper around my C# class library. I am able to pass string from my C# to C++ application. But i am not sure as to how can i pass string array in Win32 C++ project. [CODE] //C# code void Test(string lFile, int ver); //C++ … | |
How can i get th execution time ?? I tried to use library <time.h> [CODE] clock_t tStart = clock(); //put here my code double executionTime=(clock() - tStart)/CLOCKS_PER_SEC; [/CODE] here the excution time always zero. so what's the error here?? | |
[CODE]int main() { FILE *fp; unsigned long size; unsigned char *loc; fp=fopen("Hello.exe","rb"); if(fp==NULL) { printf("\nCouldn't load file"); getchar(); return 0; } fseek(fp,0,SEEK_END); size = ftell(fp); fseek(fp,0,SEEK_SET); loc=(unsigned char*)malloc(sizeof(size)); printf("\nSize of file is : %d",size); if(loc==NULL){ printf("\nError in allocating memory."); } printf("\nFread called"); fread(loc,size,1,fp); printf("\nFread fails:"); return 0; } [/CODE] I … | |
I have a text file for example abc, cde,fgh, jkl, rty qwe,erty, tyujk,werty , lkjh I want to read these tokens from the text file, into different variables row wise (ie one row at at time) Number of tokens in a row is fixed. (ie 5 in this case) Please … | |
Hello, I haven't done any work with reading or writing from/to files in C++, I think we did some C in school but its all a little fuzzy at this point. What I need to do is store the values for a couple different functions in a text file, have … | |
Hi guys, I need to implement a program for simulating the flooting algorithm. Can someone suggest from where to start. I will use structs or classes? How the flow of the program will be? | |
is there a way to convert from pointer array to array I tried the following, but it doesn't work. [CODE] int[]a={1,2,3}; int* p; p=a; a=(*P);// doesn't work [/CODE] | |
I`m new in Programming stuffs. So here is my codes: [CODE]#include<iostream.h> #include<conio.h> float records[5][5]; float ave; int ctrX, ctrY; main() { clrscr(); ctrY=0; for(ctrX=0;ctrX<=4;ctrX++) { cout<<"Student Number: "; cin>>records[ctrX][ctrY]; ctrY++; do { cout<<"Quiz 1 Score: "; cin>>records[ctrX][ctrY]; if ((records[ctrX][ctrY]<0)||(records[ctrX][ctrY]>30)) { cout<<"The score supplied must be from 0 to 30 only!" … | |
Hello all, So I am just playing around with different ways to format output to the command line in c++. I already found information on how to change the color of standard output (both in Linux and Windows). Is there a way to highlight output to the command line? I … | |
Hello again guys, I've got kind of a noob question. I have a wchar[260] and I need to compare it with a char* and im getting the error error C2664: '_stricmp' : cannot convert parameter 1 from 'WCHAR [260]' to 'const char *' Thanks! | |
anybody can help me? How to culculate totalsale for each division.. I've tried many time but failed.. my coding is below [ICODE] #ifndef DIVISIONSALE_H #define DIVISIONSALE_H class DivisionSale{ private: double sales [3]; double totalSales; public: DivisionSale(double,double ,double ,double); double getQuaterSale(int); double getDivisionSale(); void culculateTotalSale(DivisionSale[], int); }; #endif[/ICODE] [ICODE] #include "DivisionSale.h" … | |
Anyone can help me to write a code in C++ to reverse a string. Example: i/p= " string with space " o/p= " ecaps htiw gnirts " Better if we use function or class. Thanks in advance | |
As part of a school assignment, I have to analyze a binary and determine what is does and what it takes to cause the various "branches" (if statements) to be triggered. I performed a strace on the file and the only part that stands out is a gettimeofday call: [CODE]gettimeofday({1303744469, … | |
Hi all, I am constructing a program on TCP sockets. The server should be able to accept connections from more than 1 clients. My programs seem working fine when accepting connections. Now the problem is: when I try to terminate one of the client programs, the server program would also … | |
Hi guys: I am constructing this simply code to read a number of columns in a file, get a number and produce a new file. I am just not certain what is wrong. I used the same standard as an old code of mine so it should work but I … | |
OK im having a problem which I feel should be super easy within windows API gui programming, but I dont know how to go about it the right way. On a givin HWND when a single mouse click is qued and my program recognizes it and my windproc processes it … | |
I've been searching this for a little while now and I'm absolutely unable to figure out what the problem is. This is the code I'm having the issue with: [CODE] std::vector<std::string> TexName; TexName.push_back("mega.png"); [/CODE] and I get... error: 'TexName' does not name a type I've included both vector and string … | |
[CODE] #include <iostream> #include <vector> #include <iomanip> using namespace std; class DAI //DynamicArrayInput { public : void getCountry() { cout << "Country : "; cin >> Country; } void putCountry() { cout << Country << endl; } static int putCount() { return count; } private : static int count; char … |
The End.