Click here to Skip to main content
16,005,682 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
AnswerRe: how to clone a stream Pin
toxcct3-Nov-05 21:13
toxcct3-Nov-05 21:13 
QuestionHelp Required With Ordered list.cc part 1 Pin
The_Lone_Wolf3-Nov-05 4:53
The_Lone_Wolf3-Nov-05 4:53 
QuestionCan I resize my tabs within an SDI application? Pin
SheriMarie3-Nov-05 3:15
SheriMarie3-Nov-05 3:15 
AnswerRe: Can I resize my tabs within an SDI application? Pin
Sheng Jiang 蒋晟4-Nov-05 7:13
Sheng Jiang 蒋晟4-Nov-05 7:13 
QuestionOverloading [] to handle multidimentional arrays Pin
Pegasus Kiddo3-Nov-05 0:03
Pegasus Kiddo3-Nov-05 0:03 
AnswerRe: Overloading [] to handle multidimentional arrays Pin
toxcct3-Nov-05 0:16
toxcct3-Nov-05 0:16 
GeneralRe: Overloading [] to handle multidimentional arrays Pin
S. Senthil Kumar4-Nov-05 22:34
S. Senthil Kumar4-Nov-05 22:34 
AnswerRe: Overloading [] to handle multidimentional arrays Pin
Kevin McFarlane6-Nov-05 4:46
Kevin McFarlane6-Nov-05 4:46 
For a 2-D situation the easiest thing to do is something like this:

<code>
Array of arrays of ints
typedef vector<vector<int> > CMultiIntArray;

void TraceDynamicArray(const unsigned int rows, const unsigned int columns)
{
CMultiIntArray aTest;

// Allocate number of rows
aTest.resize( rows );


// For each row
for (int row = 0; row < aTest.size(); row++)
{
// Allocate number of columns
aTest[row].resize( columns );


// For each column
for (int column = 0; column < aTest[row].size(); column++)
{
// Assign a value
aTest [row] [column] = 10 * row + column;


// Trace it
cout << aTest [row] [column] << "\t";
}

cout << "\n";
}
}

// Example usage: Standard C++ Library version

int main(int argc, char* argv[])
{
TraceDynamicArray(3,5);

return 0;
}

// For rows = 3, columns = 5, produces output...

// 0 1 2 3 4
// 10 11 12 13 14
// 20 21 22 23 24
</code>


Then you can do something similar for higher dimensions. But you have to define the dimensions upfront.

Kevin
QuestionOverwriting struct in binary file Pin
scrname2-Nov-05 19:03
scrname2-Nov-05 19:03 
AnswerRe: Overwriting struct in binary file Pin
willy_total3-Nov-05 8:55
willy_total3-Nov-05 8:55 
QuestionNeed HELP with code Pin
pacificeve2-Nov-05 13:24
pacificeve2-Nov-05 13:24 
QuestionLauching jar as a process from C++ Pin
carsten8011-Nov-05 21:04
carsten8011-Nov-05 21:04 
AnswerRe: Lauching jar as a process from C++ Pin
toxcct1-Nov-05 23:45
toxcct1-Nov-05 23:45 
QuestionRe: Lauching jar as a process from C++ Pin
carsten8012-Nov-05 3:07
carsten8012-Nov-05 3:07 
AnswerRe: Lauching jar as a process from C++ Pin
toxcct2-Nov-05 3:27
toxcct2-Nov-05 3:27 
AnswerRe: Lauching jar as a process from C++ Pin
code-frog4-Nov-05 19:12
professionalcode-frog4-Nov-05 19:12 
QuestionHow to judge a string encoding is euc, sjis, ascii or others? Pin
CooperWu30-Oct-05 23:18
CooperWu30-Oct-05 23:18 
AnswerRe: How to judge a string encoding is euc, sjis, ascii or others? Pin
CooperWu30-Oct-05 23:22
CooperWu30-Oct-05 23:22 
AnswerRe: How to judge a string encoding is euc, sjis, ascii or others? Pin
toxcct31-Oct-05 0:02
toxcct31-Oct-05 0:02 
GeneralRe: How to judge a string encoding is euc, sjis, ascii or others? Pin
Sheng Jiang 蒋晟31-Oct-05 6:07
Sheng Jiang 蒋晟31-Oct-05 6:07 
GeneralRe: How to judge a string encoding is euc, sjis, ascii or others? Pin
CooperWu31-Oct-05 22:30
CooperWu31-Oct-05 22:30 
GeneralRe: How to judge a string encoding is euc, sjis, ascii or others? Pin
Johann Gerell31-Oct-05 19:40
Johann Gerell31-Oct-05 19:40 
GeneralRe: How to judge a string encoding is euc, sjis, ascii or others? Pin
CooperWu31-Oct-05 22:30
CooperWu31-Oct-05 22:30 
QuestionSocket Programming question Pin
mdykstra30-Oct-05 6:48
mdykstra30-Oct-05 6:48 
AnswerRe: Socket Programming question Pin
willy_total31-Oct-05 9:33
willy_total31-Oct-05 9:33 

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.