SetBkColor is used to set the color behind characters that you paint with functions such as TextOut. You need to create a brush with the color of your choosing and paint the view in OnEraseBkgrnd with something like FillRect.
Hope this helps [dazed]
Hi Cyprus106, Baggiowen did not ask for a routine to
validate the password, just to enter it with asterisks to
display in place of the characters typed, which I have already answered! [mad]
I have a popup menu that works. It looks like bunny's example. But my popup menu was created with m_fractMenu.CreatePopupMenu(); Maybe your menu is not a popup menu and that is the problem?! [dazed]
Hi,
If you were writing a windows program, than the CEdit control has an edit style called ES_PASSWORD that automatically handles the password protection for you. Otherwise, I believe that you have to do it yourself. You could read chars without echo (using _getch), and echo an asterisk with...
MSDN shows that the GetVersionEx function really takes an OSVERSIONINFO structure, not an OSVERSIONINFOEX structure.
VerifyVersionInfo does take the OSVERSIONINFOEX structure, however. Did you look at MSDN's sample : "getting the system version"?
Steve [dazed]
Hi Matt,
Have you seen ON_WM_DEVMODECHANGE and ON_WM_DISPLAYCHANGE?
Although ON_WM_DISPLAYCHANGE is nowhere to be found in the Microsoft documentation, the dev mode change handler that you would write does get control when you change the
screen resolution in the control panel, because all top...
Hi,
You could create a font with CreateFont, using the GREEK_CHARSET, and then use SetFont. For example, to display the ohm symbol in an edit control in a dialog:
m_pFont = new CFont;
m_pFont->CreateFont(15, 7, 0, 0, 400, FALSE, FALSE, 0,
GREEK_CHARSET...
Hi,
Could you show us what is between the new and delete in your code? There is nothing wrong with the new and delete statements. Also, what was the value of m_dlgAsset when
the debug error occurred?
Steve
Hi,
When you pass by reference, the compiler generated code is
really passing the address of the variable, and automatically dereferencing the pointers for you. However,
if you want an example of explicitly passing addresses, just change the function declaration in my example to
void...
Hi,
The function declaration would be
void Money(double nDollarValue, int& nQuarters, int& Dimes, int& Nickels, int& Pennies);
The function definition would be written as
// Simple straightforward solution
void Money(double nDollarValue, int& nQuarters, int& nDimes, int& nNickels, int&...
OK. Here's an example of how you could do it programatically:
// The following code snippet sets the file program
// that is associated with the cnf extension to WORDPAD
char szProductType[80];
DWORD dwBufLen;
HKEY hTestKey = NULL;
LONG lResult = ::RegOpenKeyEx(HKEY_CURRENT_USER...
You could set the program that is associated with a particular file extension in the folder options menu item of the windows explorer, if that is what you mean.
srfink
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.