Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
Hello everyone. I have asked this question a few other times, but I am
extremely confident that I have done an extremely poor job of explaining it!! So one more time, in really simple theoretical terms: Workbook1 has a clickevent on it. If I press the click event, the code sends a little bird down the hall and into the server room of our company. In that room, the bird opens the excel file Workbook2, and runs a macro called "Main". Is this possible (other than buying an extremely intelligent bird)?? Thank you!! -Steph |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
Hi Steph,
It depends on quite a few things but Technically the answer (I suspect) is yes, this is possible. Realistically tho' I would forget it! OJ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
Workbook1 has a clickevent on it. If I press the click event, the code
sends a little bird down the hall and into the server room of our company. In that room, the bird opens the excel file Workbook2, and runs a macro called "Main". Let's see if I can re-phase this in programming terms: Workbook1 has a clickevent on it.In Workbook1 I have a macro or vba procedure which is triggered by a Command button on Sheet1. If I press the click event, the code sends a little bird down the hall and into the server room of our company... When I click the Command Button I want the procedure to Open Workbook2 on the network server and run a procedure in Workbook2, called "Main" Yes this is quite possible with something like: Workbooks.Open Filename:= _ "H:\Documents and Settings\UserName\MyFolder\Workbook2.xls" 'adjust the path you you network 'then 'I think this is the code line you are looking for Application.Run Workbook2 & "!Main" "Steph" wrote: Hello everyone. I have asked this question a few other times, but I am extremely confident that I have done an extremely poor job of explaining it!! So one more time, in really simple theoretical terms: Workbook1 has a clickevent on it. If I press the click event, the code sends a little bird down the hall and into the server room of our company. In that room, the bird opens the excel file Workbook2, and runs a macro called "Main". Is this possible (other than buying an extremely intelligent bird)?? Thank you!! -Steph |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
That will still open the file on her computer.....from what Steph
writes it seems like she wants to open the file on another computer in the server room by running code from her workstation.... Not quite as simple!! |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
It's hard to tell from the OP. Maybe she can clarify?
"OJ" wrote: That will still open the file on her computer.....from what Steph writes it seems like she wants to open the file on another computer in the server room by running code from her workstation.... Not quite as simple!! |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
That is exactly what she wants, this question was answered yesterday. Like
you, I suggested doing it another way, that involved more process, less automation. -- HTH RP (remove nothere from the email address if mailing direct) "OJ" wrote in message oups.com... That will still open the file on her computer.....from what Steph writes it seems like she wants to open the file on another computer in the server room by running code from her workstation.... Not quite as simple!! |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
Sorry, that is not quite what she wants, she wants to run a piece of code
from one workstation, but for the code to execute on a server, thereby freeing up the workstation. This is what she wrote then A member of Sr Management executes a macro every so often (long story as to why HE has to do it...just accept the fact that he does). Right now, the code resides in the workbook that he opens and pushes a button. This code does lots of stuff (opens other workbooks, etc) and takes a while to run. And obviously, this is running on his machine. Here is the scenario I would like: He opens a "front-end" file that has a button. This button executes the code on a server, NOT his machine. So he pushes the button, and then immediately can close his workbook. Meanwhile, the code is running on a server and not his machine. As he does not even wait for the results, I felt process would be a better solution. -- HTH RP (remove nothere from the email address if mailing direct) "Bob Phillips" wrote in message ... That is exactly what she wants, this question was answered yesterday. Like you, I suggested doing it another way, that involved more process, less automation. -- HTH RP (remove nothere from the email address if mailing direct) "OJ" wrote in message oups.com... That will still open the file on her computer.....from what Steph writes it seems like she wants to open the file on another computer in the server room by running code from her workstation.... Not quite as simple!! |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
Hi everyone. Thaks for the feedback. How about this for a new process:
I have the Mgr's click event populate Sheet1!A1 of a shell file called Shell.xls. Bob, as you suggested - I create a scheduled job on the server that will open Shell.xls, say every 30 minutes. The Open event will check Shell.xls to see if Sheet1!A1 is populated. If it is, clear cell A1 and run the procedu Workbooks.Open Filename:= _ "H:\Documents and Settings\UserName\MyFolder\Workbook2.xls" Application.Run Workbook2 & "!Main If not, close Shell.xls and do nothing. Thanks again for the feedback! "Bob Phillips" wrote in message ... Sorry, that is not quite what she wants, she wants to run a piece of code from one workstation, but for the code to execute on a server, thereby freeing up the workstation. This is what she wrote then A member of Sr Management executes a macro every so often (long story as to why HE has to do it...just accept the fact that he does). Right now, the code resides in the workbook that he opens and pushes a button. This code does lots of stuff (opens other workbooks, etc) and takes a while to run. And obviously, this is running on his machine. Here is the scenario I would like: He opens a "front-end" file that has a button. This button executes the code on a server, NOT his machine. So he pushes the button, and then immediately can close his workbook. Meanwhile, the code is running on a server and not his machine. As he does not even wait for the results, I felt process would be a better solution. -- HTH RP (remove nothere from the email address if mailing direct) "Bob Phillips" wrote in message ... That is exactly what she wants, this question was answered yesterday. Like you, I suggested doing it another way, that involved more process, less automation. -- HTH RP (remove nothere from the email address if mailing direct) "OJ" wrote in message oups.com... That will still open the file on her computer.....from what Steph writes it seems like she wants to open the file on another computer in the server room by running code from her workstation.... Not quite as simple!! |
#9
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run code remotely
Steph,
I think that is a smart move :-). Sometimes, automating is not worth the effort. -- HTH RP (remove nothere from the email address if mailing direct) "Steph" wrote in message ... Hi everyone. Thaks for the feedback. How about this for a new process: I have the Mgr's click event populate Sheet1!A1 of a shell file called Shell.xls. Bob, as you suggested - I create a scheduled job on the server that will open Shell.xls, say every 30 minutes. The Open event will check Shell.xls to see if Sheet1!A1 is populated. If it is, clear cell A1 and run the procedu Workbooks.Open Filename:= _ "H:\Documents and Settings\UserName\MyFolder\Workbook2.xls" Application.Run Workbook2 & "!Main If not, close Shell.xls and do nothing. Thanks again for the feedback! "Bob Phillips" wrote in message ... Sorry, that is not quite what she wants, she wants to run a piece of code from one workstation, but for the code to execute on a server, thereby freeing up the workstation. This is what she wrote then A member of Sr Management executes a macro every so often (long story as to why HE has to do it...just accept the fact that he does). Right now, the code resides in the workbook that he opens and pushes a button. This code does lots of stuff (opens other workbooks, etc) and takes a while to run. And obviously, this is running on his machine. Here is the scenario I would like: He opens a "front-end" file that has a button. This button executes the code on a server, NOT his machine. So he pushes the button, and then immediately can close his workbook. Meanwhile, the code is running on a server and not his machine. As he does not even wait for the results, I felt process would be a better solution. -- HTH RP (remove nothere from the email address if mailing direct) "Bob Phillips" wrote in message ... That is exactly what she wants, this question was answered yesterday. Like you, I suggested doing it another way, that involved more process, less automation. -- HTH RP (remove nothere from the email address if mailing direct) "OJ" wrote in message oups.com... That will still open the file on her computer.....from what Steph writes it seems like she wants to open the file on another computer in the server room by running code from her workstation.... Not quite as simple!! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Copy a file remotely | Excel Discussion (Misc queries) | |||
Editing Spreadsheets Remotely | Excel Discussion (Misc queries) | |||
VBA - Run Macros Remotely? | Excel Programming | |||
Defining Cell Row Value Remotely in Formula not Code | Excel Programming | |||
Opening Excel remotely | Excel Programming |