Jump to content

java.policy


Recommended Posts

wordpad

FileRead()/FileWrite() don't work...? Is it Unicode? If so, you just have to use the latest version of AutoIt and some extra parameters.

:whistle:

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

yap it is in unicode. wat are the extra stuffs i need to add.

thanks.

AutoIt now supports Unicode, if you are running the current version. You just specify that by options when you do FileOpen().

:whistle:

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

$file = FileOpen("d:\java.policy", 128)

; Check if file opened for writing OK
If $file = -1 Then
    MsgBox(0, "Error", "Unable to open file.")
    Exit
EndIf

FileWriteLine($file, "Line1")
FileWriteLine($file, "Line2" & @CRLF)
FileWriteLine($file, "Line3")

FileClose($file)

i tried the open codes. when i output to a msgbox its fine...but i just cant get it to write some data into it...

i tried with 32 and 64 as well. same problems.

mouse not found....scroll any mouse to continue.

Link to comment
Share on other sites

If you set FileOpen mode just as 128 or 64 or 32, it means file will be opened in read mode (0).

UTF8 (over)write mode would be 128+2

Edited by Siao

"be smart, drink your wine"

Link to comment
Share on other sites

thanks siao, i should have looked at the Help more carefully before posting.

ok, another thing is this......

#include <File.au3>

$file2 = FileOpen("d:\java.policy", 130)

; Check if file opened for writing OK
If $file2 = -1 Then
    MsgBox(0, "Error", "Unable to open file.")
    Exit
EndIf

_FileWriteToLine($file2, 3, "my replacement for line 3", 1)

FileClose($file2)

Why doesnt my _FileWriteToLine work? thanks.

mouse not found....scroll any mouse to continue.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...