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

obtaining file information from another machine

P: n/a
Hello,

I need to know which programs are opn on another machine in my network,
these programs are opened from a shared drive on the server. How can I do
this ? I've already dowloaded a sample program form vbnet.mvps.org but it
doesn't work??

Greets John
Jul 17 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
I just tried the code off the site and it works as advertised. NetFileEnum
is designed to return the names of some or all open files on a server. It
will not return files on the local machine opened by apps running on that
machine. If you point it to the server, it should list the files as long as
the application opening the files has it opened for exclusive use. AFAIK, if
the app just opens, reads and closes the file the file won't be identified
in the list, even if the user is still working on the file.

As a simple test to ensure the code works, on your local machine open
Explorer, select a folder containing some word or excel files, share that
folder, then map a drive to that folder on your machine, i.e. X:\ = c:\my
documents share. Now open one of the files using that mapped drive X:\ an
run the code specifying "" as the server - the file(s) you opened through
this networked share should be listed. Once you're assured the code works,
open one of the server files and change the "" to the server name.

--
Randy Birch
MS MVP Visual Basic
http://vbnet.mvps.org/
"John" <no****@fiktief.com> wrote in message
news:41***********************@news.skynet.be...
: Hello,
:
: I need to know which programs are opn on another machine in my network,
: these programs are opened from a shared drive on the server. How can I do
: this ? I've already dowloaded a sample program form vbnet.mvps.org but it
: doesn't work??
:
: Greets John
:
:

Jul 17 '05 #2

P: n/a

"Randy Birch" <rg************@mvps.org> schreef in bericht
news:JY********************@rogers.com...
I just tried the code off the site and it works as advertised. NetFileEnum
is designed to return the names of some or all open files on a server. It
will not return files on the local machine opened by apps running on that
machine. If you point it to the server, it should list the files as long as the application opening the files has it opened for exclusive use. AFAIK, if the app just opens, reads and closes the file the file won't be identified
in the list, even if the user is still working on the file.

As a simple test to ensure the code works, on your local machine open
Explorer, select a folder containing some word or excel files, share that
folder, then map a drive to that folder on your machine, i.e. X:\ = c:\my
documents share. Now open one of the files using that mapped drive X:\ an
run the code specifying "" as the server - the file(s) you opened through
this networked share should be listed. Once you're assured the code works, open one of the server files and change the "" to the server name.

--
Randy Birch
MS MVP Visual Basic
http://vbnet.mvps.org/
"John" <no****@fiktief.com> wrote in message
news:41***********************@news.skynet.be...
: Hello,
:
: I need to know which programs are opn on another machine in my network,
: these programs are opened from a shared drive on the server. How can I do : this ? I've already dowloaded a sample program form vbnet.mvps.org but it : doesn't work??
:
: Greets John
:
:


Randy,

Ok it works now, another question can I terminate the program on another
computer?
I want to start a program on a computer, the first thing I do is look on
other computers in my network if the program is running and if it is running
than terminate that program (the boss can override any other user)

many thanks

Greets John

Jul 17 '05 #3

P: n/a
Nope. You can reboot the user's machine, but that's a bit drastic, eh?

--
Randy Birch
MS MVP Visual Basic
http://vbnet.mvps.org/
"John" <no****@fiktief.com> wrote in message
news:41***********************@news.skynet.be...
:
: "Randy Birch" <rg************@mvps.org> schreef in bericht
: news:JY********************@rogers.com...
: > I just tried the code off the site and it works as advertised.
NetFileEnum
: > is designed to return the names of some or all open files on a server.
It
: > will not return files on the local machine opened by apps running on
that
: > machine. If you point it to the server, it should list the files as long
: as
: > the application opening the files has it opened for exclusive use.
AFAIK,
: if
: > the app just opens, reads and closes the file the file won't be
identified
: > in the list, even if the user is still working on the file.
: >
: > As a simple test to ensure the code works, on your local machine open
: > Explorer, select a folder containing some word or excel files, share
that
: > folder, then map a drive to that folder on your machine, i.e. X:\ =
c:\my
: > documents share. Now open one of the files using that mapped drive X:\
an
: > run the code specifying "" as the server - the file(s) you opened
through
: > this networked share should be listed. Once you're assured the code
: works,
: > open one of the server files and change the "" to the server name.
: >
: > --
: >
: >
: > Randy Birch
: > MS MVP Visual Basic
: > http://vbnet.mvps.org/
: >
: >
: > "John" <no****@fiktief.com> wrote in message
: > news:41***********************@news.skynet.be...
: > : Hello,
: > :
: > : I need to know which programs are opn on another machine in my
network,
: > : these programs are opened from a shared drive on the server. How can I
: do
: > : this ? I've already dowloaded a sample program form vbnet.mvps.org but
: it
: > : doesn't work??
: > :
: > : Greets John
: > :
: > :
: >
:
: Randy,
:
: Ok it works now, another question can I terminate the program on another
: computer?
: I want to start a program on a computer, the first thing I do is look on
: other computers in my network if the program is running and if it is
running
: than terminate that program (the boss can override any other user)
:
: many thanks
:
: Greets John
:
:
:

Jul 17 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.