|
|
Thanks Maxwell!
The link is very helpful. Most of my issues are solved. How do you understand the statement in my original reply -- "declarations in the arguments' namespaces that are visible at the point of instantiation will be considered as well as declarations visible at the point of definition."
I can not understand why both instantiation point and definition point are considered. Any ideas or pseudo codes?
regards,
George
|
|
|
|
|
Hi again,
I need to display a JPG file from a location - ex. c:\img.jpg
using BitBlt but i don't know how to implement.
This will be under OnDraw() or OnPaint() function.
I read that this will use CDC but i don't know how to relate.
If you knew of a thread please inform me.
Hope you can help me.
Thanks.
|
|
|
|
|
Example:
void CMyWnd::OnPaint()
{
CPaintDC dc(this);
CImage JPEGImage;
JPEGImage.Load(_T("c:\\img.jpg"));
JPEGImage.BitBlt(dc, 0, 0, SRCCOPY);
}
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Is JPEGImage a derived class?
To create? or already exist.
|
|
|
|
|
TooShy2Talk wrote: Is JPEGImage a derived class?
No just a quickly chosen variable name. The class is CImage...
I forgot:
#include <atlimage.h> If you're using VC 6, upgrade! then I'll show a sample the long way. The CImage class makes it easy
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Select an HBITMAP object into a memory dc first.
An easy way to get an HBITMAP from a JPG file is using GDI+.
You might find it in google.
gl
|
|
|
|
|
Anyone know where I can get the debug version of msvc version 8.0.50727.762? VC2005 installs 8.0.50727.42 and depends on 8.0.50727.762!!
ed
~"Watch your thoughts; they become your words. Watch your words they become your actions.
Watch your actions; they become your habits. Watch your habits; they become your character.
Watch your character; it becomes your destiny."
-Frank Outlaw.
|
|
|
|
|
ed
~"Watch your thoughts; they become your words. Watch your words they become your actions.
Watch your actions; they become your habits. Watch your habits; they become your character.
Watch your character; it becomes your destiny."
-Frank Outlaw.
|
|
|
|
|
How do you create an expiration date for an application and/or a dll? That is, if you want to create a free trial version of software that stops running after 30 days or whatever, how do you do that?
Thanks!
|
|
|
|
|
the simple way is:
1. choose a place to store a date (registry, a file, etc)
2. when the app starts, check that place for the date
3. if you don't find a date, store the current date there
4. if you do find a date, subtract the current date from the stored date.
5. compare the difference to your time limit.
there's a huge obvious vulnerability in schemes like this (find the date and erase it to reset the trial). but, they do work.
|
|
|
|
|
But... how do you make the app stop working? Just quit every time it's started again?
|
|
|
|
|
Add a thread in your App to check the validity of yourapp or dll,when you find it is overdue then quit you App
|
|
|
|
|
|
Dear all
I download a project which is written in visual C++.net 2003.
Now I want to compile and use it in visual C++.net 2008.
But it could not be compiled because of including following line
#include <iostream.h>
It seems that visual C++.net 2008 does not support above line.
how can I overcome this problem.
Regards
Monhi
|
|
|
|
|
Could you please modify your post?! The < and > are gone ...
Maxwell Chen
|
|
|
|
|
Maybe just remove the ".h" from the relevant header file names
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
You meant #include <iostream.h> , am i right ?!
BTW, as it's been stated, and Bjarne Stroustrup tells it himself, the trailing .h is redundant with the < > inclusion symbols.
so the standard C++ is expecting standard headers to be included like that:
#include <iostream>
to finish, when you have a compiler/linker error, please paste it here. we cannot guess what the system tried to tell you, especially when you don't even post a piece of code...
|
|
|
|
|
toxcct wrote: we cannot guess what the system tried to tell you
Umm, you just uh did
Last modified: 31mins after originally posted --
led mike
|
|
|
|
|
sorry mike ? what you say ??
|
|
|
|
|
you just did guess what the system tried to tell him, after telling him we couldn't guess. :->
led mike
|
|
|
|
|
led mike wrote: you just did guess what the system tried to tell him, after telling him we couldn't guess
Haha ...
Maxwell Chen
|
|
|
|
|
Bjarne Shmarne....who does he think he is, anyway.
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Hi,
I have a quick question When a DLL process a THREAD_ATTACH message and while processing that message Issues a Memory allocation function shuch as localAlloc
Since I am in the DLL is the storage allocated out of DLL's heap or the Address Space of the calling thread Heap
Thankx
|
|
|
|
|
The first Blog entry for Nov 2004[^] (What was the difference between LocalAlloc and GlobalAlloc?) does not finish answering your question. You should continue reading the entries about GlobalLock ans they continue the first entry.
led mike
|
|
|
|