2D array of CString in MFC
-
Hi all, I want to make a 2D array of CString in MFC. Can I know if it is possible and how to declare and make it work?? Thx for your help!
Don't hate me but I don't think you can do it. I gave up after trying for a week. Currently I'm using linked CStringArray objects. Not neat but works.
-
Don't hate me but I don't think you can do it. I gave up after trying for a week. Currently I'm using linked CStringArray objects. Not neat but works.
-
Hi all, I want to make a 2D array of CString in MFC. Can I know if it is possible and how to declare and make it work?? Thx for your help!
You do it just like with any other type:
CString myarray[20][10];
--Mike-- http://home.inreach.com/mdunn/ Time is an illusion; lunchtime doubly so. -
You do it just like with any other type:
CString myarray[20][10];
--Mike-- http://home.inreach.com/mdunn/ Time is an illusion; lunchtime doubly so.I think I misunderstood something. (Read it at 4.30am so...) What I tried to do was a 2D CStringArray, derived from CStringArray, so that I could dynamicaly assign CString objects and have the array class allocate and clean up at run-time. I'm using "CStringArray fred[ 2 ]" at the moment. This is not neat at all as I said but works OK. I ass-u-med the original post was about this.