Hi,
I created a generics list:
List<FileViewupdatedfilesArr =
(List<FileView>)DataListFiles.DataSource;
and I would like to find an item in the list according to a given
index of the item in the list.
Is there a simple way to achieve it ?
Thanks so much.
Ruthie. 3 9885
On May 13, 12:37 pm, ruthie <ruthie...@yahoo.comwrote:
Hi,
I created a generics list:
List<FileViewupdatedfilesArr =
(List<FileView>)DataListFiles.DataSource;
and I would like to find an item in the list according to a given
index of the item in the list.
Is there a simple way to achieve it ?
Thanks so much.
Ruthie.
Hi Ruthie,
You can use the index operator of the list.
updatedfilesArr[index]
If that's not what you meant, feel free to ask :).
Moty
On May 13, 12:52 pm, Moty Michaely <Moty...@gmail.comwrote:
On May 13, 12:37 pm, ruthie <ruthie...@yahoo.comwrote:
Hi,
I created a generics list:
List<FileViewupdatedfilesArr =
(List<FileView>)DataListFiles.DataSource;
and I would like to find an item in the list according to a given
index of the item in the list.
Is there a simple way to achieve it ?
Thanks so much.
Ruthie.
Hi Ruthie,
You can use the index operator of the list.
updatedfilesArr[index]
If that's not what you meant, feel free to ask :).
Moty
Dear Moty,
Great !!
So simple - I spent some time for looking for something much
complicated.
Thanks a lot.
Ruthie.
On May 13, 1:41 pm, ruthie <ruthie...@yahoo.comwrote:
On May 13, 12:52 pm, Moty Michaely <Moty...@gmail.comwrote:
On May 13, 12:37 pm, ruthie <ruthie...@yahoo.comwrote:
Hi,
I created a generics list:
List<FileViewupdatedfilesArr =
(List<FileView>)DataListFiles.DataSource;
and I would like to find an item in the list according to a given
index of the item in the list.
Is there a simple way to achieve it ?
Thanks so much.
Ruthie.
Hi Ruthie,
You can use the index operator of the list.
updatedfilesArr[index]
If that's not what you meant, feel free to ask :).
Moty
Dear Moty,
Great !!
So simple - I spent some time for looking for something much
complicated.
Thanks a lot.
Ruthie.
Hi,
Glad I could help.
The List class has much more search capabilities such as FindIndex and
more Find* methods.
You can look for further information (here of course:) ) and the MSDN
generic list page: http://msdn2.microsoft.com/en-us/library/d9hw1as6.aspx
Moty This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Sean Berry |
last post by:
Given
myList =
what is the easiest way to find out what index 'dog' is at?
|
by: salem.ganzhorn |
last post by:
#include <map>
#include <iostream>
using namespace std;
int main(
int argc,
const char * argv
)
{
|
by: ike |
last post by:
Could you please give your opinion on the portability of this code?
/* -------- begin findindex.c -------- */
struct Foo { int junk0; };
struct Bar { int junk1; struct Foo foo; int junk2; };
...
|
by: mike |
last post by:
what should i have to write in this code section?
#### is what i want to write
do i have to use foreach to for
if options is TextBox array
i used to enumbera....... but i don't...
|
by: cmrhema |
last post by:
hello
I am working in asp.net and C#
I am selecting multiple items in a list box.
Now I want a count of the seleted items also the index of the selected item
I browsed and found something...
|
by: GS |
last post by:
I want to create a dropdownlistbox in my windows form with name value pair.
but I need to initialize its initial selected value to a value from database
for the record.
I was going to just use...
|
by: Lorna |
last post by:
I have a table on a form containing 2 columns - size type and size. Depending on the size type (Mens, womens, Youth) I want to change the set of sizes available (in an option box). I have been able...
|
by: zcabeli |
last post by:
Hello,
how can i find the index of an existing element in a list ?
thanks,
|
by: raylopez99 |
last post by:
I would like to know if there's a quick "Linq" way to find the index
of an array having a particular value. I can do this the long way by
sequential iteration, but would like to know if there's a...
|
by: ashiela |
last post by:
i need to find the max position of my program. how can i do that?
int main()
{
int j,max=0,k;
for(k=0;k<=9;k++)
{
printf("Enter the number:");
scanf("%d", &j);
}
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: jfyes |
last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |