Sign in to follow this  
Followers 0
onedayillpay

config.cfg help

13 posts in this topic

#include <File.au3>

_FileWriteToLine("C:\Program Files\Steam\steamapps\francescaklinger\counter-strike\cstrike\cfgfuck.cfg", 3, "my replacement for line 3", )

i have a file in my cstrike folder calld "cfgfuck.cfg" and i dont understand why that line of code wont work...maybe the file has to be .txt format

Share this post


Link to post
Share on other sites



except for the comma at the end i was able to make it work.

(of course i tested a different directory)

#include <File.au3>

_FileWriteToLine("C:\Program Files\Steam\steamapps\francescaklinger\counter-strike\cstrike\cfgfuck.cfg", 3, "my replacement for line 3" )

Share this post


Link to post
Share on other sites

except for the comma at the end i was able to make it work.

(of course i tested a different directory)

#include <File.au3>

_FileWriteToLine("C:\Program Files\Steam\steamapps\francescaklinger\counter-strike\cstrike\cfgfuck.cfg", 3, "my replacement for line 3" )

what comma?

Share this post


Link to post
Share on other sites

#include <File.au3>

_FileWriteToLine("C:\Program Files\Steam\steamapps\francescaklinger\counter-strike\cstrike\cfgfuck.cfg", 3, "my replacement for line 3",1)

o yah...i ment to post this likne of code

i want to replace line 3

Share this post


Link to post
Share on other sites

code still works for me. what kind of error are you getting? it just doesn't do anything? or error?

Share this post


Link to post
Share on other sites

it just does nothing...even the the _filewritetoline in the help file does nothing

Share this post


Link to post
Share on other sites

its realy starting to piss me off

i unistalld and reinstalld

and still the _filewritetoline located in the help folder dont work

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

still dont work...

ok im just going to use fileWrite

now im getting some were

but how do you filewrite this key "

i need to add this line to the cfgfile

amx_nick "2134235" "testname"

but how do you filewrite this key "

------------------example-code---------------------------

$target = InputBox("cfgfuck", "Enter steamID", "", "")

$file = FileOpen("cfgfuck.cfg", 2)

; Check if file opened for writing OK

If $file = -1 Then

MsgBox(0, "Error", "Unable to open file.")

Exit

EndIf

FileWrite($file, "amx_nick " & $target & " testname" )

FileWrite($file, "")

FileWrite($file, "")

FileClose($file)

Edited by onedayillpay

Share this post


Link to post
Share on other sites

so how do you send the key " to a txt file using filewrite

Share this post


Link to post
Share on other sites

so how do you send the key " to a txt file using filewrite

double them up or use single quotes around it. Check the FAQ in the help file, it's explained in there.

Share this post


Link to post
Share on other sites

#12 ·  Posted (edited)

send("+'") works if you want to send "

but im trying to filewrite that key

FileWrite($file, ' " ')

FileWrite($file, """"""""""""""""""""""""""""""""""""""""""Frustrated)

ok i got it it takes four filewrite(" " " ")

gadamn y was that not in the read me

Edited by onedayillpay

Share this post


Link to post
Share on other sites

"This is a string with ""double quotes"" in it."

-or-

'This is a string with "double quotes" in it.'

Read the help file.

Share this post


Link to post
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
Sign in to follow this  
Followers 0