dbTalk Databases Forums  

File Paths Don't Work Upon Restarting Database

comp.databases.filemaker comp.databases.filemaker


Discuss File Paths Don't Work Upon Restarting Database in the comp.databases.filemaker forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
asimon623@gmail.com
 
Posts: n/a

Default File Paths Don't Work Upon Restarting Database - 11-11-2006 , 12:52 PM






Hi, I'm pretty new to filemaker. I made an export script which exports
all records to a file and then executes a bat file to rename that file,
move it to a different location, and check the validity of the file.
The script worked fine when I first made it. When I exited out of
filemaker, and then opened my program again, it didn't work. I went
into my script, respecified the files (the export file and the bat),
and it worked. The specifications were exactly the same. I exited,
reentered, and the same problem with the same fix.

Can anybody tell me what to do differently

thanks


Reply With Quote
  #2  
Old   
Kent
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-11-2006 , 01:12 PM






We don't have enough information to help.

1) Is the export working or not?
2) If it works, is the exported file ending up in the right place?
3) A) If those are both OK, is the batch file executing?
B) Correctly

1 and 2 you can figure out by doing a search for the file exported, and see if it
exists in the wrong place.

3 you can check by (temporarily) putting a wait command at the end of the batch
file, which will tell you if the batch is running, and if it can't find the file
(error message)

Relative paths can be trouble if something is executed from a shortcut in a
different place, or gets moved.

Absolute paths have dangers when moved to other computers.

Kent

asimon623 (AT) gmail (DOT) com wrote:
Quote:
Hi, I'm pretty new to filemaker. I made an export script which exports
all records to a file and then executes a bat file to rename that file,
move it to a different location, and check the validity of the file.
The script worked fine when I first made it. When I exited out of
filemaker, and then opened my program again, it didn't work. I went
into my script, respecified the files (the export file and the bat),
and it worked. The specifications were exactly the same. I exited,
reentered, and the same problem with the same fix.

Can anybody tell me what to do differently

thanks


Reply With Quote
  #3  
Old   
asimon623@gmail.com
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-12-2006 , 01:57 AM



I'm sorry, I said it worked, but I guess it was a little unclear

The export works fine, the files end up in the right place, the batch
executes and works fine

The only problem I'm having is that everytime I exit filemaker, I have
to respecify the export location and the batch file I want to use.
Basically, the path is saving correctly within the script, but for some
strange reason, will not work unless I go back in and retype it in
exactly as it was.


Reply With Quote
  #4  
Old   
eyebrown@mindspring.com
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-12-2006 , 08:55 AM



In article <1163318248.017547.283590 (AT) f16g2000cwb (DOT) googlegroups.com>,
asimon623 (AT) gmail (DOT) com wrote:

Quote:
The only problem I'm having is that everytime I exit filemaker, I have
to respecify the export location and the batch file I want to use.
Basically, the path is saving correctly within the script, but for some
strange reason, will not work unless I go back in and retype it in
exactly as it was.
Sorry, I can't answer your specific problem, but I'd like to take
advantage of this thread to ask a more general question, the answer to
which may solve your problem.

That is, can anyone supply a clear succinct explanation of when and when
not to click the "save relative path" checkbox in defining relationships,
the perform external script step and in import/export script steps? The
help file is maddeningly unclear.

I'm running a solution in FM 6, served by FM 5.5 Server, with about two
dozen clients. I have lots of exporting and importing of text files as I
interact with an old DOS program, and also pass stuff into and out of some
MySQL tables.

In addition, there are circumstances where I want to make a small FM file
that is *not* served, but is related to and from various served files.
These unserved files live on a hard drive of a machine available to all
clients.

When should a path be "relative" and when should it be absolute? I note
that "save relative path" comes checked by default and it must be
consciously chosen to deselect. One of my employees says he routinely
unchecks it all the time. He says that rather than give FM an "idea"
where something is, or where an export goes, he would rather tell it
definitively where it is.

Most client machines are Win2000, two of them are Mac OS X, the FM Server
is Mac OS X, if that makes a difference.

Most of time time, "save relative path" goes through checked. Most of the
time there are no issues. Sometimes a client machine will execute a
script that calls an external script and gets a "cannot find file
so-and-so" error. Navigation to the file seems to clear this up and
future activations of that script run okay.

But all this is trial-and-error on my part. I'd love to know exactly when
and when not to click that little box.

Steve Brown


Reply With Quote
  #5  
Old   
Kent
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-12-2006 , 10:21 AM



My apologies, I was the one who was unclear. I was wondering what the result is
after you have quit and restarted. I wondered if everything was happening, but
with one or more things happening in the wrong place, or if the script was failing
to execute completely, or just prompting you for the location?

When you run after restarting, does the script and batch fail to execute, or do
you simply not get the file you are hoping for? The latter might indicate that the
export is happening after restart, but that one or more things are aimed wrong
(after restart). The only (pretty long shot) guess I have is could you be
maneuvering to your path via a mapped network drive that is not necessarily
constant between runs? I'm afraid this one is over my head. I honestly have no
idea what else would cause the result you are getting. Sorry.

