Click here to Skip to main content
15,895,084 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Extract data from database Pin
Kevin McFarlane29-Apr-04 4:32
Kevin McFarlane29-Apr-04 4:32 
GeneralRe: Extract data from database Pin
dreamerzz29-Apr-04 4:37
dreamerzz29-Apr-04 4:37 
GeneralRe: Extract data from database Pin
David Crow29-Apr-04 4:47
David Crow29-Apr-04 4:47 
GeneralRe: Extract data from database Pin
dreamerzz29-Apr-04 4:49
dreamerzz29-Apr-04 4:49 
GeneralRe: Extract data from database Pin
David Crow29-Apr-04 4:59
David Crow29-Apr-04 4:59 
GeneralRe: Extract data from database Pin
dreamerzz29-Apr-04 5:05
dreamerzz29-Apr-04 5:05 
GeneralRe: Extract data from database Pin
David Crow29-Apr-04 5:13
David Crow29-Apr-04 5:13 
GeneralRe: Extract data from database Pin
gUrM33T29-Apr-04 4:35
gUrM33T29-Apr-04 4:35 
Yes there is. Using the new operator. At run-time, find out the number of records, and then allocate an array long enough to hold values you want to retrieve. For example, assuming that you've 50 records, the code will look like this:
LONG lRecCount = 50; <font color=green>// you won't hardcode this, but get it at run-time from database</font>
double *pdblValues = new double[lRecCount + 1];
for(LONG i = 0; i < lRecCount; i++)
  pdblValues[i] = <font color=green>collect value from the field here</font>;

One more thing, don't forget to delete[] pdblValue after you are finished with it.

Hope that helps,

Gurmeet
BTW, can Google help me search my lost pajamas?

My Articles: HTML Reader C++ Class Library, Numeric Edit Control

GeneralRe: Extract data from database Pin
dreamerzz29-Apr-04 5:07
dreamerzz29-Apr-04 5:07 
GeneralRe: Extract data from database Pin
gUrM33T29-Apr-04 7:57
gUrM33T29-Apr-04 7:57 
GeneralRe: Extract data from database Pin
David Crow29-Apr-04 5:10
David Crow29-Apr-04 5:10 
GeneralPls Helpl Pin
ThatsAlok29-Apr-04 2:41
ThatsAlok29-Apr-04 2:41 
GeneralRe: Pls Helpl Pin
22491729-Apr-04 4:15
22491729-Apr-04 4:15 
GeneralRe: Pls Helpl Pin
ThatsAlok4-May-04 20:53
ThatsAlok4-May-04 20:53 
QuestionHow to emulate a console window? Pin
Maxime Labelle29-Apr-04 2:06
Maxime Labelle29-Apr-04 2:06 
AnswerRe: How to emulate a console window? Pin
David Crow29-Apr-04 2:15
David Crow29-Apr-04 2:15 
GeneralRe: How to emulate a console window? Pin
Maxime Labelle29-Apr-04 2:55
Maxime Labelle29-Apr-04 2:55 
GeneralRe: How to emulate a console window? Pin
David Crow29-Apr-04 3:39
David Crow29-Apr-04 3:39 
GeneralRe: How to emulate a console window? Pin
Maxime Labelle29-Apr-04 4:18
Maxime Labelle29-Apr-04 4:18 
AnswerRe: How to emulate a console window? Pin
Ravi Bhavnani29-Apr-04 2:31
professionalRavi Bhavnani29-Apr-04 2:31 
GeneralRe: How to emulate a console window? Pin
Maxime Labelle29-Apr-04 2:48
Maxime Labelle29-Apr-04 2:48 
QuestionHow to make a CListCtrl with MULTILINES Pin
strizi29-Apr-04 1:37
strizi29-Apr-04 1:37 
AnswerRe: How to make a CListCtrl with MULTILINES Pin
gUrM33T29-Apr-04 4:17
gUrM33T29-Apr-04 4:17 
QuestionHow to Recover Deleted Files Pin
jk chan29-Apr-04 1:23
jk chan29-Apr-04 1:23 
AnswerRe: How to Recover Deleted Files Pin
David Crow29-Apr-04 2:03
David Crow29-Apr-04 2:03 

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.