A question about CImage

in CDoc
CImage m_pImg;

in CView
::GlobalLock(HBITMAP(pDoc->m_img)); == NULL
GetLastError(); > invalid handler

before try to get the handle, I have initialized it successfully, and my 
OnDraw() can works well.

0
ckacka (2)
3/3/2005 6:15:02 AM
vc.mfc 33608 articles. 0 followers. Follow

4 Replies
775 Views

Similar Articles

[PageSpeed] 23

Till I Know CImage is not a Predefined MS MFC Class, are you using some
external Library!!!

--

With Regards
Alok Gupta
Visit me at http://alok.bizhat.com

                           "I think this will Help"

"ckacka" <ckacka@discussions.microsoft.com> wrote in message
news:B320B34E-4D86-4179-88AC-D6E6E08A5BDC@microsoft.com...
> in CDoc
> CImage m_pImg;
>
> in CView
> ::GlobalLock(HBITMAP(pDoc->m_img)); == NULL
> GetLastError(); > invalid handler
>
> before try to get the handle, I have initialized it successfully, and my
> OnDraw() can works well.
>


0
thatsalok1 (226)
3/3/2005 6:20:09 AM
thanks for your reply
it's defined in <atlimage.h>
\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlimage.h

"thatsalok" wrote:

> Till I Know CImage is not a Predefined MS MFC Class, are you using some
> external Library!!!
> 
> --
> 
> With Regards
> Alok Gupta
> Visit me at http://alok.bizhat.com
> 
>                            "I think this will Help"
> 
> "ckacka" <ckacka@discussions.microsoft.com> wrote in message
> news:B320B34E-4D86-4179-88AC-D6E6E08A5BDC@microsoft.com...
> > in CDoc
> > CImage m_pImg;
> >
> > in CView
> > ::GlobalLock(HBITMAP(pDoc->m_img)); == NULL
> > GetLastError(); > invalid handler
> >
> > before try to get the handle, I have initialized it successfully, and my
> > OnDraw() can works well.
> >
> 
> 
> 
0
ckacka (2)
3/3/2005 6:53:01 AM
Please Ask  ATL/WTL related Question in it own group i.e.
microsoft.public.vc.ATL
--
With Regards
Alok Gupta
Visit me at http://alok.bizhat.com
                           "I think this will Help"

"ckacka" <ckacka@discussions.microsoft.com> wrote in message
news:36DBCA69-D708-46D2-864D-8830E53F1AA3@microsoft.com...
> thanks for your reply
> it's defined in <atlimage.h>
> \Microsoft Visual Studio .NET 2003\Vc7\atlmfc\include\atlimage.h
>
> "thatsalok" wrote:
>
> > Till I Know CImage is not a Predefined MS MFC Class, are you using some
> > external Library!!!
> >
> > --
> >
> > With Regards
> > Alok Gupta
> > Visit me at http://alok.bizhat.com
> >
> >                            "I think this will Help"
> >
> > "ckacka" <ckacka@discussions.microsoft.com> wrote in message
> > news:B320B34E-4D86-4179-88AC-D6E6E08A5BDC@microsoft.com...
> > > in CDoc
> > > CImage m_pImg;
> > >
> > > in CView
> > > ::GlobalLock(HBITMAP(pDoc->m_img)); == NULL
> > > GetLastError(); > invalid handler
> > >
> > > before try to get the handle, I have initialized it successfully, and
my
> > > OnDraw() can works well.
> > >
> >
> >
> >


0
thatsalok1 (226)
3/3/2005 7:51:26 AM
"thatsalok" <thatsalok@NO_gmail.com_I_DONT_NEED_SPAM> wrote in message 
news:eP%23OqW8HFHA.3628@TK2MSFTNGP15.phx.gbl...
> Please Ask  ATL/WTL related Question in it own group i.e.
> microsoft.public.vc.ATL
> --

In Visual Studio 2003, Microsoft combined classes like CString and yes, 
CImage, to be used in both ATL and MFC.  So CImage can be considered an MFC 
class....

-- David


0
dc2983 (3206)
3/5/2005 3:17:55 AM
Reply:

Similar Artilces:

