Click here to Skip to main content
15,917,862 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: device manager refresh Pin
Blake Miller31-Jan-06 10:29
Blake Miller31-Jan-06 10:29 
GeneralRe: device manager refresh Pin
Manu_8131-Jan-06 11:45
Manu_8131-Jan-06 11:45 
GeneralRe: device manager refresh Pin
Ryan Binns31-Jan-06 17:28
Ryan Binns31-Jan-06 17:28 
QuestionTrying to expand a tree... Pin
KellyR31-Jan-06 9:06
KellyR31-Jan-06 9:06 
AnswerRe: Trying to expand a tree... Pin
Stephen Hewitt31-Jan-06 11:53
Stephen Hewitt31-Jan-06 11:53 
GeneralRe: Trying to expand a tree... Pin
KellyR2-Feb-06 4:12
KellyR2-Feb-06 4:12 
QuestionIs there a specific size for a 2 dimentional array Pin
Deema Jack31-Jan-06 8:18
Deema Jack31-Jan-06 8:18 
AnswerRe: Is there a specific size for a 2 dimentional array Pin
Dethulus31-Jan-06 8:31
Dethulus31-Jan-06 8:31 
If I understand your question correctly the answer is yes. All elements in any array are the same size. Accessing a 2 dimensional array as you described is simply a matter of indexing it properly. Assuming you've declared your array as:

int nArray[100][5];

You could assign x to any element in the array with any of the following methods:

<br />
int i, j, x;<br />
<br />
x = nArray[75][4];<br />
for(i=0; i<100; i++)<br />
{<br />
   for(j=0; j<5; j++)<br />
   {<br />
      x = nArray[i][j];<br />
      // ... do something with x;<br />
   }<br />
}<br />

However, unlike in BASIC you can't access element nArray[100][5]. Array access is always zero relative.

Hope this helps...

-Dethulus
QuestionSelecting an item by Keystrokes Pin
Kurt _B31-Jan-06 8:11
Kurt _B31-Jan-06 8:11 
AnswerRe: Selecting an item by Keystrokes Pin
Owner drawn31-Jan-06 22:47
Owner drawn31-Jan-06 22:47 
GeneralRe: Selecting an item by Keystrokes Pin
Kurt _B1-Feb-06 2:15
Kurt _B1-Feb-06 2:15 
QuestionHow to gray out a control Pin
Robert Palma Jr.31-Jan-06 6:26
Robert Palma Jr.31-Jan-06 6:26 
AnswerRe: How to gray out a control Pin
Rob Caldecott31-Jan-06 6:38
Rob Caldecott31-Jan-06 6:38 
GeneralRe: How to gray out a control Pin
Robert Palma Jr.31-Jan-06 8:52
Robert Palma Jr.31-Jan-06 8:52 
AnswerRe: How to gray out a control Pin
_anil_31-Jan-06 17:23
_anil_31-Jan-06 17:23 
GeneralRe: How to gray out a control Pin
toxcct31-Jan-06 21:31
toxcct31-Jan-06 21:31 
GeneralRe: How to gray out a control Pin
Robert Palma Jr.1-Feb-06 5:59
Robert Palma Jr.1-Feb-06 5:59 
QuestionVS2005 Compiles Wrong Files Pin
Swinefeaster31-Jan-06 6:18
Swinefeaster31-Jan-06 6:18 
QuestionSTL conflict Pin
eddyroth31-Jan-06 4:26
eddyroth31-Jan-06 4:26 
QuestionWhat is the difference between HANDLE and HWND ? Pin
wicked weasel31-Jan-06 4:20
wicked weasel31-Jan-06 4:20 
QuestionExplaination needed.. Pin
wicked weasel31-Jan-06 4:18
wicked weasel31-Jan-06 4:18 
QuestionWhat is the difference between HANDLE and HWND ? Pin
unknown**person31-Jan-06 4:10
unknown**person31-Jan-06 4:10 
AnswerRe: What is the difference between HANDLE and HWND ? Pin
wicked weasel31-Jan-06 4:21
wicked weasel31-Jan-06 4:21 
AnswerRe: What is the difference between HANDLE and HWND ? Pin
Dethulus31-Jan-06 4:23
Dethulus31-Jan-06 4:23 
QuestionMemory DC Pin
masnu31-Jan-06 4:10
masnu31-Jan-06 4:10 

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.