Solved

Run a program at Server through client.

Posted on 2001-08-17
4
196 Views
Last Modified: 2008-02-01
Hi all,

I have an exe file (say Upload.EXE) which is developed in VB6 and stored at mapped network directory (say P:\Develop>). This program used to do some process at remote database and get some data from their and FTP to another location. My server is windows 2000 and I secheduled to run this Upload.EXE for every 2 hrs under scheduled tasks. Now i want to run this program (upload.exe) at Server by running another program at my client pc. I mean when i click some button at client PC, that Upload.exe should run at server. (not at client pc). Is there anyway to achive this? Please advice me with some good examples. My advance thanks for your kind advices.

Sarvan
0
Comment
Question by:sarvan
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 1

Expert Comment

by:sdm395
ID: 6395977
You could turn Upload.exe into an ActiveX exe, and then call this from your client program using createobject(classname, server), and specify the servername to create it on.  You will also have to go into dcomcnfg on the server and adjust the properties for the program, ensuring that it is set to run application on this computer
0
 
LVL 4

Accepted Solution

by:
nutwiss earned 200 total points
ID: 6396639
look at the 'AT' command in Win2000 help - its a command-line command which enables you to simply specify which machine you want to run an application on:

The AT command schedules commands and programs to run on a computer at
a specified time and date. The Schedule service must be running to use
the AT command.

AT [\\computername] [ [id] [/DELETE] | /DELETE [/YES]]
AT [\\computername] time [/INTERACTIVE]
    [ /EVERY:date[,...] | /NEXT:date[,...]] "command"

\\computername     Specifies a remote computer. Commands are scheduled on the
                   local computer if this parameter is omitted.
id                 Is an identification number assigned to a scheduled
                   command.
/delete            Cancels a scheduled command. If id is omitted, all the
                   scheduled commands on the computer are canceled.
/yes               Used with cancel all jobs command when no further
                   confirmation is desired.
time               Specifies the time when command is to run.
/interactive       Allows the job to interact with the desktop of the user
                   who is logged on at the time the job runs.
/every:date[,...]  Runs the command on each specified day(s) of the week or
                   month. If date is omitted, the current day of the month
                   is assumed.
/next:date[,...]   Runs the specified command on the next occurrence of the
                   day (for example, next Thursday).  If date is omitted, the
                   current day of the month is assumed.
"command"          Is the Windows NT command, or batch program to be run.
0
 

Expert Comment

by:anand_m
ID: 6396669
You can create a Scheduler component ( wrapper over existing WinNT Scheduler ) using ITaskScheduler,etc. and call this from the client.
The Scheduler will in turn call your VB component on the server thereby you can submit different tasks to run at different times from the client machine.

Take a look at ITask,ITaskScheduler interface to write a simple component which will invoke other Server-side components.

On the client side you can have an interface to specify the date and time during which the process should run

Anand
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7202342
Hi sarvan,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Split points between: sdm395@devx and nutwiss

sarvan, if you think your question was not answered at all or if you need help, just post a new comment here; Community Support will help you.  DO NOT accept this comment as an answer.

EXPERTS: If you disagree with that recommendation, please post an explanatory comment.
==========
DanRollins -- EE database cleanup volunteer
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
MsgBox 2 64
Using "ScreenUpdating" 6 85
Sending a email via excel using vba 6 117
Excel 2007 Random Generate List Based on Defined Source Cells 3 29
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question