Click here to Skip to main content
16,022,219 members

Comments by Wajrak_ (Top 6 by date)

Wajrak_ 27-Mar-21 0:59am View    
Last time I tried with all the filters that came to my mind so last version was this:

watcher.NotifyFilter = NotifyFilters.LastWrite | NotifyFilters.FileName | NotifyFilters.CreationTime | NotifyFilters.LastAccess | NotifyFilters.DirectoryName;

watcher.Filter = "*.*";

Allthough I only need lastwrite or lastaccess. Again, code works fine as long as change to the file is made by certain apps. I dont mind sharing code I simply dont have it anymore, I've tried 5 different approaches to no avail and moved on, I would like to know why this is happening though. I also tried increasing buffer sizes to pretty much maximum, shifting FSW to top of hierarchy, kept it away form loops and built test solution just to figure it out... to no avail.
Wajrak_ 3-May-13 13:14pm View    
Well I feel like an idiot because I have not thought about making selections from selections Event (I'm still embarrassed).
You solved my problem in your first reply, as soon as you told me what I did I was back on the right path.
I hope I don't make a hobbit out of this "ask a question" because I like to consider my self as a resourceful guy, but it is a second time when you solved my problem in mater of minutes ;)

But you make me wonder with one thing you wrote and if you don't mind (and I think you don't, because last time you spent a lot of your time after answering my question explaining some other things to me), it was:
"never, never use such names, rename auto-generated names to something semantic"
This is the first time when someone suggested this to me so I'm quite surprised. If you could let me know why? It would be my pleasure.
Again, Thank you for your time.
Wajrak_ 3-May-13 11:15am View    
Sergey Alexandrovich I love you ;)
I remember you answering my question last year and you know what? I feel like an idiot now. You answer explains me being unable to debug and trace code in this case. I'm an idiot.
Thank you!

BTW, what I was trying to achieve was selecting multiple rows in ListView by simply going up and down using arrow keys and selecting items by pressing space button.

Thank you again.
Wajrak_ 3-May-13 11:10am View    
You sadly did. Imagine that I have selected 10 rows from ListView programatically by using listViewLeft.Items[selectedIndex].Selected = true; In loop. Now Im trying to use listViewLeft.SelectedItems.Count but it returns false values. It works when I select rows by using mouse, it does not when I select them programatically;

I'm not new to programming, I'm just suprissed because I see no difference between two ways of selecting rows. Like I said I can work around it but I would like to know what is going one?

Cheers
Wajrak_ 13-Nov-12 16:30pm View    
First of all, thank You for Your time and quick reply. Second of all i do apologise for late reply, my work requires a lot of traveling so i have to prioritise. Ive got no questions, your explanation is very clear for me. Im glad there are still ppl who are willing to explain something without taking things for granted or abusing other ppl by saying "you should know this" or "google" it. Again thank you
- Wajrak