Quantcast
Channel: CodeGuru Forums - Visual C++ Programming
Browsing all 3026 articles
Browse latest View live
↧

Image may be NSFW.
Clik here to view.

ListBox entry not deselected

Hello, Normally, if you select an entry in a ListBox, the previous one is automatically deselected. This works well if both entries are visible in the ListBox. I do however have a strange ListBox...

View Article


Image may be NSFW.
Clik here to view.

How to play wav file without blocking application with xaudio2

Hi! I am using xaudio2 to trigger very simple 100 ms .wav files. The timing is very important in this application, and when the mouse is clicked, the application sends a trigger to the parallel port,...

View Article


parsing xml file using xerces c++

Hello, I am novice user, trying to parse XML file using xerces c++ on windowÂ’s visual studio 2013. I did the following steps: 1.download and unzip the xerces 3.1.4 file 2.trying to do sample program of...

View Article

How do I return a reference to this without a copy?

I have a bunch of functions that I want to chain together so I'm having the object return itself each time. This works in every compiler except for Visual C++. Why does this code Code: jwLog &...

View Article

Token Pasting Question

I want to paste a prototype signature in every call like this Code: //tLocalAlloc newdata = HookedLocalAlloc; // ##1 void* newdata = hs.hookerFunc; For the first line, it is already working. But the...

View Article


std::vector::data()

I'm building a 3rd-party library where there's a class where one of the functions returns this:- Code: return m_window.data(); m_window is a std::vector of ints. Unfortunately, I'm building with MSVC8...

View Article

How to compare two different values from reading the text file

Code: void mostUnique(ifstream& in, ostream& out) {         in.open("problem15Text.txt");         string line;         int period = 0;         int unique = 0;         while (getline(in, line))...

View Article

Converting from const double* to const float*

I'm compiling a 3rd-party library which has a function like this:- Code: void some_func (const double* var) {         some_other_func (var); } Unfortunately, some_other_func() expects a const float*...

View Article


[RESOLVED] Class inheritance problem.

Hello, I was searching on the internet for my answer but I found nothing. All I want to make is Object that can move sf::Recrtangle or sf::Sprite. For example: For example: Code:         class Movable...

View Article


Iterator initialization problem...

This code apparently compiles with gcc but is giving me a compiler error with MSVC:- Code: namespace { struct id_compare {         bool operator()(const boost::shared_ptr<Playlist>& p1, const...

View Article

Correct Open CDaoRecordset throws exception

For CDaoRecordset I try to call: Open(dbOpenDynaset,"SELECT adresa,objekt,typ,stanice,cesta,hodnota,cas,user,ip FROM Povely WHERE (cas>'2016-10-14 8:22:41') ORDER BY cas ASC;") but it throws...

View Article

Java to C++

Hi guys, ** I have a problem and I'm in need of help. Can anyone maybe help me a little?* I have a code written in Java that runs on ImageJ/Fiji software (https://fiji.sc/).* I want that code to be...

View Article

FlashWindow Doesn't Work On Minimized Program

Environment: VC++ 6.0, Win7 I'm trying to use CWnd::FlashWindow() to flash the program's TaskBar icon. I'm using the system timer to call FlashWindow() six times (about every second). When the program...

View Article


Project Help

I need a way to compare a number to the amount of times a string was entered. In my project i need to make sure that when a category for a bunch is selected like 'P' for pretty_category or 's' for...

View Article

non-static member reference must be on a specific object

I have a main.cpp, validationFormat.cpp and validationFormat.h I want to cout my bool function in the validationFormat.cpp from my main.cpp. in my main.cpp I am including my validationFormat.h. Which...

View Article


SSE programming - no speedup

Hi everyone, I'm trying my hand at SSE programming and at this point in time using SSE does not seem to result in a speedup for me. This as opposed to example code where I do see such a speedup (for...

View Article

GetFieldValue is too slow

I read from MS SQL Server using CDaoRecodset. There is a shortcode: Code: CDaoDatabase *db; db = new CDaoDatabase(); db->Open(NULL, FALSE, FALSE, _T("DRIVER={SQL Server Native Client...

View Article


How is it possible to build a shell of my own?

I want to build a shell for windows 7 in which it consists of a task bar, file manager, main menu, context menu and other stuff, Are there any tutorials on that. In case your answer is litestep, I am...

View Article

binary search in a file

So i have this code where i open a file and store all of the words from it into a vector. I'm suppose to take in user input and look into the file and see if it's a word using a binary search. I have...

View Article

turn user input into scramble

I need to take user input of a word and make the word scrambled for however long it is. so if it was 4 letters 4 scrambles, 5 letters 5 scrambles... etc. here is what i have so far Code: #include...

View Article
Browsing all 3026 articles
Browse latest View live