Unable to open file using shell or process
Mike Bonner
bonnmike at gmail.com
Thu Oct 14 14:29:56 EDT 2010
Glad it worked for you!
Since it's all in the same folder you can most likely simplify it by setting
the default folder before opening the process.
you can do it like
on mouseup
-- the following changes the default folder so that you start in the
location
-- that contains your php script and the file you want to work on.
-- Should avoid the need for an explicit path.
-- as long as both are in the same folder you should be good to go.
-- if they were in different places you might have to provide the full path
to 1 or the other.
set the defaultfolder to "/home/Bill/Desktop/report"
-- much simplified promysql, no long pathing involved
put "nr.php -f tt.conf"into promysql
open process promysql for update
read from process promysql for 500
put it into fld tout
write "quit" to process promysql
close process promysql
end mouseup
On Thu, Oct 14, 2010 at 12:13 PM, Glen Bojsza <gbojsza at gmail.com> wrote:
> Hi Mike,
>
> That did it !
>
> Many thanks.
>
> Glen
>
> On Thu, Oct 14, 2010 at 12:04 PM, Mike Bonner <bonnmike at gmail.com> wrote:
>
> > Did changing your code to the following work?
> >
> > on mouseUp
> > put "/home/Bill/Desktop/report/nr.php -f
> /home/Bill/Desktop/report/tt.conf"
> > into promysql
> > open process promysql for update
> > read from process promysql for 500
> > put it into fld tout
> > write "quit" to process promysql
> > close process promysql
> > end mouseUp
> >
> >
> > On Thu, Oct 14, 2010 at 11:48 AM, Glen Bojsza <gbojsza at gmail.com> wrote:
> >
> > > Yes, the nr.php file is in the same directory as the tt.conf file. I
> have
> > > also confirmed the path and files by do a process with ls -l
> > > /home/Bill/Desktop/reporter and it show the files.
> > >
> > >
> > >
> > > On Thu, Oct 14, 2010 at 11:08 AM, Mike Bonner <bonnmike at gmail.com>
> > wrote:
> > >
> > > > Is the tt.conf in the same folder with nr.php?
> > > >
> > > > try /home/Bill/Desktop/report/nr.php -f
> > /home/Bill/Desktop/report/tt.conf
> > > > if
> > > > it is, or simplify it by switching there first.
> > > >
> > > > "cd /home/Bill/Desktop/report ; ./nr.php -f tt.conf"
> > > >
> > > > On Thu, Oct 14, 2010 at 10:56 AM, Glen Bojsza <gbojsza at gmail.com>
> > wrote:
> > > >
> > > > > Hi Ken,
> > > > >
> > > > > It does not make a difference though thanks for pointing it out...
> I
> > > was
> > > > > also trying to add 2>&1 & after the tt.conf to see if that made a
> > > > > difference
> > > > > but it did not.
> > > > >
> > > > > Glen
> > > > >
> > > > > On Thu, Oct 14, 2010 at 10:47 AM, Ken Ray <kray at sonsothunder.com>
> > > wrote:
> > > > >
> > > > > > > on mouseUp
> > > > > > > put "/home/Bill/Desktop/report/nr.php -f tt.conf " into
> promysql
> > > > > > > open process promysql for update
> > > > > > > read from process promysql for 500
> > > > > > > put it into fld tout
> > > > > > > write "quit" to process promysql
> > > > > > > close process promysql
> > > > > > > end mouseUp
> > > > > > >
> > > > > > > Error: Unable to open tt.conf
> > > > > >
> > > > > > Glen,
> > > > > >
> > > > > > Not that it should make a difference, but it appears there's a
> > space
> > > > > after
> > > > > > your command. I haven't used 'open process' to run a php script,
> so
> > I
> > > > may
> > > > > > just be shooting blanks here, but just thought I'd pass that
> along.
> > > > > >
> > > > > > Ken Ray
> > > > > > Sons of Thunder Software, Inc.
> > > > > > Email: kray at sonsothunder.com
> > > > > > Web Site: http://www.sonsothunder.com/
> > > > > >
> > > > > >
> > > > > > _______________________________________________
> > > > > > use-revolution mailing list
> > > > > > use-revolution at lists.runrev.com
> > > > > > Please visit this url to subscribe, unsubscribe and manage your
> > > > > > subscription preferences:
> > > > > > http://lists.runrev.com/mailman/listinfo/use-revolution
> > > > > >
> > > > > _______________________________________________
> > > > > use-revolution mailing list
> > > > > use-revolution at lists.runrev.com
> > > > > Please visit this url to subscribe, unsubscribe and manage your
> > > > > subscription preferences:
> > > > > http://lists.runrev.com/mailman/listinfo/use-revolution
> > > > >
> > > > _______________________________________________
> > > > use-revolution mailing list
> > > > use-revolution at lists.runrev.com
> > > > Please visit this url to subscribe, unsubscribe and manage your
> > > > subscription preferences:
> > > > http://lists.runrev.com/mailman/listinfo/use-revolution
> > > >
> > > _______________________________________________
> > > use-revolution mailing list
> > > use-revolution at lists.runrev.com
> > > Please visit this url to subscribe, unsubscribe and manage your
> > > subscription preferences:
> > > http://lists.runrev.com/mailman/listinfo/use-revolution
> > >
> > _______________________________________________
> > use-revolution mailing list
> > use-revolution at lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> > subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-revolution
> >
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>
More information about the use-livecode
mailing list