Click here to Skip to main content
15,897,273 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to print color BITMAP from ressource on Printer ? Pin
jerome_data6-Mar-07 20:39
jerome_data6-Mar-07 20:39 
AnswerRe: How to print color BITMAP from ressource on Printer ? Pin
prasad_som6-Mar-07 22:25
prasad_som6-Mar-07 22:25 
GeneralRe: How to print color BITMAP from ressource on Printer ? Pin
Mark Salsbery7-Mar-07 3:48
Mark Salsbery7-Mar-07 3:48 
GeneralRe: How to print color BITMAP from ressource on Printer ? Pin
prasad_som7-Mar-07 23:01
prasad_som7-Mar-07 23:01 
GeneralRe: How to print color BITMAP from ressource on Printer ? Pin
Hamid_RT7-Mar-07 0:20
Hamid_RT7-Mar-07 0:20 
AnswerRe: I found it's DIB and DDB problem Pin
jerome_data7-Mar-07 23:28
jerome_data7-Mar-07 23:28 
Questiontemplate method in c++ Pin
mehmetned6-Mar-07 11:40
mehmetned6-Mar-07 11:40 
AnswerRe: template method in c++ Pin
Stephen Hewitt6-Mar-07 11:46
Stephen Hewitt6-Mar-07 11:46 
I assume you mean something like this:
template <typename T>
inline int GetID(const T &obj)
{
	return obj.id;
}


There are a number of methods you could use to handle differently named variables. Given the general case above you could introduce an exception using template specialisation as follows for example:

template <>
inline int GetID<rocket>(const rocket &obj)
{
	return obj.rocket_id;
}



Steve

GeneralRe: template method in c++ Pin
mehmetned6-Mar-07 11:58
mehmetned6-Mar-07 11:58 
GeneralRe: template method in c++ Pin
Stephen Hewitt6-Mar-07 12:03
Stephen Hewitt6-Mar-07 12:03 
QuestionCDialogBar in a CDialog Appl. for HeaderCtrl Column Chooser? Pin
-273C6-Mar-07 11:37
-273C6-Mar-07 11:37 
QuestionQuestion about memory writing and reading Pin
godspeed1236-Mar-07 11:36
godspeed1236-Mar-07 11:36 
AnswerRe: Question about memory writing and reading Pin
PJ Arends6-Mar-07 12:12
professionalPJ Arends6-Mar-07 12:12 
QuestionMigrating from VC++ 6.0 MFC to VC++ 2005 Pin
BuckBrown6-Mar-07 11:33
BuckBrown6-Mar-07 11:33 
AnswerRe: Migrating from VC++ 6.0 MFC to VC++ 2005 Pin
prasad_som6-Mar-07 17:19
prasad_som6-Mar-07 17:19 
Questionhow to learn multithreading Pin
l_d6-Mar-07 9:07
l_d6-Mar-07 9:07 
AnswerRe: how to learn multithreading Pin
David Crow6-Mar-07 9:53
David Crow6-Mar-07 9:53 
AnswerRe: how to learn multithreading Pin
Hamid_RT6-Mar-07 18:21
Hamid_RT6-Mar-07 18:21 
GeneralRe: how to learn multithreading Pin
l_d7-Mar-07 8:06
l_d7-Mar-07 8:06 
GeneralRe: how to learn multithreading Pin
Hamid_RT7-Mar-07 17:47
Hamid_RT7-Mar-07 17:47 
Questionstop scrolling of first column in CListView / CListCtrl Pin
ensger6-Mar-07 8:18
ensger6-Mar-07 8:18 
AnswerRe: stop scrolling of first column in CListView / CListCtrl Pin
Michael Dunn6-Mar-07 12:29
sitebuilderMichael Dunn6-Mar-07 12:29 
Questionpush_back ina vector - Not working for me Pin
LCI6-Mar-07 7:00
LCI6-Mar-07 7:00 
AnswerRe: push_back ina vector - Not working for me Pin
Maximilien6-Mar-07 7:30
Maximilien6-Mar-07 7:30 
GeneralRe: push_back ina vector - Not working for me Pin
LCI6-Mar-07 7:35
LCI6-Mar-07 7:35 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.