Click here to Skip to main content
15,885,278 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Non-Templatized methods in Template Class? Pin
bob169728-Feb-11 4:42
bob169728-Feb-11 4:42 
QuestionC++ - how to refer a header file which is used in a dll while loading thru loadlibrary method Pin
DavJes7-Feb-11 1:47
DavJes7-Feb-11 1:47 
AnswerRe: C++ - how to refer a header file which is used in a dll while loading thru loadlibrary method Pin
Hans Dietrich7-Feb-11 2:07
mentorHans Dietrich7-Feb-11 2:07 
AnswerRe: C++ - how to refer a header file which is used in a dll while loading thru loadlibrary method Pin
CPallini7-Feb-11 3:00
mveCPallini7-Feb-11 3:00 
AnswerRe: C++ - how to refer a header file which is used in a dll while loading thru loadlibrary method Pin
Stefan_Lang8-Feb-11 1:36
Stefan_Lang8-Feb-11 1:36 
Question"Could not find field 'Description'" error in access database. Pin
Le@rner7-Feb-11 1:21
Le@rner7-Feb-11 1:21 
AnswerRe: "Could not find field 'Description'" error in access database. Pin
David Crow7-Feb-11 8:47
David Crow7-Feb-11 8:47 
QuestionProblem using const float ** Pin
Alex80gbg6-Feb-11 22:41
Alex80gbg6-Feb-11 22:41 
Dear all,

Usually when I create a function in C++ I use 'const' for the input arguments that I do not change in the function. For example :

void myFunction( const float * pMyArray, const int numelMyArray, ... );


That allows you to see what arguments are inputs and protects against accidental modification of the data. The data in pMyArray is not const.

So far so good. My problem occurs when I want to pass the function an array of pointers to arrays, and still use const to avoid , like this:

void myFunction( const float ** ppMyPtrArray, const int numelMyPtrArray, ... );


When I pass the function an array of pointers to arrays of non-const floats, I get the the following error during compilation:

cannot convert parameter 1 from 'float **' to 'const float **' 1>
Conversion loses qualifiers


What on earth is happening here? Suddenly 'const' for function arguments does not work like (I) expected...

Please help me solve this mysterySmile | :)

A good day to you all!
AnswerRe: Problem using const float ** Pin
Stefan_Lang6-Feb-11 23:18
Stefan_Lang6-Feb-11 23:18 
AnswerRe: Problem using const float ** Pin
Andrew Brock6-Feb-11 23:41
Andrew Brock6-Feb-11 23:41 
QuestionDoModal [modified] Pin
john56326-Feb-11 20:16
john56326-Feb-11 20:16 
AnswerRe: DoModal Pin
Cedric Moonen6-Feb-11 21:30
Cedric Moonen6-Feb-11 21:30 
QuestionHow to provent text selection in CComboBox ? Pin
mesajflaviu6-Feb-11 20:01
mesajflaviu6-Feb-11 20:01 
AnswerRe: How to provent text selection in CComboBox ? Pin
mesajflaviu6-Feb-11 20:20
mesajflaviu6-Feb-11 20:20 
QuestionRe: How to provent text selection in CComboBox ? Pin
David Crow7-Feb-11 3:27
David Crow7-Feb-11 3:27 
AnswerRe: How to provent text selection in CComboBox ? Pin
mesajflaviu7-Feb-11 5:06
mesajflaviu7-Feb-11 5:06 
QuestionReading the file that create from "Print to file" option Pin
Max++6-Feb-11 16:09
Max++6-Feb-11 16:09 
AnswerRe: Reading the file that create from "Print to file" option Pin
Andrew Brock6-Feb-11 18:38
Andrew Brock6-Feb-11 18:38 
Questionhello, anyone have an idea of a code in MFC to shut down with time the pc ? in Vs 2008 ? Pin
leech4ever6-Feb-11 13:49
leech4ever6-Feb-11 13:49 
AnswerRe: hello, anyone have an idea of a code in MFC to shut down with time the pc ? in Vs 2008 ? Pin
«_Superman_»6-Feb-11 15:13
professional«_Superman_»6-Feb-11 15:13 
AnswerRe: hello, anyone have an idea of a code in MFC to shut down with time the pc ? in Vs 2008 ? Pin
Andrew Brock6-Feb-11 15:23
Andrew Brock6-Feb-11 15:23 
QuestionHow to make a book provision for multiple authors Pin
Horace Cheng6-Feb-11 11:49
Horace Cheng6-Feb-11 11:49 
AnswerRe: How to make a book provision for multiple authors Pin
Maximilien6-Feb-11 17:11
Maximilien6-Feb-11 17:11 
AnswerRe: How to make a book provision for multiple authors Pin
Richard MacCutchan6-Feb-11 22:08
mveRichard MacCutchan6-Feb-11 22:08 
QuestionBluetooth socket programming Pin
Pranit Kothari6-Feb-11 7:05
Pranit Kothari6-Feb-11 7:05 

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.