IPB

Bienvenue invité ( Connexion | Inscription )

> [RÉSOLU] Créer un fichier de type Adresse Internet du Web (.webloc)
Options
clarusad
posté 22 Feb 2024, 15:50
Message #1


Macbidouilleur de bronze !
**

Groupe : Membres
Messages : 309
Inscrit : 17 Oct 2006
Lieu : Strasbourg, France
Membre no 70 694



Salut,
J'arrive à créer un fichier et écrire dedans mais ça ne fonctionne pas correctement. Seul Safari peut ouvrir ce type de fichier.
Qu'est-ce qui cloche dans le code suivant ?
Merci

Code
tell application "Finder"

    set myNAME to "apple"
    set myURL to "http://www.apple.com"
    
    set the myFILE to ((path to downloads folder) as text) & myNAME
    
    make new file at ((path to downloads folder)) with properties {name:myNAME, file type:"ilht", creator type:"MACS"}
    
    open for access file the myFILE with write permission
    write (myURL) to file the myFILE starting at eof
    close access file the myFILE
        
end tell


Ce message a été modifié par clarusad - 22 Feb 2024, 18:21.
Go to the top of the page
 
+Quote Post

Les messages de ce sujet


Reply to this topicStart new topic
1 utilisateur(s) sur ce sujet (1 invité(s) et 0 utilisateur(s) anonyme(s))
0 membre(s) :

 



Nous sommes le : 14th May 2024 - 04:10