|
i want to store the processes running on a system in one string and send it as byte over network
if i do so how much a string can hold
or if i use string array will it work??
(i know how to list the process)
This code was posted by me...
|
|
|
|
|
Hi,
if you open a Socket or a NetworkStream you can send as much as you like, either in text (Unicode, ASCII, ...) or in binary (more compact, more compatibility concerns).
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
hello, i write from italy so my english is not so good: i'm sorry
i'm writing a program that should log filter based activity on my computer
i need to log when a document (doc, xls, ppt... etc)
is open, or readed, or is edited, or deleted
in my first attempt was capturing what files are open by all current open processes
for example:
winword.exe > test.doc // someone is reading a document
nero.exe > test.doc // someone is burning a document
but maybe is not a good solution
now, what do you think about this?
how i can do this job better?
hooks?
p.s. i cannot use windows event log for some reason... windows xp home and domains, etc
thank you in advance
|
|
|
|
|
You can try looking to FileSystemWatcher, but, as far as I know, it does not give you info on the process that caused a change.
|
|
|
|
|
It will also not tell you when a file is opened.
|
|
|
|
|
thank you for your answers
other solutions? i can use non-dotnet code too
vb6, c
|
|
|
|
|
Actually there is a LastAccessTime in the File/FileInfo classes; it does not get updated by default. It takes a registry tweak to enable that; I tried it once, it works (as in opening for read gets timestamped) but slows down Windows.
Anyway getting notified about all the files that are being read (assuming FSWatcher can cope) isn't likely to be a very good idea with indexers and AV and the like running all the time...
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
fswatch is good... but sometimes does not work
when i dragdrop a file into nero/neroexpress and burn a cd, or write an image
the file is not catched at all by fswatch
tried with cdburnerxp too and it does not too
anyway, it's a good start.
it's incredible that .netframework cannot get me the process who raised the event...
how can process monitor software (sysinternals) do this?
thanks in advance
|
|
|
|
|
Hi,
tamamm wrote: fswatch ... sometimes does not work
AFAIK FileSystemWatcher only gives a best attempt, it does not guarantee anything. It will signal multiple actions (from a few to a lot) on a file when you create, write, close it, depending on file size and buffer sizes. And it may miss some. It depends on its own buffer size, and I got the impression it is not really event driven.
tamamm wrote: it's incredible that .netframework cannot get me ...
Sysinternals plays dirty tricks on your system: it knows much more about the internal structures of the Windows kernel than MS is willing to tell anyone; and it uses its own driver to get access to those. That is how it was when they were independant, and it still is that way now MS has acquired them. I don't think it is realistic to try and obtain with your own code all the information they are offering.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Hi,
I am creating a sms processing agent using the opensource smslib (.net Version). It will be connected to my Sms gateway modem.
I also need to create a web services to communicate with my application.
What language do you guys advice i should use for creating the web services. (php or c#)?
|
|
|
|
|
Well as this is a C# forum I would guess most people will say C#, which is my choice.
Try another forum next time - like the 'Web Development' one
Life goes very fast. Tomorrow, today is already yesterday.
|
|
|
|
|
C#
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
|
You are a naughty, naughty DoctorMick.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
you're a sick doctor. Go get some help.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
If I use an ImageList as my source for a PictureBox I can use JPG and PNG files.
If I load the images into Resources, I can still use the JPG files, but the PNG images are not visible.
Unfortunately, I need PNG format for the transparency.
|
|
|
|
|
I regularly use PNG files as resources, with no problems whatever. Admittedly I rarely use PictureBox , as I find it an unsatisfactory control on many fronts. However, on those occasions that I have used it I have had no problems so long as the image type is one supported by the .Net Framework.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Thanks.
Experimenting converting the same image to JPG (so I lose my transparency) I can see my problem. From an ImageList it was made to fit the PictureBox size. From Resources it is not, and what was visible on screen was a tiny, transparent!!, corner of the image.
I will have to experiment with formatting the image to be the correct size.
|
|
|
|
|
The PictureBox has a SizeMode property. Set it to StretchImage to ensure that the image fills the PictureBox . Have a play with the other settings, to get familiar with how it works.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Or throw it out of the window, and paint stuff yourself, then you know all the time what is going on.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Absotively!!
That's what I do. I really cannot remember the last time I used a PictureBox. But then I can't remember the last time I watered the plants or mowed the cat eithter.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Henry Minute wrote: I can't remember the last time I watered the plants or mowed the cat eithter.
Don't worry, once mowed properly a cat doesn't need seconds.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
|
Yeah I'm not too sure about that one. I always use PNG as I have found that it has the highest quality and smallest file size. But I have noticed a few problems when using PNG's with the PictureBox, I'm not sure what causes these problems, but all I know is that when I select "Auto-size" I don't have any problems with the PictureBox.
|
|
|
|
|
It turns out the problem was with SizeMode. Using an ImageList seems to automatically use Zoom. Taking the image from Resources doesn't, and all I could see was the top left (transparent) corner of my image!!
|
|
|
|