Author |
Message |
mbslrm
|
Posted: Mon Jun 01, 2009 7:26 pm Post subject: Copying a Font to the Windows Font Directory |
|
|
What is it you are trying to achieve?
I'm trying to copy a font to the Windows Font Directory from within Turing.
What is the problem you are having?
We can't use batch files since the school computers have disabled cmd.
Describe what you have tried to solve this problem
I made a batch file that would copy it, which I would just call within Turing.
Please specify what version of Turing you are using
4.1 |
|
|
|
|
|
Sponsor Sponsor
|
|
|
DemonWasp
|
Posted: Mon Jun 01, 2009 7:48 pm Post subject: RE:Copying a Font to the Windows Font Directory |
|
|
You could use File.Copy. |
|
|
|
|
|
mbslrm
|
Posted: Mon Jun 01, 2009 8:31 pm Post subject: RE:Copying a Font to the Windows Font Directory |
|
|
Thanks! |
|
|
|
|
|
mbslrm
|
Posted: Mon Jun 01, 2009 10:42 pm Post subject: Re: Copying a Font to the Windows Font Directory |
|
|
I keep getting "Did not copy the file.
Error: Access (Permission) Denied"
I used the following, as per the example in the link you posted:
(I also tried C:/WINDOWS/Fonts, which shouldn't and didn't make a difference.
Turing: |
File.Copy ("bubble.ttf", "C:\\WINDOWS\\Fonts")
if Error.Last = eNoError then
put "File copied"
else
put "Did not copy the file."
put "Error: ", Error.LastMsg
end if
|
|
|
|
|
|
|
Dan
|
Posted: Mon Jun 01, 2009 10:56 pm Post subject: RE:Copying a Font to the Windows Font Directory |
|
|
I think you need administration rights to copy a file to the fonts folder in windows vista (and posbliy xp).
So you would have to run the turing program as the administrator (witch is not overly safe). |
Computer Science Canada
Help with programming in C, C++, Java, PHP, Ruby, Turing, VB and more! |
|
|
|
|
mbslrm
|
Posted: Mon Jun 01, 2009 11:01 pm Post subject: RE:Copying a Font to the Windows Font Directory |
|
|
That's what I thought too...
This is happening on my home computer (XP SP3) on an Administrator account, so this technique probably isn't going to work at school.
What other ways are there? |
|
|
|
|
|
mbslrm
|
Posted: Mon Jun 01, 2009 11:16 pm Post subject: RE:Copying a Font to the Windows Font Directory |
|
|
Could I make a visual basic script and then call it within Turing? |
|
|
|
|
|
DemonWasp
|
Posted: Tue Jun 02, 2009 8:27 am Post subject: RE:Copying a Font to the Windows Font Directory |
|
|
You could, but it probably wouldn't help much. The problem is with access permissions on that directory, not the language you're coding in. Unless you can somehow elevate the VB code you call to administrator-level permissions (ah, sudo, how I wish you were available on Windows) it won't be able to do it. |
|
|
|
|
|
Sponsor Sponsor
|
|
|
mbslrm
|
|
|
|
|
|