A question in an interview
I was asked to write a function described below with C/C++ in 20 minutes. Implement a function that prints all posible combinations of the characters in a string. These combinations range in length from one to the length of the string. Two combinations that differ only in ordering of their characters are the same combination. In other words,"12" and "31" are different combinations from the input string"123",but 21 is the same as "12". Any good suggestion? I'd start by asking for a better definition of the problem. What if the input string is &qu...

quick question
So I extended my Windows 2003 to support Windows 2008, making my schema version now 44. I do not wish to to install a windows 2008 DC, can I still use the features such as RODC and probably fine grain password policy etc? Howdie! On 30.03.2010 15:28, Nik wrote: > So I extended my Windows 2003 to support Windows 2008, making my schema > version now 44. > I do not wish to to install a windows 2008 DC, can I still use the > features such as RODC and probably fine grain password policy etc? No, you can't. For RODCs, you need a full-DC with Server 2008 in the hu...

DPM 2010 question
Hello, I have some questions about Data Protection Manager 2010: 1. How to configure a Protection Group, when this Protection Group makes the backup, to overwrite a tape that is already linked to a Protection Group? 2. How to configure a Protection Group to perform the backup of folders that are already configured on another Protection Group? 3. How to catalog a tape manually (changing the catalog name)? 4, How to link two or more Protection Groups to one tape? 5. How to erase a tape that is linked to a Protection Group? 6. How to mark the tape that is linked t...

Beginner question
I am creating a query that counts how many times each classification is being used in our organization. But, I need it to pull up only the classifications that have a person in them. Here's how it looks now: Column 1: Field = Classification; Table = pos info; Total = Group By Column 2: Field = Class Code; Talbe = pos info; Total = Group By Column 3: Field = Count Of Classification: Count(*); Total = Expression I need it to pull up the Classifications that, within each same record, the field "IncumbentLast" Is Not Null. Thanks for your help. Hi - Add the field "Incum...

VBA question: Sheets() vs. Worksheets()?
Are these the same functions? Sheets can include chart sheets. Worksheets no -- Don Guillett SalesAid Software dguillett1@austin.rr.com "Mondrogan" <mondrogan@comcast.net> wrote in message news:FoudnVzS_MQXq2nYnZ2dnUVZ_qCmnZ2d@comcast.com... > Are these the same functions? > So I should always use Sheets() rather than Worksheets()? Sounds like Worksheets() functionality is a subset of Sheets(). "Don Guillett" <dguillett1@austin.rr.com> wrote in message news:%23gVmVAAZHHA.1400@TK2MSFTNGP06.phx.gbl... > Sheets can include chart sheets. Works...

Technical Question about Performance
Hi all I want to set up a web application for an organization that has some agents in different cities. I have 2 solutions and I want to know which is better and faster. 1-Like other sites put Asp.net pages and database in a host. 2-Putting asp.net pages in a local server but database in a host that local server gets data from host. thanks in advance On Feb 2, 7:25=A0am, "pers" <reza...@hotmail.com> wrote: > Hi all > I want to =A0set up a web application =A0for an organization that has som= e > agents in different cities. > I have 2 soluti...

Microsoft Query question
I am trying to use Microsoft Query to get data from my SQL 2000 databases. The problem is that I have a few columns with names that conflict with keywords (like Identity). (Yes. I kow that keywords should be avoided but it is done and cannot be changed.) This is causing a keyword syntax error within the Query application. Oddly enough, even if I do not select the column the error still appears. And when you look at all the columns available, the keyword named column shows up in boldface. When I am doing queries in other programs I put square ("[ ]") brackets around column and table...

Appoint Synch Question
We have User A enter in appointments through CRM for User B. Once the sync occurs and User B is in Outlook, the appointments appear on User B's outlook calendar. We have an issue though when User B is out of the office and User A schedules an appointment for them. User A usually checks User B's Outlook calendar prior to scheduling appointments. If User B isn't online, then User A cannot see the appointments that have been recently scheduled for User B and proceeds to add an appointment for a time slot that may already be reserved. Is there anyway around this issue? Is ...

Question about antivirus programs and windows updates.
Hello, I have been using the same antivirus for years, (CA Etrust) I have used this since 2000. I have had very rare issues with this program and never any conflicts with Windows Updates. What I am interested in finding out today is what other antivirus programs play well with Windows Updates? I read all the time in this NG about different AV products causing issues during update. You may be wondering why I am considering changing if I have been happy, well the company has made major changes to the most recent program version and is now sending notices about upgrading ...

