Getting this task to run

View: New views
9 Messages — Rating Filter:   Alert me  

Getting this task to run

by Michael Reick :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm creating a batch file that converts a .swf to an video file from the
command line in a cfm page, writing it out and trying to run it with
cfexecute.  (I've tried running the program directly from cfexecute,
with no luck).

What's really odd is when I RDP to the server in question, I can run the
batch file I created with CF with no problems, it runs for a bit then
spits out the video file.

So... Unless somebody's got some idea on why that isn't working, I've
decided to try to schedule the .bat file I create with CF with the
windows 2003 task scheduler, using schtasks.exe, but I'm having problems
with that too.

I try to run a command like so:
schtasks /create /tn createMovie47 /tr
d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
09/30/2008
And I have to type in a password, but when I try to include the password
with /rp or /p I just run into problems.

Can somebody please help with this?  I appreciate it...

Thanks,
Michael


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313303
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: Getting this task to run

by Dave Watts :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> I'm creating a batch file that converts a .swf to an video file from the
> command line in a cfm page, writing it out and trying to run it with
> cfexecute.  (I've tried running the program directly from cfexecute,
> with no luck).
>
> What's really odd is when I RDP to the server in question, I can run the
> batch file I created with CF with no problems, it runs for a bit then
> spits out the video file.
>
> So... Unless somebody's got some idea on why that isn't working, I've
> decided to try to schedule the .bat file I create with CF with the
> windows 2003 task scheduler, using schtasks.exe, but I'm having problems
> with that too.
>
> I try to run a command like so:
> schtasks /create /tn createMovie47 /tr
> d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
> 09/30/2008
> And I have to type in a password, but when I try to include the password
> with /rp or /p I just run into problems.

First, you may need to specify full file paths to things like schtasks.exe.

Second, when you run it from the console, are you using the same user
account that CF is?

Third, where exactly are you trying to enter a password?

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313306
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

dynamic formfield

by Tim Do :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm having a problem with a dynamic form field that I'm building.  

input  type = "text" name = "nm_#myvar#"

myvar is something that can be up to 16 digits.  When the form is
submitted it looks something like :  nm_1.54585221559E+015.  I need it
to show something like:  nm_1458522155945998

What can be causing this??  Any ideas would be much appreciated.

Thanks!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313307
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: Getting this task to run

by Michael Reick :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

1) I tried specifying the full path to schtasks.exe but that didn't make
a difference.

2) Yes, logging into the physical box with the same account (RDP or
since it's my dev server, I can walk over to it.. .:))

3) If I run either of these from the command prompt on the server
schtasks /create /tn createMovie47 /tr
d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
09/30/2008 /p *accountPassword*
or
schtasks /create /tn createMovie47 /tr
d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
09/30/2008 /rp *accountPassword*
 
It starts asking me for username then, and when I provide /u *username*
or /ru *username* it then asks me for the computer name and when I
supply the /s *computerName* it tells me the password is wrong.

Very very odd, and frustrating...

Thanks,

Michael
Dave Watts wrote:

>> I'm creating a batch file that converts a .swf to an video file from the
>> command line in a cfm page, writing it out and trying to run it with
>> cfexecute.  (I've tried running the program directly from cfexecute,
>> with no luck).
>>
>> What's really odd is when I RDP to the server in question, I can run the
>> batch file I created with CF with no problems, it runs for a bit then
>> spits out the video file.
>>
>> So... Unless somebody's got some idea on why that isn't working, I've
>> decided to try to schedule the .bat file I create with CF with the
>> windows 2003 task scheduler, using schtasks.exe, but I'm having problems
>> with that too.
>>
>> I try to run a command like so:
>> schtasks /create /tn createMovie47 /tr
>> d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
>> 09/30/2008
>> And I have to type in a password, but when I try to include the password
>> with /rp or /p I just run into problems.
>>    
>
> First, you may need to specify full file paths to things like schtasks.exe.
>
> Second, when you run it from the console, are you using the same user
> account that CF is?
>
> Third, where exactly are you trying to enter a password?
>
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
>
> Fig Leaf Software provides the highest caliber vendor-authorized
> instruction at our training centers in Washington DC, Atlanta,
> Chicago, Baltimore, Northern Virginia, or on-site at your location.
> Visit http://training.figleaf.com/ for more information!
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313308
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

: dynamic formfield

by Chuck Weidler-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

What does the code look like that is creating myvar?

-----Original Message-----
From: Tim Do [mailto:TDo@...]
Sent: Tuesday, September 30, 2008 8:35 PM
To: cf-talk
Subject: SPAM-LOW: dynamic formfield

I'm having a problem with a dynamic form field that I'm building.  

input  type = "text" name = "nm_#myvar#"

myvar is something that can be up to 16 digits.  When the form is
submitted it looks something like :  nm_1.54585221559E+015.  I need it
to show something like:  nm_1458522155945998

What can be causing this??  Any ideas would be much appreciated.

Thanks!



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313309
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: Getting this task to run