Kent


asimon623 (AT) gmail (DOT) com wrote:
Quote:
I'm sorry, I said it worked, but I guess it was a little unclear

The export works fine, the files end up in the right place, the batch
executes and works fine

The only problem I'm having is that everytime I exit filemaker, I have
to respecify the export location and the batch file I want to use.
Basically, the path is saving correctly within the script, but for some
strange reason, will not work unless I go back in and retype it in
exactly as it was.


Reply With Quote
  #6  
Old   
Kent
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-12-2006 , 10:27 AM



Relative path is ideal when you have no way to guarantee under what configuration
the end solution will be used. If you are going to require the user to place their
solution in a particular spot and leave it there, absolute file paths are OK. If
there is any chance a folder won't be exactly where you want it, then you need to
keep everything you do inside your own folder (recursively), and use relative
paths. In particular (on Windows anyway) if you are going to make use of
individual users "my Documents" folder, by dropping your solution there, you need
to use relative for everything, since there is no way to anticipate what their
folder will be called.

Kent



eyebrown (AT) mindspring (DOT) com wrote:
Quote:
In article <1163318248.017547.283590 (AT) f16g2000cwb (DOT) googlegroups.com>,
asimon623 (AT) gmail (DOT) com wrote:

The only problem I'm having is that everytime I exit filemaker, I have
to respecify the export location and the batch file I want to use.
Basically, the path is saving correctly within the script, but for some
strange reason, will not work unless I go back in and retype it in
exactly as it was.

Sorry, I can't answer your specific problem, but I'd like to take
advantage of this thread to ask a more general question, the answer to
which may solve your problem.

That is, can anyone supply a clear succinct explanation of when and when
not to click the "save relative path" checkbox in defining relationships,
the perform external script step and in import/export script steps? The
help file is maddeningly unclear.

I'm running a solution in FM 6, served by FM 5.5 Server, with about two
dozen clients. I have lots of exporting and importing of text files as I
interact with an old DOS program, and also pass stuff into and out of some
MySQL tables.

In addition, there are circumstances where I want to make a small FM file
that is *not* served, but is related to and from various served files.
These unserved files live on a hard drive of a machine available to all
clients.

When should a path be "relative" and when should it be absolute? I note
that "save relative path" comes checked by default and it must be
consciously chosen to deselect. One of my employees says he routinely
unchecks it all the time. He says that rather than give FM an "idea"
where something is, or where an export goes, he would rather tell it
definitively where it is.

Most client machines are Win2000, two of them are Mac OS X, the FM Server
is Mac OS X, if that makes a difference.

Most of time time, "save relative path" goes through checked. Most of the
time there are no issues. Sometimes a client machine will execute a
script that calls an external script and gets a "cannot find file
so-and-so" error. Navigation to the file seems to clear this up and
future activations of that script run okay.

But all this is trial-and-error on my part. I'd love to know exactly when
and when not to click that little box.

Steve Brown

Reply With Quote
  #7  
Old   
eyebrown@mindspring.com
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-13-2006 , 06:28 AM



In article <UXH5h.292743$1T2.150447@pd7urf2no>, Kent
<kent.news.account (AT) gmail (DOT) com> wrote:

Quote:
Relative path is ideal when you have no way to guarantee under what
configuration
the end solution will be used. If you are going to require the user to
place their
solution in a particular spot and leave it there, absolute file paths are
OK. If
there is any chance a folder won't be exactly where you want it, then you
need to
keep everything you do inside your own folder (recursively), and use relative
paths. In particular (on Windows anyway) if you are going to make use of
individual users "my Documents" folder, by dropping your solution there,
you need
to use relative for everything, since there is no way to anticipate what their
folder will be called.
Thanks, Kent. That's a much better explanation than the FM help.

Steve Brown


Reply With Quote
  #8  
Old   
asimon623@gmail.com
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-19-2006 , 03:13 PM




After restart, the batch file isn't found. Because of this, the export
can't work. It's like the filepath isn't saving right, but it is...I
just have to respecify the file, but it's the exact same location every
single time.


Reply With Quote
  #9  
Old   
Kent
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-20-2006 , 05:00 AM



Have you tried putting the batch file elsewhere? Or perhaps a shortcut to the
batch file in the active Filemaker directory or root directory? Maybe try
compiling the batch file (after backing it up since you can't modify it once
compiled) in a .com file and running it that way to see if it makes a difference?

Kent

asimon623 (AT) gmail (DOT) com wrote:
Quote:
After restart, the batch file isn't found. Because of this, the export
can't work. It's like the filepath isn't saving right, but it is...I
just have to respecify the file, but it's the exact same location every
single time.


Reply With Quote
  #10  
Old   
asimon623@gmail.com
 
Posts: n/a

Default Re: File Paths Don't Work Upon Restarting Database - 11-23-2006 , 10:49 AM



Wow, I put the batch file in the system32 with the paths and it works
now. So basically, it has to be in the same directory as my filemaker
database or with paths. That's quite annoying, but I'll deal

Thanks for the help


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.