Click here to Skip to main content
15,914,070 members
Home / Discussions / C#
   

C#

 
GeneralRe: get solution Pin
Nagy Vilmos24-Mar-09 3:51
professionalNagy Vilmos24-Mar-09 3:51 
AnswerRe: get solution Pin
CPallini24-Mar-09 8:02
mveCPallini24-Mar-09 8:02 
QuestionHow add RadioButtonList control to GridView Control in C# .NET appliction Pin
Murugan k24-Mar-09 2:01
Murugan k24-Mar-09 2:01 
AnswerRe: How add RadioButtonList control to GridView Control in C# .NET appliction Pin
Ravi Mori24-Mar-09 2:16
Ravi Mori24-Mar-09 2:16 
Questioni want 2 delete in array element .. [modified] Pin
Rajeshwar Code- Developer24-Mar-09 1:51
Rajeshwar Code- Developer24-Mar-09 1:51 
AnswerRe: i want 2 delete in array element .. Pin
harold aptroot24-Mar-09 1:59
harold aptroot24-Mar-09 1:59 
GeneralRe: i want 2 delete in array element .. Pin
Rajeshwar Code- Developer24-Mar-09 2:14
Rajeshwar Code- Developer24-Mar-09 2:14 
GeneralRe: i want 2 delete in array element .. Pin
harold aptroot24-Mar-09 2:28
harold aptroot24-Mar-09 2:28 
Ok yes let me help some more then, cause I didn't actually do anything to help yet
Anyway, what I would probably do, if it is sure that you number of elements will halve, create a new int[2,length/2] , scan through the old array and only use the correct places like:
int[,] result = new int[2,array.GetLength(0)/2];
for (int i = 0; i < array.GetLength(0); i++)
{
   result[i&1,i/2] = array[1,i];
}

I hope that is what you mean?


edit: aah no it is not what you mean, but it's close..
Ok this is harder, since you don't know the size of the result yet..
maybe first put all elements that are not 1 into a List<int> and then turn that into an int[2,List.Count/2] ?



GeneralRe: i want 2 delete in array element .. Pin
harold aptroot24-Mar-09 2:36
harold aptroot24-Mar-09 2:36 
GeneralRe: i want 2 delete in array element .. Pin
Rajeshwar Code- Developer24-Mar-09 2:38
Rajeshwar Code- Developer24-Mar-09 2:38 
GeneralRe: i want 2 delete in array element .. Pin
harold aptroot24-Mar-09 2:48
harold aptroot24-Mar-09 2:48 
GeneralRe: i want 2 delete in array element .. Pin
musefan24-Mar-09 3:27
musefan24-Mar-09 3:27 
GeneralRe: i want 2 delete in array element .. Pin
harold aptroot24-Mar-09 3:51
harold aptroot24-Mar-09 3:51 
GeneralRe: i want 2 delete in array element .. Pin
musefan24-Mar-09 3:55
musefan24-Mar-09 3:55 
GeneralRe: i want 2 delete in array element .. Pin
Rajeshwar Code- Developer24-Mar-09 4:38
Rajeshwar Code- Developer24-Mar-09 4:38 
AnswerRe: i want 2 delete in array element .. Pin
musefan24-Mar-09 2:26
musefan24-Mar-09 2:26 
GeneralRe: i want 2 delete in array element .. Pin
Rajeshwar Code- Developer24-Mar-09 2:29
Rajeshwar Code- Developer24-Mar-09 2:29 
GeneralRe: i want 2 delete in array element .. Pin
musefan24-Mar-09 2:47
musefan24-Mar-09 2:47 
QuestionDataGridView adds datasource columns in again when recompiling [modified] Pin
kanchoette24-Mar-09 1:46
kanchoette24-Mar-09 1:46 
AnswerRe: DataGridView adds datasource columns in again when recompiling Pin
jaypatel51224-Mar-09 2:54
jaypatel51224-Mar-09 2:54 
QuestionOpen FTP abd get data Pin
abbd24-Mar-09 1:33
abbd24-Mar-09 1:33 
AnswerRe: Open FTP abd get data Pin
Michael Bookatz24-Mar-09 1:41
Michael Bookatz24-Mar-09 1:41 
Questionimage slideshow Pin
mist_psycho24-Mar-09 1:25
mist_psycho24-Mar-09 1:25 
AnswerRe: image slideshow Pin
musefan24-Mar-09 1:41
musefan24-Mar-09 1:41 
Generalimage slideshow Pin
mist_psycho26-Mar-09 0:47
mist_psycho26-Mar-09 0:47 

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.