Hi,
I have a class which inherits from CListCtrl class, say class list.
I have another class dlg, which inherits from CDialog.
Class dlg contains an instance of class list.
I have got a delete button in class dlg, on which I delete the selected item in listCtrl and do lots of other processing.
I want the same functionality on delete k...
I have a solution, mostly C#, but with a few VC++ projects, that is pushed through our standard release process (perl and bash scripts on Unix boxes). Currently the initiative is to validate DLL and EXE versions as they pass through the process. All the versioning is set so that File Version is of the format $Id: $ (between the colon and...
an ActiveX control generated by Visual Basic 6, very old stuff, it has a couple of methods and one event.
now I have to use the control in C++, visual studio 2008, but I don't like to generate a form/dialog/window as constainer. I add some MFC class From ActiveX Control. Now the wrap class has all the methods defined in the ActiveX co...
I am just starting with cpp and I've been following different examples to learn from them, and I see that buffer size is set in different ways, for example:
char buffer[255];
StringCchPrintf(buffer, sizeof(buffer), TEXT("%s"), X);
VS
char buffer[255];
StringCchPrintf(buffer, 255*sizeof(char), TEXT("%s"), X);
Which one is the correc...
I don't understand exactly how to use a function that returns a boolean. I know what it is, but I can't figure out how to make it work in my program. I'm trying to say that if my variable "selection" is any letter beween 'A' and 'I' then it is valid and can continue on to the next function which is called calcExchangeAmt(amtExchanged, se...
I am developing a program in VS C++ 2008.
Right now, I have a huge list of dll and lib dependencies and I am adding some more. I worry that when I need to update a dependency by building from source (where I have to manually replace built dlls and libs in the correct place), if I accidently forgot to replace something or vice versa, I m...
hi!
I have two precompiled library: X.a and Y.a and a test.cpp (without main function) source code use these two libraries.
I compiled the C++ using:
g++ -c test.cpp
and I got 'test.o'.
Now how can I link these three together to generate a .a file because test.cpp use some function in X.a and Y.a and other GCC libraries?
BTW, I am...
I'm using the folowing code to read files from a folder in windows. However since this a MFC application I have to convert the char array to UNICODE. For example if I hard code the path as "C:\images3\test\" as shown below the code works.
WIN32_FIND_DATA FindFileData;
HANDLE hFind = INVALID_HANDLE_VALUE;
hFind = FindFirstFile(_T(...
Hello,
nowadays I have this piece of code:
#import "C:\Users\Public\SoundLog\DLLs\ForPython\SoundLogDLL.tlb" named_guids
but I want to substitute the C:\Users\Public part by the %PUBLIC% environment variable.
How can I do this ?
...
I wish c++, was a little more specific on the messages they give. The following error is being thrown in the document below
main.h
#ifndef main_h
#define main_h
//includes
#include <windows.h>
#include <commctrl.h>
#include <d3d9.h>
#include <fstream>
#include "capplication.h"
//constants
#define TITLE "D3D Tut 01: Creat...
Does VC++ 2010 have support for C++0x's portable atomic type template?
...
I'm just starting out with x64 compilation.
I have a couple of char*'s, and I'm subtracting them.
With a 32-bit compile, this works:
char * p1 = ....
char * p3 = ...
int delta = p3 - p1;
But if I compile for x64 I get a warning:
warning C4244: 'initializing' : conversion from '__int64' to 'int',
possible loss of data
Wha...
I have an existing C codebase that works on x86.
I'm now compiling it for x64.
What I'd like to do is cast a size_t to a DWORD, and throw an exception if there's a loss of data.
Q: Is there an idiom for this?
Here's why I'm doing this:
A bunch of Windows APIs accept DWORDs as arguments, and the code currently assumes sizeof(...
I have hide my custom made IE 7 toolbar button using TB_HIDEBUTTON in runtime.
I have problem to bring up the button back. Can I use ShowBrowserBar to bring it visible back?
...
hello to every one,
i am new one to this site and this is my first query...
i need simple Sliding window algorithm implementation in c++ or matlab
please help me in this regard
thanks
...
I am working on MS Visual Studio. I keep on getting this error:
"Run-Time Check Failure #3 - The variable 'test' is being used without being initialized."
I don't have any idea how to solve this. Here is the code that I'm currently tries to modify:
STDMETHODIMP CButtonDemoBHO::Exec(const GUID*, DWORD nCmdID, DWORD d, VARIANTARG*, VAR...
Hello,
I have an exe file that accpets parameters. For example,
a.exe parameter1 parameter2 parameter3
the problem is that I am not sure what parameters areavailable. Is there a way to find out it? the exe is complied by visual c++.
Thanks.
...
I finally managed to get a texture onto a cube sadly, but it is appearing incorrectly. as the below picture identifies.
Anyways, I am not sure what it could be. My first guess is it could be my uv mapping or my vertex positioning is off. If someone could check and make sure thats good. The first element is the vertex position, second...
I'm involved in one of those challenges where you try to produce the smallest possible binary, so I'm building my program without the C or C++ run-time libraries (RTL). I don't link to the DLL version or the static version. I don't even #include the header files. I have this working fine.
Some RTL functions, like memset(), can be use...
Hello,
when including "sqlite3.c" into my project, I get lots of compiler errors:
error C2027: use of undefined type "_ht" d:\...\sqlite3.c line 19556
...
fatal error C1003: Errors in the program are too numerous to allow recovery. The compiler must terminate.
When inlcuding "sqlite3.c" into an empty test project, I have no pro...