By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,892 Members | 1,363 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,892 IT Pros & Developers. It's quick & easy.

iterating and filtering files using C#

P: n/a
Hi

I created a program using C#, which iterates files and displays these in a
listview. However I would like to filter the files, so files won't be
displayed if the current user hasn't "read access"

any clever way to do that in the .NET Framework using C#?

thanks

/Dan
Nov 15 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
I bet you better keep the accessible file list in a sperate XML file which
you place in a directory, which created using the name of the user then as
the user login you just take the xml file and read the data sequentially
using a fast sequential xml reader like XMLtextreader class and display the
filenames in the lsitview, I guess you use system.io for these operation
right now, which is resourse wise costly if you have so many files in a one
folder.

Nirosh.

"Dan Kjaergaard" <dk*****@hotmail.com> wrote in message
news:#2**************@TK2MSFTNGP12.phx.gbl...
Hi

I created a program using C#, which iterates files and displays these in a
listview. However I would like to filter the files, so files won't be
displayed if the current user hasn't "read access"

any clever way to do that in the .NET Framework using C#?

thanks

/Dan

Nov 15 '05 #2

P: n/a
Actually i use MS Index Server to search for files - the result is returned
in a DataReader which I iterate. The Index Server controls the files so it's
not possible for me to keep track of the users files using xml. I just get
the basic fileinformation as filename, path and so on...

any idea?

/Dan

"Champika Nirosh" <no****@textcentric.lk> skrev i en meddelelse
news:OQ**************@TK2MSFTNGP11.phx.gbl...
I bet you better keep the accessible file list in a sperate XML file which
you place in a directory, which created using the name of the user then as
the user login you just take the xml file and read the data sequentially
using a fast sequential xml reader like XMLtextreader class and display the filenames in the lsitview, I guess you use system.io for these operation
right now, which is resourse wise costly if you have so many files in a one folder.

Nirosh.

"Dan Kjaergaard" <dk*****@hotmail.com> wrote in message
news:#2**************@TK2MSFTNGP12.phx.gbl...
Hi

I created a program using C#, which iterates files and displays these in a listview. However I would like to filter the files, so files won't be
displayed if the current user hasn't "read access"

any clever way to do that in the .NET Framework using C#?

thanks

/Dan


Nov 15 '05 #3

P: n/a
I don't know much about MS Index Server, can it say the users, have access
to a particular file?
"Dan Kjaergaard" <dk*****@hotmail.com> wrote in message
news:ef**************@tk2msftngp13.phx.gbl...
Actually i use MS Index Server to search for files - the result is returned in a DataReader which I iterate. The Index Server controls the files so it's not possible for me to keep track of the users files using xml. I just get
the basic fileinformation as filename, path and so on...

any idea?

/Dan

"Champika Nirosh" <no****@textcentric.lk> skrev i en meddelelse
news:OQ**************@TK2MSFTNGP11.phx.gbl...
I bet you better keep the accessible file list in a sperate XML file which
you place in a directory, which created using the name of the user then as the user login you just take the xml file and read the data sequentially
using a fast sequential xml reader like XMLtextreader class and display the
filenames in the lsitview, I guess you use system.io for these operation
right now, which is resourse wise costly if you have so many files in a

one
folder.

Nirosh.

"Dan Kjaergaard" <dk*****@hotmail.com> wrote in message
news:#2**************@TK2MSFTNGP12.phx.gbl...
Hi

I created a program using C#, which iterates files and displays these

in a listview. However I would like to filter the files, so files won't be
displayed if the current user hasn't "read access"

any clever way to do that in the .NET Framework using C#?

thanks

/Dan



Nov 15 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.