this is the submit chat codeCode:Private Sub cmdSubmit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdSubmit.Click If txtPost.Text <> "" Then If txtUsername.Text <> "" Then ShoutBox.AddPost(frmMain.txtLid.Text, txtPost.Text, ) txtPost.Text = "" Else End If Else MsgBox("Please fill in a post.", MsgBoxStyle.Information) End If End Sub
how would i split the text so i can code irc type commands
such as
/title {input}
| = split
i want to split the / | my.settings.title | "{input}"
and the
if txtpost.text = "/title" split {input} then
lable1.text = "{output}"
end if
please and thankyou
Last edited by cosconub; 01-16-2011 at 03:00 AM.
~Mohandas GandhiA man is but the product of his thoughts what he thinks, he becomes.
~ ImmortalA Genius is nothing with out an idea, An idea is always an idea even without a genius.
You can win the rat race,Originally Posted by Jeremy S. Anderson
But you're still nothing but a fucking RAT.
++Latest Projects++
[Open Source] Injection Library
Simple PE Cipher
FilthyHooker - Simple Hooking Class
CLR Injector - Inject .NET dlls with ease
Simple Injection - An in-depth look
MPGH's .NET SDK
eJect - Simple Injector
Basic PE Explorer (BETA)
let me some it up...
i want to beable to type
/title mytext in to my chatbox and click submit
and instead of posting it changes lable1.text to mytext
~Mohandas GandhiA man is but the product of his thoughts what he thinks, he becomes.
~ ImmortalA Genius is nothing with out an idea, An idea is always an idea even without a genius.
Dim yourstring as string = "/title blubb"
Dim x() as string = yourstring.split(" ")
msgbox(x(1))
If that does not work, use regex.split.
cosconub (01-16-2011)
Or something like this:
[php]
If TextBox1.Text.StartsWith("/") Then
Dim firstInd As integer = TextBox1.Text.IndexOf(" "c)
Dim command As String = TextBox1.Text.Substring(1, firstInd)
Dim content As String = TextBox1.Text.SubString(firstInd+1)
If command.ToLower = "title" then
Label1.Text = content
End If
End If
[/php]
You can win the rat race,Originally Posted by Jeremy S. Anderson
But you're still nothing but a fucking RAT.
++Latest Projects++
[Open Source] Injection Library
Simple PE Cipher
FilthyHooker - Simple Hooking Class
CLR Injector - Inject .NET dlls with ease
Simple Injection - An in-depth look
MPGH's .NET SDK
eJect - Simple Injector
Basic PE Explorer (BETA)
cosconub (01-17-2011)