-
- Color a progressbar: PBM_SETBATCOLOR seems not to work
by U412
- 9 Replies
- Last post
by Sahir Shah
- Hi everyone...
I use following code:
Code Snippet
COLORREF color1, color2;
color1 = m_ProgressGreen.SendMessage(PBM_SETBARCOLOR, 0, (LPARAM)RGB(255, 0, 0));
m_ProgressGreen.Invalidate(TRUE);
color2 = m_ProgressBlue.SendMessage(PBM_SETBARCOLOR, 0, (LPARAM)RGB(0, 0, 255));
m_ProgressBlue.Invalidate(TRUE);
There is no effect, whethere i
-
- Can't run on other machines!
by Alireza Noori
- 14 Replies
- Last post
by Alireza Noori
- Hi, I have posted this message 2 times but it doesn't work so please help me. Please help all of the message before you post a reply. I have made a program (a simple one) with C++/CLI (CLR) and built it. It's working well on my PC but when I copy it to a CD and take it to another computer (even if .Net Framework 2 is installed) it doesn't work. In other posts many people sent me replies telling me
-
- Problem with Active Accessibility and OLE lock count
by Florian Heidenreich
- 1 Replies
- Last post
by Florian Heidenreich
- Hello! I've noticed an irritating behaviour of the Windows Magnifier and a standard single document MFC application generated by the new project wizard of VC++ 8.0 with enabled support for Active Accessibility and even without enabled Active Accessibility when using a CFormView based view. As soon as the Windows Magnifier (magnify.exe) is running, an accessible proxy is created through CWnd::Cr
-
- volatile, somewhat puzzled (C not C++ question)
by Hugo6003
- 13 Replies
- Last post
by Hugo
- Hi
I have used volatile many times on several platforms, but I'm seeing something puzzling.
We have code (our own fast read/write spin lock, coded in C). And although it runs correctly both debug and release builds, I am puzzled over what I see in the debugger memory window when running a release build.
The lock data is declared as a typedef volatile struct ...
in deb
-
- vcproj: How to save debugging settings into portable vcproject?
by Stuart Reynolds
- 13 Replies
- Last post
by Simple Samples
- I want to be able to distribute vcproj files to customers with custom debug settings in the project configuration. It seems that whenever I set the fields in the project's Properties dialog, the changes are saved into some new non-portable ".user" file, and not in the ".vcproj". For example, if I do:
Open MyProject.vcproj
Go to: Project > Properties > Configurati
-
- Having differently colored characters in a RichEdit 1 control
by Jehjoa
- 5 Replies
- Last post
by Pintu Shukla
- Hello everyone, first post here. :-) I am currently experimenting with the RichEdit control, trying to beat it into submission. What I'm trying to do is have text entered in a certain color, then let the user change color, and continue typing in that color. I expected this to be a pretty trivial task, but I was wrong. Currently, the RichEdit control is being initialized with default settings, whi
-
- dllexport a private member of an exportable class
by Hicham Mouline
- 9 Replies
- Last post
by Holger Grund
- Hi, here are relevant excerpts of the code:
main.cpp (Project main)
#include "Tree.h"
int main( int argc, char * argv[])
{
...
const Tree<AmericanPut,CRR>& m = Tree<AmericanPut,CRR>::getModel();
...
}
Tree.h (Project DLL)
template <typename cT, template<const int> class tT, const int ntree =2>
class F
-
- Asynchronous Sockets in C++?
by yabansu
- 14 Replies
- Last post
by abcdefgqwerty2
- Hello,
I want to use asynchronous sockets in pure C++.
Is there anyone to tell me how to do it or at least show me a basic example
The external libraries are appreciated too.
Thanks...
-
- How can I limit the no of lines in an EditBox
by shibumong
- 3 Replies
- Last post
by Damien Watkins - MSFT
- Hello,
How can I limit the no of lines allowed in a multiline CEditBox
Thanks and Regards
Shibu
-
- Convert double 2 char[]
by DioNNiS
- 1 Replies
- Last post
by DioNNiS
- How conver double to char[]
function itoa work only whith integer...=(
-
- Writing data to file
by KeeperMustDie
- 9 Replies
- Last post
by JamesSexton
- Hello, I am new on c++ forms prgraming. I just faced a problem with writing structure or class to file and cant fnd answer. Can anyone plz tell me ho to do that
-
- What I'm doing wrong with System::Drawing::Imaging::ColorPalette (candidate function(s) not accessible)
by MausOnMars
- 1 Replies
- Last post
by Ramkrishna Pawar
- Hello,
The following code gives me a the compiler mesage: :
Code Snippet
error C3767: 'System::Drawing::Imaging::ColorPalette::ColorPalette': candidate function(s) not accessible My Code:
Code Snippet
using namespace System::Drawing; void main(void){ Imaging::ColorPalette cp; // or Imaging::ColorPalette^ cp2 = gcnew Imaging::ColorPalette(); } What's wro
-
- LPCSTR and LPCWSTR
by George2
- 2 Replies
- Last post
by Sdi
- Hello everyone,
I think when UNICODE or _UNICODE is defined, when using _T, it could convert characters to wide character.
And I also think LPCSTR should be defined to pointer to wide character when UNICODE or _UNICODE is defined, and LPCSTR should be defined to pointer to multibyte character when UNICODE and _UNICODE are not defined.
But it seems I am wrong for all points. Could anyone e
-
- Suggestions for a test harness (cppUnit?)
by TerryMcP
- 1 Replies
- Last post
by Sarath.
- What is the latest test harness for native (Win32) C++ that you would recommend
I've found references to cppUnit ( http://cppunit.sourceforge.net/cgi-bin/moin.cgi ) as well as nUnit (for managed C#)
I also found a passage that the Windows Development team cut over to a "new test harness" during the infamous "Longhorn Reset". Any insight into what tool they're using do the
-
- IO Completion Port problem (GetQueuedCompletionStatus)
by Vincent
- 1 Replies
- Last post
by Vincent
- Hi,
I have implemented a client/server application using IOCP on both side. It's working for some time but at one point the client keep receiving empty buffers. The function GetQueuedCompletionStatus awakes a thread, the number of bytes transfered given by GetQueuedCompletionStatus is ok and no particular error is signaled. When I check the buffer passed to WSARecv it is empty. Once it
-
- Error C2065 in vc6
by tasleemarif
- 2 Replies
- Last post
by Damien Watkins - MSFT
- hi i m using this code i on windows XP and visual studio 6,i receive error mentioned above i had include these two lines as well,in stdaxh.h #define _WIN32_WINNT 0x0500 #include <windows.h> the code is below MENUITEMINFO mii; memset(&mii, 0, sizeof(MENUITEMINFO)); mii.cbSize = sizeof(MENUITEMINFO); mii.fMask = MIIM_ID| MIIM_BITMAP |MIIM_DAMFT_BITMAPTA; error is describled as below D:\
-
- std::vector versus std::map performance
by Jonathan Scott
- 7 Replies
- Last post
by Brian Kramer
- I am curious if anyone knows about possible performance issues related to the use of the container template std::map, and particularly as it relates to std::vector's performance. I imagine there is good and bad usage of a map and/or vector, but would replacing a map with a vector offer any real performance gain (considering heavy usage)
My worry is that we will replace an easy-to-read associati
-
- OpenMP development questions
by mxchi
- 1 Replies
- Last post
by Ramkrishna Pawar
- Hi there, I get a desktop machine having two Intel Core2 processors, to utilise the mutli-processor machine with OpenMP, I wrote a benckmark code to verify the supportness of OpenMP in Visual Studio 2005.
When I increase the numbe of parallel thread from One to Two , I saw the improvement in performance which is in term of the running time nearly decreased by half; however when I continue i
-
- Overrideing operator== in an interface
by GordonTWatts
- 4 Replies
- Last post
by GordonTWatts
- Hi,
I'm wrapping a large native C++ library in a .NET one to make the native library accessible across various .NET languages. The native library makes moderate use of multiple inheritance, so I've gone the interface route. I'm having trouble with operators and interfaces, however.
For example, I'd like to implmenet the operator==. In C++/CLR I can do this pretty easily using the typica
-
- VC++ generates wrong parameter signature "custom mod | byref | custom mod | typedefref "
by p.b.a
- 1 Replies
- Last post
by Feng Chen - MSFT
- I came across the following parameter signature which according to the specs (PIIB 22.2.10) should be wrong: "modopt byref modopt valuetype typedefref". The code is generated by the Visual C++ compiler and the disassembled version looks something like this: "valuetype modopt([Microsoft.VisualC]Microsoft.VisualC.IsConstModifier)& modopt([Microsoft.VisualC]Microsoft.VisualC.IsCXXR
-
- help :: Trouble taking my C++ class to a static lib to a DLL without the sky falling
by flashbabe
- 1 Replies
- Last post
by Holger Grund
- I have CLR visual C++ code (myClr) that I need to use both in another c++ application as well as a c# application. My approach to doing this is to build myClr as a static library (.lib) and create a wrapping level project exposeDLL that simply links the .lib and includes the header file to myClr. When I do the above situation I am able to see the myClr object in a DLL, but I can't see any methods
-
- Warnings in Setup projects including multiple .msm
by Fred3000gt
- 2 Replies
- Last post
by Fred3000gt
- When including the Microsoft_VC80_ATL / CRT / MFC / MFCLOC merge modules,
I get multiple warnings of type:
WARNING: Two or more objects have the same target location ('[policydir]\8.0.50727.42.cat')
WARNING: Two or more objects have the same target location ('[policydir]\8.0.50727.42.cat')
WARNING: Two or more objects have the same target location ('[payload_ul]\8.0.50727.42
-
- Help using EnumChildWindows()
by flynny1st
- 6 Replies
- Last post
by flynny1st
- Hi,
I'm having problems inplementing the EnumChildWindows callback function. I have hooke dinto my external application ok. What i wish to do now is add a new child window (button) in this application.
I can do this, however the problem i have is that because the window already contains child windows itself. My window (button) is being drawn underneath these panes and so cannot be cl
-
- AfxGetApp()->OnCmdMsg(ID_FILE_NEW, 0, NULL, NULL) caused crash in debug mode.
by smart pig
- 4 Replies
- Last post
by Simple Samples
- Hey, In converting an existing application to Unicode compatible one, I have a line
Code Block
ProcessShellCommand(cmdInfo); that causes crash in debugging building. But it didn't crash in release building . Debugging into ProcessShellCommand review that AfxGetApp()->OnCmdMsg(ID_FILE_NEW, 0, NULL, NULL) caused the crash. I used the following code,
Code Block
-
- error LNK2019: unresolved external symbol
by Mohsen teimouri
- 3 Replies
- Last post
by Mohsen teimouri
- Hi,
I am trying to run particle systems on visual c++ 2005. The source is an open source and is written by a profetional ( http://www.cs.unc.edu/~davemc/Particle/ ) (CS people in a university). I have linking problem. I tried to compile it with /clr but I got error 2028 in addition to error 2019. Could you plaese help me to run this example.
Thank you,
Mohsen Teimouri
1>------ Build