|
View:
New views
4 Messages
—
Rating Filter:
Alert me
|
|
|
jsLibHi everyone
Firstly, thank you all kindly for the jsLib library. It's made a little dream of mine come true. For a long time I've been following Planet Mozilla daily, seeing FUEL come and go, all the time having a mind's eye image of that red jsLib icon but not really knowing what it was. Finally I've got my head around it and it's exactly what I am after and have been for so long. I come from a Perl/HTML/JS/CSS web design background and I've wanted to convert that into working with Mozilla code for a long time but obviously Perl is the glue in those skills and there's nothing in the Mozilla code that runs Perl. Anyway, thanks again for your library, it's excellent. Could you please tell me what the valid arguments are for the FileUtils.run() API method? In general I think the doco for jsLib is quite good but could be better. Maybe I can help as I learn? It would be good to have more examples than the only ones I can find on this brilliant page: https://www.mozdevgroup.com/docs/pete/jslib.html BTW that is the most sensible perspective I've seen regarding working with Mozilla's code base. It sums up the problem with having to write 'infrastructure' code perfectly. I've grabbed the example from there and I can use it to run a program with a line like this: fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe"); however even though that application takes a file path as an argument when run from the Windows XP cmd prompt, I can't get this (for example) to work: fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); Thanks again for your great work on jsLib everyone, any help would be greatly appreciated. pd _______________________________________________ Jslib mailing list Jslib@... https://www.mozdev.org/mailman/listinfo/jslib |
|
|
Re: jsLib> however even though that application takes a file path as an argument when run from the Windows XP cmd prompt, I can't get this (for example) to work: > > fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", > "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); > > Thanks again for your great work on jsLib everyone, any help would be greatly appreciated. > > Does fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe"); work correctly? --pete -- Pete Collins - Founder, Mozdev Group Inc. www.mozdevgroup.com Mozilla Software Development Solutions tel: 1-719-302-5811 fax: 1-719-302-5813 _______________________________________________ Jslib mailing list Jslib@... https://www.mozdev.org/mailman/listinfo/jslib |
|
|
Re: jsLibOn Tue, Sep 1, 2009 at 2:38 AM, Pete Collins <pete@...> wrote:
> >> however even though that application takes a file path as an argument when run from the Windows XP cmd prompt, I can't get this (for example) to work: >> >> fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); >> >> Thanks again for your great work on jsLib everyone, any help would be greatly appreciated. >> >> > > Does > > fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe"); > > work correctly? Hi Pete, thanks for your reply Yes it does. I actually screwed up my example a little. Here's more: Works: fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe"); fu.run("c:\\Progra~1\\mplayerc\\mplayerc.exe"); Fails: fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", "c:\incoming\RushS2E7.avi"); fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", "c:\\incoming\\RushS2E7.avi"); fu.run("c:\\Progra~1\\mplayerc\\mplayerc.exe", "c:\\incoming\\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); fu.run("c:\\Progra~1\\mplayerc\\mplayerc.exe", "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); fu.run("c:\\Progra~1\\mplayerc\\mplayerc.exe", "c:\incoming\RushS2E7.avi"); fu.run("c:\\Progra~1\\mplayerc\\mplayerc.exe", "c:\\incoming\\RushS2E7.avi"); So 8.3 filenames and escaping backlashes do not seem to help. Both programs launch without any secondary parameter. It's possible mplayerc.exe needs another /open or /play parameter but it definitely takes command line params and I just tested it without /open or /play from the command prompt and it works fine. I've looked at the FileUtils.js run method and there's code that provides errors but I'm not seeing any errors in he Error Console. Thanks pd > --pete > > -- > Pete Collins - Founder, Mozdev Group Inc. > www.mozdevgroup.com > Mozilla Software Development Solutions > tel: 1-719-302-5811 > fax: 1-719-302-5813 > > _______________________________________________ > Jslib mailing list > Jslib@... > https://www.mozdev.org/mailman/listinfo/jslib Jslib mailing list Jslib@... https://www.mozdev.org/mailman/listinfo/jslib |
|
|
Re: jsLib> Fails: > > fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe", > "c:\incoming\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"); > Try this: fu.run("c:\\Progra~1\\GRETECH\\GomPla~1\\GOM.exe",["c:\\incoming\\Leverage.S02E07.The.Two.Live.Crew.Job.HDTV.XviD-FQM.avi"]); Wrapping the second arg in an array ... Also escape the backslashes ... --pete -- Pete Collins - Founder, Mozdev Group Inc. www.mozdevgroup.com Mozilla Software Development Solutions tel: 1-719-302-5811 fax: 1-719-302-5813 _______________________________________________ Jslib mailing list Jslib@... https://www.mozdev.org/mailman/listinfo/jslib |
| Free embeddable forum powered by Nabble | Forum Help |