|
|
:-Di would like to know how do i display text over an image using MFC, cos when i write a text using DrawText, the text gets written behind the Image.
Nams
|
|
|
|
|
This depends on the way you are doing it but make sure the text is written after the iamge is drawn, including in the OnPaint handler.
The tigress is here
|
|
|
|
|
See if this article is of any help.
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
I was confused using the Date Picker (CDateTimeCtrl). When I enter a date using the date picker, (OnChange) DTN_DATETIMECHANGE notification was sent twice but if I enter using the keyboard it was only sent once.
|
|
|
|
|
Ok, so what's your question?
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
Hi
I have created a .dll file and one .exe file in Visual C++.NET platform.
I want to call that .exe file from that Main.cpp file. How can we do it in to the Visual C++.NET platform?
Thank you
Janak
|
|
|
|
|
|
CreateProcess()<br />
CreateProcessEx()<br />
ShellExecute()
or the easiest,
WinExec()
Regards,
Rajesh R. Subramanian
You have an apple and me too. We exchange those and We have an apple each.
You have an idea and me too. We exchange those and We have two ideas each.
|
|
|
|
|
Thanks to both of you...
-- modified at 5:58 Tuesday 13th December, 2005
|
|
|
|
|
Hi,
I have a function that uploads files to our database. I wish to display the
status of upload while it is happening....something like a dialog with a list
box that displays each action as it happens.
The problem: I made a dialog with a list box. The dialog implements
WM_UPDATEUISTATE. It adds a string in certain static location to the list box
every time it recieves this message. But, it apparently accumulates all the
messages that the worker thread sends and then displays all of them at the
end of processing not as the processing happens. Please suggest alternatives.
I am a bit new to MFC and I would request you to give some idea on what went
wrong here, if possible.
Thanks in advance!
krems.
krems
|
|
|
|
|
That's normal behavior if you have one single thread. In your program, what's happening is that you are running a function (I suppose) that is doing the work of uploading files. Thus, your UI is not responding anymore because messages aren't processed anymore. When your function terminates, your UI code is again ran and it finally process all the messages.
If you want the UI responding to your message while doing some work in the background, you'll have to make an extra worker thread to manage the upload. Look in this website, I think there is some nice articles about threads (it's too long to explain here).
|
|
|
|
|
HI to all,
can anybody help me what is the Difference between VC++6.0 and VC++.NET.
Thanks.
|
|
|
|
|
regarding what ?
- VC++.NET is standard compliant (VC++6 is not anymore)
- VC++ support .NET applications but still maintains native code generation too (VC++6 doe not know .net framework at all)
TOXCCT >>> GEII power [toxcct][VisualCalc 2.20] | soon : [VisualCalc 3.0]
|
|
|
|
|
toxcct wrote: soon : [VisualCalc 3.0]
hmmm.. how soon? Expecting it very soon!
You have an apple and me too. We exchange those and We have an apple each.
You have an idea and me too. We exchange those and We have two ideas each.
|
|
|
|
|
|
toxcct wrote: still compiling...
hai.. which computer are you using for compilation.... PCXT 386
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
|
toxcct wrote: (VC++6 is not anymore)
Did it used to be?
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
DavidCrow wrote: Did it used to be?
hum, i thought it was at a time... you know, these old ages, when dinosaurs were still on earth...
TOXCCT >>> GEII power [toxcct][VisualCalc 2.20] | soon : [VisualCalc 3.0]
|
|
|
|
|
toxcct wrote: hum, i thought it was at a time
Actually, VC6 was released several months before the C++ ISO standard.
My programming blahblahblah blog. If you ever find anything useful here, please let me know to remove it.
|
|
|
|
|
Nemanja Trifunovic wrote: Actually, VC6 was released several months before the C++ ISO standard
and dinosaurs were released several months before standard homo sapiens sapiens...
TOXCCT >>> GEII power [toxcct][VisualCalc 2.20][VisualCalc 3.0]
|
|
|
|
|
I expect the major difference is Environment.
Major Changes from Visual C++ 6.0 to Visual C++ .NET
----------------------------------------------------
Microsoft Visual C++ .NET provides many new features and improvements.
Managed Code and Targeting the .NET Framework
Provides links to Managed Extensions for C++ and Visual C# documentation.
Attributed Programming
Describes what attributes are and what you can do with them.
C++ Compiler, Linker, and C++ Language
Provides links and updated information about the compiler, linker, build tools, and C++ language features in Visual C++ .NET.
Debugger
Provides information about the Visual Studio debugger and links to related topics.
Development Environment
Describes changes in the development environment in Visual C++ .NET.
Resource Editors
Discusses the Image Editor toolbar and the Text Tool dialog box.
Libraries
Provides links to new content in the Visual C++ libraries, including the Active Template Library (ATL), ATL Server, C Run-Time Library, Microsoft Foundation Class Library, OLE DB Templates, Shared Classes, and the Standard C++ Library.
Deployment and Redistribution of an Application
Provides links to deployment and redistribution information for Visual Studio .NET.
Nice talking to you.
|
|
|
|
|
Hi
I cannot display the BMP image in my window. Here is the code i am using to do the same in WM_PAINT. (Both LoadBitmap and LoadImage are not working). Any pointers will be helpful.
case WM_PAINT:
hdc = BeginPaint(hWnd, &ps);
// LoadBitmap(hInst, MAKEINTRESOURCE(IDB_BITMAP2));
LoadImage(0,"C:\\Anniyan.bmp",IMAGE_BITMAP,100,100,LR_LOADFROMFILE);
EndPaint(hWnd, &ps);
break;
Regards
Anniyan
|
|
|
|
|
Your code is not even trying to display an image, and it will leak resources.
1) Load bitmap image:
HBITMAP image = LoadBitmap(hInst, MAKEINTRESOURCE(IDB_BITMAP2));
2) Select bitmap into DC. ( See SelectObject() )
3) Bit-blit bitmap it hdc. ( See BitBlt() )
4) Select previous bitmap into DC. ( See SelectObject() )
5) Delete bitmap. ( DeleteObject() )
INTP
Every thing is relative...
|
|
|
|