Click here to Skip to main content
15,921,467 members
Home / Discussions / C#
   

C#

 
AnswerRe: c# DataGridView EditMode and DeleteKey Pin
Abhinav S3-Jun-12 17:16
Abhinav S3-Jun-12 17:16 
Questionconvert part of a list to an array Pin
a.fatemeh3-Jun-12 7:18
a.fatemeh3-Jun-12 7:18 
AnswerRe: convert part of a list to an array Pin
Dave Kreskowiak3-Jun-12 7:30
mveDave Kreskowiak3-Jun-12 7:30 
GeneralRe: convert part of a list to an array Pin
VJ Reddy3-Jun-12 7:56
VJ Reddy3-Jun-12 7:56 
GeneralRe: convert part of a list to an array Pin
Luc Pattyn3-Jun-12 8:59
sitebuilderLuc Pattyn3-Jun-12 8:59 
GeneralRe: convert part of a list to an array Pin
VJ Reddy3-Jun-12 14:05
VJ Reddy3-Jun-12 14:05 
AnswerRe: convert part of a list to an array Pin
Richard Andrew x643-Jun-12 7:33
professionalRichard Andrew x643-Jun-12 7:33 
GeneralRe: convert part of a list to an array Pin
VJ Reddy3-Jun-12 7:57
VJ Reddy3-Jun-12 7:57 
GeneralRe: convert part of a list to an array Pin
Luc Pattyn3-Jun-12 9:00
sitebuilderLuc Pattyn3-Jun-12 9:00 
AnswerRe: convert part of a list to an array Pin
VJ Reddy3-Jun-12 7:53
VJ Reddy3-Jun-12 7:53 
GeneralRe: convert part of a list to an array Pin
Richard Andrew x643-Jun-12 8:00
professionalRichard Andrew x643-Jun-12 8:00 
GeneralRe: convert part of a list to an array Pin
Luc Pattyn3-Jun-12 9:00
sitebuilderLuc Pattyn3-Jun-12 9:00 
AnswerRe: convert part of a list to an array Pin
taha bahraminezhad Jooneghani3-Jun-12 8:05
taha bahraminezhad Jooneghani3-Jun-12 8:05 
AnswerRe: convert part of a list to an array PinPopular
Luc Pattyn3-Jun-12 8:58
sitebuilderLuc Pattyn3-Jun-12 8:58 
GeneralRe: convert part of a list to an array Pin
Dave Kreskowiak3-Jun-12 9:15
mveDave Kreskowiak3-Jun-12 9:15 
GeneralRe: convert part of a list to an array Pin
Luc Pattyn3-Jun-12 9:26
sitebuilderLuc Pattyn3-Jun-12 9:26 
GeneralRe: convert part of a list to an array Pin
DaveyM694-Jun-12 8:18
professionalDaveyM694-Jun-12 8:18 
I've just seen this and happened to have reflector open so I've had a look!

GetRange uses Array.Copy to copy to a new list:
C#
List<T> list = new List<T>(count);
Array.Copy(this._items, index, list._items, 0, count);
list._size = count;
return list;

as is ToArray but to an array instead:
C#
T[] destinationArray = new T[this._size];
Array.Copy(this._items, 0, destinationArray, 0, this._size);
return destinationArray;

Now quite what Array.Copy is doing I'm not 100% sure as it's an extern function, so perhaps it's using unmanaged code to block copy?
Dave

Binging is like googling, it just feels dirtier.
Please take your VB.NET out of our nice case sensitive forum.
Astonish us. Be exceptional. (Pete O'Hanlon)

BTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)



GeneralRe: convert part of a list to an array Pin
VJ Reddy3-Jun-12 13:51
VJ Reddy3-Jun-12 13:51 
GeneralRe: convert part of a list to an array PinPopular
Luc Pattyn3-Jun-12 14:28
sitebuilderLuc Pattyn3-Jun-12 14:28 
AnswerRe: convert part of a list to an array Pin
Apocalypse Now3-Jun-12 14:09
Apocalypse Now3-Jun-12 14:09 
GeneralRe: convert part of a list to an array Pin
Luc Pattyn3-Jun-12 14:30
sitebuilderLuc Pattyn3-Jun-12 14:30 
GeneralRe: convert part of a list to an array Pin
Apocalypse Now4-Jun-12 14:33
Apocalypse Now4-Jun-12 14:33 
QuestionSign Language Recognition Pin
RimaTeliani3-Jun-12 0:00
RimaTeliani3-Jun-12 0:00 
AnswerRe: Sign Language Recognition Pin
OriginalGriff3-Jun-12 0:29
mveOriginalGriff3-Jun-12 0:29 
GeneralRe: Sign Language Recognition Pin
RimaTeliani3-Jun-12 2:09
RimaTeliani3-Jun-12 2:09 

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.