Re: Launching a URL in OSX is Cake?
on 25/1/02 7:11 AM, Scott Rossi at [EMAIL PROTECTED] wrote: I like using the ascii for delete as a placeholder, because it works fine and there's no way a user has typed it. You know, that's a good point about not being able to type delete. formFeed is another useful option. But watch out a bit, because the fact that a user can't type it doesn't mean it can't - at least in principle - be a character in a legitimate and genuine path. This isn't completely hairsplitting; all my file info xfcns return line format lists (ie ascii CR, 13, is the delimiter). My many useful old file manipulation stacks which recurse over folders now choke on the files that Apple introduced to hold custom icons for folders, named - so to speak - icon%0D (ie the file name ends with a return character - so my lists of files include two names of non-existent files, icon and empty). Ben Rubinstein | Email: [EMAIL PROTECTED] Cognitive Applications Ltd | Phone: +44 (0)1273-821600 http://www.cogapp.com| Fax : +44 (0)1273-728866 ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
Scott Rossi wrote: Recently, Geoff Canyon wrote: I like using the ascii for delete as a placeholder, because it works fine and there's no way a user has typed it. You know, that's a good point about not being able to type delete. formFeed is another useful option. Good idea, I hadn't thought of that one. Another one I use often is numToChar(3), which is the Enter key. Users can't type that one either. There's also the bell but I can't remember what its ascii number is. -- Jacqueline Landman Gay | [EMAIL PROTECTED] HyperActive Software | http://www.hyperactivesw.com ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
On Thursday, January 24, 2002, at 10:31 AM, I wrote: Am I missing something or is the launching URLs and mail links extremely easy in OSX? Using the following seems to launch IE or Mail perfectly: ### tURL is the HTTP or mail address to be launched put open location quote tURL quote into s do s as AppleScript Does anyone know of a reason why this method should be avoided? On a related note, Richard Gaskin suggested using something like the following AppleScript to launch a local HTML document. However, I found I had to change the directory delimiter of the document path to a colon to avoid execution errors. ### tLaunchPath is the path of the HTML document to be launched delete char 1 of tLaunchPath replace / with : in tLaunchPath put tell application quote Finder quote cr \ open file quote tLaunchPath quote cr \ end tell into s do s as AppleScript If anyone has found alternate scripts/techniques, I'm sure list members would appreciate any suggestions. Regards, Scott Rossi Creative Director, Tactile Media [EMAIL PROTECTED] http://www.tactilemedia.com ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
At 10:31 AM -0800 1/24/02, Scott Rossi wrote: Am I missing something or is the launching URLs and mail links extremely easy in OSX? Using the following seems to launch IE or Mail perfectly: ### tURL is the HTTP or mail address to be launched put open location quote tURL quote into s do s as AppleScript Does anyone know of a reason why this method should be avoided? Because programming should be hard! I remember when we had to write our own compilers BY HAND -- on an abacus! You kids today don't know how easy you have it... ;-) regards, Geoff ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
On Thursday, January 24, 2002, at 11:09 AM, Geoff Canyon wrote: Does anyone know of a reason why this method should be avoided? Because programming should be hard! I remember when we had to write our own compilers BY HAND -- on an abacus! You kids today don't know how easy you have it... On a related note, I come from a print background where we created page layouts by having type set for us on photo paper and pasting it down onto boards with rubber cement. Making corrections to anything required cutting the paper with an Exacto(TM) blade and pasting new type into position. Try this sometime with 6 point legal type and make it straight. You kids today with your fancy shmancy page layout programs and printers don't know how easy you have it... At any rate, it seems that launching any old document is also possible without having to reference the document's creator application: answer file Locate file: put it into tPath delete char 1 of tPath replace / with : in tPath put tell application quote Finder quote cr \ open file quote tPath quote cr \ end tell into s do s as AppleScript This should open the target document as if it was doubleclicked. Shouldn't this be more difficult? Regards, Scott Rossi Creative Director, Tactile Media [EMAIL PROTECTED] http://www.tactilemedia.com ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
At 11:40 AM -0800 1/24/02, Scott Rossi wrote: On a related note, I come from a print background where we created page layouts by having type set for us on photo paper and pasting it down onto boards with rubber cement. Making corrections to anything required cutting the paper with an Exacto(TM) blade and pasting new type into position. Try this sometime with 6 point legal type and make it straight. You kids today with your fancy shmancy page layout programs and printers don't know how easy you have it... I yield -- that sounds harder than writing a compiler, even on an abacus... At any rate, it seems that launching any old document is also possible without having to reference the document's creator application: answer file Locate file: put it into tPath delete char 1 of tPath replace / with : in tPath put tell application quote Finder quote cr \ open file quote tPath quote cr \ end tell into s do s as AppleScript This should open the target document as if it was doubleclicked. Shouldn't this be more difficult? It _is_ slightly more difficult, since you need to watch out for the / character in the legitimate path, which will have been translated to a : You could either escape the : which always gives me a headache, or do a character-by-character switch. I generally go the headache route, but I have no aspirin handy at the moment... regards, gc ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
Geoff Canyon wrote: It _is_ slightly more difficult, since you need to watch out for the / character in the legitimate path, which will have been translated to a : You could either escape the : which always gives me a headache, or do a character-by-character switch. I generally go the headache route, but I have no aspirin handy at the moment... I sometimes do it this way: replace colon with numToChar(8) in tPath replace / with colon in tPath replace numToChar(8) with / in thePath I like using the ascii for delete as a placeholder, because it works fine and there's no way a user has typed it. I have some Tylenol if you want it... -- Jacqueline Landman Gay | [EMAIL PROTECTED] HyperActive Software | http://www.hyperactivesw.com ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
At 4:18 PM -0600 1/24/02, J. Landman Gay wrote: Geoff Canyon wrote: It _is_ slightly more difficult, since you need to watch out for the / character in the legitimate path, which will have been translated to a : You could either escape the : which always gives me a headache, or do a character-by-character switch. I generally go the headache route, but I have no aspirin handy at the moment... I sometimes do it this way: replace colon with numToChar(8) in tPath replace / with colon in tPath replace numToChar(8) with / in thePath I like using the ascii for delete as a placeholder, because it works fine and there's no way a user has typed it. I have some Tylenol if you want it... You know, that's a good point about not being able to type delete. I would have: replace : with -: in tPath replace / with +: in tPath replace -: with / in tPath replace +: with : in tPath regards, Geoff ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Launching a URL in OSX is Cake?
Recently, Geoff Canyon wrote: I like using the ascii for delete as a placeholder, because it works fine and there's no way a user has typed it. You know, that's a good point about not being able to type delete. formFeed is another useful option. Regards, Scott Rossi Creative Director Tactile Media, Multimedia Design Email: [EMAIL PROTECTED] Web: www.tactilemedia.com ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard