Re: Write file imports with spaces
Re: Write file imports with spaces
- Subject: Re: Write file imports with spaces
- From: Matt Deatherage <email@hidden>
- Date: Wed, 18 Jul 2007 22:55:05 -0500
On 7/19/07 at 9:40 PM, Tim Mansour <email@hidden> wrote:
> On 19/07/2007, at 12:04 pm, John Haley wrote:
>
> >Now when I try to import AccountEdge is putting a space between every
> >character.
>
> That'll be because FileMaker has moved to Unicode, and it sounds like
> MYOB hasn't. You'll have to convert your text before importing;
> amongst other methods the TextCommands scripting addition can do this
> for you.
To clarify: they're not "spaces" between the characters, they're 0x00
bytes, as in the high bytes of UTF-16 characters. A value stored in a
FileMaker Pro "text" cell of "MWJ" is actually returned to AppleScript
as the Unicode bytes 0x00 4D 00 57 00 4A, not as the ASCII characters
0x4D 57 4A.
(Script Debugger 4 is your great friend here - its explorer clearly
shows the types of the text with the "UTF-16" icon.)
My scripts have been doing this for years and I had no trouble with UTF
when moving to FileMaker 8, 8.5, or even 9, nor when upgrading
AccountEdge every year. However, upon looking, I see that I'm exporting
the text from within FileMaker, not from AppleScript. For
compatibility, when you tell FileMaker to export a "text" file, it still
uses ASCII and expects you to pick a more modern format if you need
non-ASCII support.
You should be sure to contact MYOB and tell them you need Unicode import
support, by the way - it may be too late for the next version, and if
not, it's really close.
--Matt
--
Matt Deatherage <email@hidden>
GCSF, Incorporated <http://www.macjournals.com>
"I write to discover what I think. After all, the bars aren't open that
early." -- Daniel J. Boorstein, on why he wrote at home from 6:30 AM to
8:30 AM (Wall Street Journal, 1985.12.31)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden