Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

This code writes to a .ini file from a textbox using a combox as well. What would the code have if it was just from a TextBox?

ini.Write(ComboBox1.SelectedItem.ToString, "NickName", TextBox1.Text)

This Code reads from the .ini file sending to the textbox using a combobox. What would the code have to be if it was just sending it to the textbox?

TextBox1.Text = ini.ReadString(ComboBox1.SelectedItem.ToString, "NickName")

It's not impossible, it's Inevitable.
Posted
Is this a trick question? :)

 

ini.Write(TextBox1.text, "NickName", TextBox1.Text)

 

 

That made it save to the file like this:

 

[PureSc0pe] 'Shouldn't be here

Nickname=PureSc0pe

 

And it wrote the end of the file when Nickname= was already at the top...

 

And TextBox51.Text = ini.ReadString("serverip=") only reads what's in the []

It's not impossible, it's Inevitable.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...