One of the standard menus provided to a Document/View app under MFC is the Windows menu. It provides things like tiling and cascading windows, and appends an enumerated list of currently available views at the end of the menu. Problem is, sometimes it doesn't and I'd like to know why. More specifically, I'd like to know how to refresh...
I've got an MFC application that is built with VC6. When ClearType is enabled (Windows XP) some texts are rendered smoothly, i.e. with ClearType, and others are not.
Dialog texts don't seem to ever get rendered with ClearType. Some list controls, however, have it enabled completely, others only in their headers.
What could be the reaso...
Someone told me to use MFC,but it seems that MFC will be dead,although its not already...
so if i want to learn windows programming now, which one should i choose? thx.
...
My service is MFC based, set to "Allow service to interact with the desktop", and will only ever run on XP & W2K.
Try as I might I cannot get a simple dialog box to display to the user from a Windows service using a class derived from CDialog. I can however get a message box to appear using MessageBox().
No error is returned and Get...
Hello,
MSDN contains an example for creating a desktop alert window:
http://msdn.microsoft.com/en-us/library/bb983515.aspx
The sample code starts with the following declaration.
CMFCDesktopAlertWnd* pPopup = new CMFCDesktopAlertWnd;
When I use it in my code, the compiler complains
'CMFCDesktopAlertWnd' : no appropriate default cons...
As I am new to Visual C++, there are so many types for handling string. When I use some type and go ahead with coding but on next step, there are in-build functions that use other types & it always require to convert one type of string to other. I found so many blogs but so confused when see so many answers & try but some are working & s...
I am trying to add drag-and-drop text to my Doc-View App. I added the COleDropTarget variable to the view class, registered it in OnCreate(). I added OnDragEnter(), OnDragOver(), OnDragLeave() and OnDrop() to that class as virtual overrides, but none of them are ever called. I previously had added m_pMainWnd->DragAcceptFiles(TRUE); to my...
Hello
I have a MFC application that launches a IWebBrowser2 window. On users computers where Internet Explorer is not their default browser they get the following warning message
"Internet explorer is not currently your default browser.
Would you like to make it your default browser?"
Is there a way to disable this check before I...
I have a piece of mature geospatial software that has recently had areas rewritten to take better advantage of the multiple processors available in modern PCs. Specifically, display, GUI, spatial searching, and main processing have all been hived off to seperate threads. The software has a pretty sizeable GUI automation suite for funct...
Hi,
can anyone give me any advice on what to do about this error ?!
i made a simple mfc app which works on windows7 but on winXP it throws the bellow error :
"The ordinal 7118 could not be located in the dynamic link lybrary mfc90.dll"
Thank you.
...
I need to compile some mfc code that was written using Visual C++ 6.0 many years ago. I was supposed to be able to choose New->Project->Win32 Application and then in Project->Settings choose "Using MFC as a static library." I'm using the AE version and this could be the reason that this option is not available. So far, the smaller progra...
Currently, I am developing an app for a China customer. China customer are mostly switch to GB2312 language in their OS encoding. I need to write a text file, which will be encoded using GB2312.
I use std::ofstream file
I compile my application under MBCS mode, not unicode.
I use the following code, to convert CString to std::string, a...
Our program requires the user to hold the Alt+Shift keys together in order to carry out some operations. The problem is that Windows uses this combination to switch locale on some setups. Anyone got any ideas as to how we can "override" this behaviour of Windows whilst our program is running? Can we do some sort of message intervention? ...
hello everyone..
Myself, new to mfc and vc++ environment. So i have got two simple questions to be clarified.
The first is how to make a resizable dialog bar and another question is how to give background color for a dockable dialog bar.
plz help me out from this. thanks in advance..
...
Hello everyone!
I'm currently developing a custom control that derives from CStatic MFC class (Smart Device C++ project).
I have created the control class using VC++ MFC class wizard, selecting CStatic class as its base class. I have used Class View to add OnSize event handler for my control class (I have selected WM_SIZE message from m...
I am making simple one on server side & one on client side application for transfering file from one location to another location or from one computer to another computer if computers are in network.
I used the code from http://www.codeproject.com/KB/IP/SocketFileTransfer.aspx. It is working & file transfered successfully.
But i need t...
I am pretty sure these classes are not thread safe.
But, is it safe to use different objects from these classes in different threads?
Do they have any global dependencies with each other like static data or anything to watch out for?
...
Hi,
I want to convert CString array to managed code ot send it to C#.
For normal CString i did like this,
CString menu = "MENU";
String ^ msg = gcnew String(menu);
Globals1::gwtoolbar->Add(msg);
But now i want to send array of string.i dont know how to do for CString array.
When i gave like this it shows error
CString menu[10];
Stri...
Hello!
As I know, this windows is MFC windows. How can I work with this windows (set text, get text, scroll and so on) using COM technology and any script language, for example VBS?
...
Previously, I am using STL map to perform the mentioned task.
struct ltstr
{
bool operator()(std::string s1, std::string s2) const
{
const int l1 = s1.length();
const int l2 = s2.length();
if (l1 == l2) {
// In alphabetical order.
return s1.compare(s2) < 0;
}
// From longest leng...