Runtime Question 01-31-08
With the runtime for 2007, does that mean it be deployed on a MAC? QB Possibly a Mac that is dual-boot, but not to the native Mac OS. -- Jerry Whittle, Microsoft Access MVP Light. Strong. Cheap. Pick two. Keith Bontrager - Bicycle Builder. "Question Boy" wrote: > With the runtime for 2007, does that mean it be deployed on a MAC? > > QB ...

Office 2007 Configuration Question
Hello, Was wondering if anyone might have any ideas on this Am running WORD 2007 from MS Office Enterprise Edition. Yes, it's a legal copy. PC is about 4 years old, and running XP. Everything is fine for a month or so, and then it wants to go into a Configuration setup (again), which takes about 5 minutes to do. Then, everything is fine again for a month or two. Any ideas why this might be ? Thanks, B. Do you have both Word 2003 and 2007 on the machine? If you start Word 2003 and then later start Word 2007, the configuration will be reperformed, unless...

Custom Form Question #2
I have created two almost identical custom forms for Outlook 2007 in an exchange environment. The forms are based on the task form, and simply have a second tab that we each sign off on the steps of our projects as they go. We create those forms by going to action|new "custom" form. However, one of the forms appears as a task with a task icon in the task folder when I create it. But, the other shows up in the task folder, but with a post item icon, that is the little yellow sticky note with the blue push pin in it. I can't find where you set this attribute and why one form i...

Question #6
I was aksed this question and I'm inclined to say that there is no "legitimate" way of doing this but I want ot make sure that I am correct. There is no way to send an email from thisdomain.com but have it received by thatdomain.com correct. To accomplish this one would have to forge from address etc correct? Thanks Can you re-phrase your question please? The way you phrased your question describes typical mail flow - mail is sent FROM one domain, and received by another domain. I'm sure that's not what you intended. -- Ben Winzenz Exchange MVP "KC"...

Publisher 2002 question
Is there a way to set up an address book in Publisher 2002? Yes maam. Open Publisher and go to Tools > Mail Merge > Create Address List -- Brian Kvalheim Microsoft Publisher MVP http://www.publishermvps.com This posting is provided "AS IS" with no warranties, and confers no rights. "judyt" <judyt@discussions.microsoft.com> wrote in message news:39CFC3DE-47B6-4131-B406-AECDA88791BB@microsoft.com... > Is there a way to set up an address book in Publisher 2002? ...

SBS 2003 to 2008 Migration, and other Server migration questions
Hi, I'm in the midst of planing a migration from SBS 2003 to SBS 2008. I did a swing migration 3 or so years ago when I switched out HW for SBS 2003, and it worked well, only a couple of minor problems I had to deal with. I"m not opposed to purchasing the rights again, but do see that MS has documention for the same purpose, so I was wondering from those who have done migrations, which did you use, and why? Also, I have a 2nd domain controller, and a couple of other member servers (all 2003 Server), and I would like to figure out if I could do some kind of migration ...

LDB question
A while ago we had a discussion about persistent connection (which I tried once and never since). I plan to check "BE-MDB-open-status" on it's LDB, ie. LDB exists = MDB is open LDB doesn't exists = MDB is closed (I suppose that in such case persistent connection cannot be used.) But after an accident it may result incorrect MDB status since LDB may not be deleted. Is there a safer way to check if MDB is open? TIA Vlado How about OpenDatabase with the Exclusive option. If the file is already in use, that should fail. Testing the LDB is not ideal: it applies only when t...

