January 11, 200620 yr I'm hoping there is a simple solution. I am exporting several DBs to .csv files and ftping them to a linux host. When the export is done on a PC no problems. On a Mac, the carriage returns in the uploaded file are not recognized and the data is handled like one long record in Linux. Is there away to get FM6 to export .csv with CR & LF (or which ever one linux is expecting)? Or does this need to be addressed on the receiving end? JRW
January 12, 200619 yr On the receiving end, or on the FM machine with some "post processing". An Applescript fired right after the export will do. Don't know enough AS to help you with the right syntax there...
January 12, 200619 yr On a Mac, the carriage returns in the uploaded file are not recognized and the data is handled like one long record in Linux. Try write a PHP script to do the CR & LF before importing to another DB in Linux (I'm assuming you're using Mysql).
January 13, 200619 yr Author Two steps forward... and one back. Thank you for the suggestion. This proved to be an interesting challenge. Ok, I completed an Applescript to convert the CRs to LFs (YEAH!). Thank goodness for the web. Put together a few scripts to eventually do what I needed. I run it from the Finder & all is good. I create a script in FM6 run AppleScript & say "tell finder launch (activate) myScript". Simple! Obviously FM6 is sending an action other than run/activate/open as the script opens and does nothing. Grr! Does anyone know what handler I need to declare in AS for a launch/activate being received from FM6? I'm SOOOOO close. JRW
January 14, 200619 yr Why not put the whole script in the "perform Applescript" script step instead of trying to launch something that is on the hard disk?
January 16, 200619 yr Author Good suggestion. I tried that too. -) The issue I have is with the script statement that I used "path to me" when contained within Filemaker returns "/Applications/Filemaker 6/Filemaker Developer" and not the path of where the DBs are. I've searched for a script command that that gives the current working directory (ala status (currentFilePath)). No such luck. Hm. Maybe I could save the path in a field & access it in the script. Let me work on that one. It's all new to me. (nothing like explaning a problem & coming up with a solution) Cheers, JRW
January 16, 200619 yr Author Well, if someone knows how to copy the contents of a field (or clipboard) into AS that would be nice to know. Anyway... In my search for finding a way to get the current path, I ran across another handler type for AS, "On idle". I put this in the script & voila. The script now runs in the background & quits. Problem solved. Thanks for the suggestions. Now on to testing. Cheers, JRW
Create an account or sign in to comment