- Strength to Increase Rep
- +7
- Strength to Decrease Rep
- -1
- Upvotes Received
- 12
- Posts with Upvotes
- 10
- Upvoting Members
- 10
- Downvotes Received
- 2
- Posts with Downvotes
- 2
- Downvoting Members
- 2
Hello Friends, As we know, when we have virtual function in our class, compiler smartly puts vptr(virtual table pointer) in our class to access correct function at run time. Can i access this vptr in my program, to use/manipulate this directly? Regards, Vivek |
|
I wrote a simple program to take input till the char array is filled up. But i seem to be getting a problem during runtime that the program takes input continuously and never stops. Pls help in identifying the problem.(there were no errors during compiling) [CODE] #include<iostream> #include<string> using namespace … |
|
Hello, I am doing simple read/write program for serial port. I am faceing a error that i donĀ“t understand. Error is: "error C2664: 'CreateFileW' : cannot convert parameter 1 from 'const char [5]' to 'LPCWSTR' " My whole program: #include <windows.h> #include <iostream> #include <string> using namespace std; void set_com_pin(bool … |
|
For Mobile Applications carbide C++ is better or j2me is better? |
|
as above. [code] string s; cin >> s; [/code] for example, if the user enters Orange, i want it to convert to orange. please advise what i should do. thanks in advance |
|
Hi.. Suppose I have a multimap like below [CODE] multimap<string, int> m; m.insert(pair<string, int>("a", 1)); m.insert(pair<string, int>("c", 20)); m.insert(pair<string, int>("b", 3)); m.insert(pair<string, int>("b", 4)); m.insert(pair<string, int>("a", 5)); m.insert(pair<string, int>("b", 6)); [/CODE] I want to print a output flags for first element, middle element and last element for multi map. Like … |
|
Hi all, Please help me in writing a program to find the similarity between two texts and return a percentage value. Code must be efficient . Regards, Raj |
|
I have this piece of code [CODE=C++]// some function int px; void SomeFunction( void *dummy ) { ... RECT rect; GetWindowRect(hWnd, &rect); px = ((rect.right - rect.left) / 2) - 60; ... // Terminate thread _endthread(); }[/CODE] And my problem is px doesn't get assigned.. it stays 0.. although in … |
|
I'm trying to load a bit map but the picture won't come up. It compiles just fine. I'm not sure if this makes a difference either but I am trying to load a bitmap into a dialog box. Here's the code: The .cpp file: #include "windows.h" #include "resource.h" HBITMAP g_hbmHang … |
|
I wrote a command pattern to my class Administrator, HR and Staff. Each of it has several MF but command only operate on single MF. Therefore, i got this design. I got the solution like this. CommandList composes Vector of command. [CODE] class GenericCommander; class ComamndList : public GenericCommander {}; … |
|
what's wrong with this line when I try to compile in C++?? The src code was originally in C. It gets an expected identifier error with my c++ compiler [CODE]typedef enum {false, true} bool;[/CODE] |
|
Can someone help me out. I haven't dealt with pointer function much. Here is the class definition for which it resides, although its only part of it. [code] template<typename Type> class vec2D { private: bool (*drawFunc)(unsigned int ID); unsigned int Col_id; public: //Enables each object member to have its own … |
|
Hey All, i'm doing this project in c++ consisting in reading an mp3 file and extracting the informations within it. Thing is i'm starting to be pissed by this persistent error that stops me from test the code. This error is, as far as my (limited) knowledge goes, caused by … |
|
Hi, I am pretty new to C++ but have lots of experience in java/c# and know the basics (classes/structures/pointers etc) but am having some problems linking to external source libraries. I am trying to use something called the openframeworks which I have downloaded and I need to include "\libs\openFrameWorks\ofMain.h" but … |
|
Hello, I compiled my trayicon utility c++ code in visual studio 2005 express edition and tray icon balloons showed up successfully but later I deleted my firewall, switched on to windows firewall and now I am on another firewall software. Now i ran my same project and balloons showed up … |
|
Hello..,, I have read about a function used in file handling named as "peek". If anyone knows about this function then plz tell me..... |
|
Please explain. Does it automatically include the default constructor? |
|
I can't get this code to work... [code=c++] typedef bool (* ProcessCallback)(DWORD ProcessId, DWORD ParentProcessId, TCHAR * Path, void * ImageBase, DWORD ImageSize); bool EnumProcesses(ProcessCallback Callback); // --------- class cProcessList { public: struct sProcess { DWORD ProcessId; TCHAR Path[MAX_PATH]; }; std::vector<sProcess> List; bool operator()(DWORD ProcessId, DWORD ParentProcessId, TCHAR * Path, … |
|
so, I have a program that uses a keyboard hook, but starts it in another thread so that it can continue executing. The problem is, the only way I have to stop the mouse hook right now is to just kill the thread using TerminateThread(). However, this does not enable … |
|
I am working on STL(map) in shared memory. How can it be implemented. I am successsful in creating the two process process1 : writing a text to the sahred memory process2 : reading the same text from shared memory. But now i am planning to implement the shared memory for … |
|
HI , i need help with a c++ code that downloads a single file from a DIRECT link and save it somewhere on the computer i am working under windows and i have searched google but i didnt find anything simple just tons of codes that i cant understand i … |
|
|
|
hi, can any one give an idea how to rewrite the .net url using cpp.how to integrate it with the ISAPI Headers in IIS. Regards, Prakash -------------------------------------------------------------------------------- |
|
Hello all, Note: This is a general question, and I did not find any other category in the forum to ask this question... Last year, I got a copy of VS 2008 (VC 9.0) as gift. I liked it a lot! I started developing some simple applications using C ( … |
|
i'm working on a school assigment with Binary search trees im trying to find the localtion of the smallest key in the binary nodes so i created a function that retutns the point location to the smallest element key [CODE] template <typename DataType, class KeyType> BSTreeNode * BSTree<DataType, KeyType>::findMin (BSTreeNode … |
|
hi folks, I have some 247 warnigs are same type warning C4996: 'fopen' was declared deprecated I am using makefile to compile my cpp program in Visual studio 2005. I have added _CRT_SECURE_NO_DEPRECATE in preprocessor definition too. but still I do get the warnings . Could anyone help me? |
|
I have a function under Base class and at the definition tine of this base class function I need to call another function which is define under the Derived class. how to do this?? My class declaration is below [code]class Base{ public: void showdata(double); }; class Derived : public Base{ … |
|
Man, I hate having to get you guys to hold my hand through all this, but I've run into another problem. I have my ODBC connecting to a MS access database. This is all coded into a library that gets injected into a video game, and then macro commands call … |
|
I have Tabctrl in a dialog.I want to set its background colour for each tab .I tried ON_WM_DRAWITEM but the control never comes in OnDrawItem().Can you help? #define RED RGB(255,0,0) #define YELLOW RGB(255,255,0) #define MAGENTA RGB(255,0,255) #define WHITE RGB(255,255,255) #define BLUE RGB(0,0,255) void CVMListDialog::OnDrawItem(int nIDCtl, LPDRAWITEMSTRUCT lpdis) { CDialog::OnDrawItem(nIDCtl, lpdis); … |
|
please download the VC++ express 2008 project attached. it has linker errors. please help me solve the problem. |