Another Pivot Chart Autoformating Question
I have read through the other posts; but I still need some additional help since I do not have Macro or VBA experience. I am looking for a easy solution to reset all the pivot charts to my formatting as noted below (from a recorded Macro that didn't work) after a data refresh. There are about 20 tabs in the workbook with a pivot table and chart on each tab. A manual macro that works on all tabs or an auto run macro that works after a refresh is what I'm looking for. Any suggestions? Thanks in advance, Sub FormatPivotChart() ' FormatPivotChart Macro ' ActiveSheet.Ch...

Data grouping and averaging questions in excel 2003
I am looking into purchasing a data logger that will collect voltage, amperage with a time scale.Below is a sample of the data and a summary to be generated above the data. I have some problems with how I can have a msexcel spreadsheet automatically calculate averages and total times for each zone. I would like a summary for many separate zones with a dozen or so sessions that have recording to last from 10 to 100 seconds within each session. I would like to automatically disregard calculating any values in column C that are <30 & all rows in column B that have been disregarded i...

Budgeting Question for the Experts!
While I have worked my butt off to get a solid budget, I would like to be able to manage my budget from paycheck to paycheck. Obviously, there are some bills that are paid at the end of the month, others during the middle of the month, and others at the beginning of the month. I get paid every two weeks, and so some months have 2 deposits while others have 3. Essentially my question is this: Does any one have a suggestion on how to best approach this with Money? Right now, I'm doing it manually in Excel which is a pain. I would much rather do it in Money. In short, it's...

Stupid question i know.
We have a nice new AD site here, we transferred all our exchange from NT to the new 200 Exchange, i want to add one user to view a particular calender, i am guessing i have to set permissions through users and computers but its driving me mad. Anybody shed light on it? I know...read the book, go on a course...aint got time. Thanks Alan -- SP1 for Fun, BMW for Comfort. BOTAFOT #148 Assuming that you just want the user to be able to select File | Open | Other user's folder | calendar, then you should create an Outlook profile an logon to the target mailbox. Right click on calendar f...

Exchange Services Question
Can anyone tell me if I have to stop and restart exchange services or reboot after making changes to message size limits for them to take affect? Thanks Simple answer: No... everything happens on the fly. "colmers" wrote: > Can anyone tell me if I have to stop and restart exchange services or reboot > after making changes to message size limits for them to take affect? > > Thanks > Thanks Rahul.... "Rahul" wrote: > Simple answer: No... everything happens on the fly. > > "colmers" wrote: > > > Can anyone tell me if I h...

Question on LABEL Range
In a LABEL Range(say that it has 12 elements row-wise), how do one refer to the 4th elements? I have this ideas that in a worksheet, I have 12 rows single column LABELED range called MONTHS, where 1st elements is JAN(that is C6), and so on, and last element would be DEC(C17). How do I get the 4th element which will be APR, and put that value in the different cell using the LABEL reference instead of the absolute cell location(C9)? Thanks I am not sure I understand your question? You refer to the labels with their names, so if you want to sum the April row you use =SUM(Apr) Otherwis...

SBS 2000 Exchange Question
Has anyone seen the following before? "Microsoft Exchange Server reported error 0x80040600: Unknown error 0x80040600" This is effecting only one of 20 clients on XP Pro using Outlook XP. KB didn't have a reference to it. Thanks -- KnetWerks http://support.microsoft.com/?kbid=814441 -- John Oliver, Jr. MCSE, MCT, CCNA, Exchange MVP Microsoft Certified Partner "KnetWerks" <KnetWerks@discussions.microsoft.com> wrote in message news:7E9C06AF-EEBC-4DE3-B978-C48C713DA7E2@microsoft.com... > Has anyone seen the following before? > > "Microsoft Exc...

Excel question #22
I was wondering how to make something happen. I would like to take a formula in excel and assign it to a cell. When the user enters a number it takes that number and applies it to the formula and returns the number. Here is an example. (x / 60)=y if user enter 10 then the formula should return .166~ where x is the users input and y is the returned answer. If you could help me I would appreciate it. Have user input into cell A1. In cell B1, enter the formula: =A1/60 HTH, Elkar "shaver21560@hotmail.com" wrote: > I was wondering how to make something happen. I wo...

How do I print 2-up? (May be a template question)
I've been given a template for a flyer to be printed 2-up on 8.5x11, IOW, the template is 5.5x8.5. I can't see a way to do it. Can someone give me a clue? Thanks. -- Al Dykes News is something someone wants to suppress, everything else is advertising. - Lord Northcliffe, publisher of the Daily Mail What version Publisher? Believe me, it does make a difference. In Publisher 2003 or 02, page setup, custom, landscape, type 5.5 width, 8.5 height... Publisher will say it will print two copies per sheet. In Publisher 2007... File, page setup, Click advanced on the right. Sel...