by Dave Watts :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> 2) Yes, logging into the physical box with the same account (RDP or
> since it's my dev server, I can walk over to it.. .:))

So, CF isn't running as SYSTEM? Just want to confirm that.

> 3) If I run either of these from the command prompt on the server
> schtasks /create /tn createMovie47 /tr
> d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
> 09/30/2008 /p *accountPassword*
> or
> schtasks /create /tn createMovie47 /tr
> d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
> 09/30/2008 /rp *accountPassword*
>
> It starts asking me for username then, and when I provide /u *username*
> or /ru *username* it then asks me for the computer name and when I
> supply the /s *computerName* it tells me the password is wrong.

Is the account you're using a domain account? If so, use the domain as a prefix:

/u domain\user

You shouldn't need the /s switch if you're trying to affect the local system.

If I understand the documentation correctly, omitting /ru and /rp
means the task will run under the SYSTEM user context. The /u and /p
switches let you control how schtasks writes to the scheduler queue.
So, you should be able to just specify /u and /p.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313310
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: Getting this task to run

by Michael Reick :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I would prefer to get this running directly from CF, simply because it's
less complicated...

No, CF is not running as System.

When I try to add /u *localUserName* /p *password* I get this:
ERROR: Invalid syntax. Cannot specify user name without specifying
system name.

So... when I add /s //*machineName* I get this:
ERROR: C:\WINDOWS\system32\kernel32.dll


Dave Watts wrote:

>> 2) Yes, logging into the physical box with the same account (RDP or
>> since it's my dev server, I can walk over to it.. .:))
>>    
>
> So, CF isn't running as SYSTEM? Just want to confirm that.
>
>  
>> 3) If I run either of these from the command prompt on the server
>> schtasks /create /tn createMovie47 /tr
>> d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
>> 09/30/2008 /p *accountPassword*
>> or
>> schtasks /create /tn createMovie47 /tr
>> d:\wwwroot\tours\47\youTube\createMovie.bat /sc once /st 18:45 /sd
>> 09/30/2008 /rp *accountPassword*
>>
>> It starts asking me for username then, and when I provide /u *username*
>> or /ru *username* it then asks me for the computer name and when I
>> supply the /s *computerName* it tells me the password is wrong.
>>    
>
> Is the account you're using a domain account? If so, use the domain as a prefix:
>
> /u domain\user
>
> You shouldn't need the /s switch if you're trying to affect the local system.
>
> If I understand the documentation correctly, omitting /ru and /rp
> means the task will run under the SYSTEM user context. The /u and /p
> switches let you control how schtasks writes to the scheduler queue.
> So, you should be able to just specify /u and /p.
>
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
>
> Fig Leaf Software provides the highest caliber vendor-authorized
> instruction at our training centers in Washington DC, Atlanta,
> Chicago, Baltimore, Northern Virginia, or on-site at your location.
> Visit http://training.figleaf.com/ for more information!
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313311
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: Getting this task to run

by Dave Watts :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> I would prefer to get this running directly from CF, simply because it's
> less complicated...

I'm not sure what you mean by this. Scheduled tasks by default run as
SYSTEM. They're never going to be run "directly from CF" because CF
isn't the scheduler service.

> When I try to add /u *localUserName* /p *password* I get this:
> ERROR: Invalid syntax. Cannot specify user name without specifying
> system name.

Are you adding the name as "domain\user" or "localmachinename\user"?

> So... when I add /s //*machineName* I get this:
> ERROR: C:\WINDOWS\system32\kernel32.dll

I think it's just /s machinename, without any slashes. If you did add
slashes, Windows uses backslashes for UNC notation, not forward
slashes. But again, I don't think they're needed at all here.

I'll qualify all this by saying I haven't used schtasks in a long time.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313323
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: Getting this task to run

by Michael Reick :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks for your help and suggestions Dave, I had to go a different
direction though to get this process working.

Sometimes I wish I were a burger flipper rather than a programmer... :)


Dave Watts wrote:

>> I would prefer to get this running directly from CF, simply because it's
>> less complicated...
>>    
>
> I'm not sure what you mean by this. Scheduled tasks by default run as
> SYSTEM. They're never going to be run "directly from CF" because CF
> isn't the scheduler service.
>
>  
>> When I try to add /u *localUserName* /p *password* I get this:
>> ERROR: Invalid syntax. Cannot specify user name without specifying
>> system name.
>>    
>
> Are you adding the name as "domain\user" or "localmachinename\user"?
>
>  
>> So... when I add /s //*machineName* I get this:
>> ERROR: C:\WINDOWS\system32\kernel32.dll
>>    
>
> I think it's just /s machinename, without any slashes. If you did add
> slashes, Windows uses backslashes for UNC notation, not forward
> slashes. But again, I don't think they're needed at all here.
>
> I'll qualify all this by saying I haven't used schtasks in a long time.
>
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
>
> Fig Leaf Software provides the highest caliber vendor-authorized
> instruction at our training centers in Washington DC, Atlanta,
> Chicago, Baltimore, Northern Virginia, or on-site at your location.
> Visit http://training.figleaf.com/ for more information!
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313382
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4
LightInTheBox - Buy quality products at wholesale price!