Page 1 of 1

Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 3:44 pm
by dj1437
I copied a link like 5 times to make sure it was copied and then i went in chrome and pasted it and i got a code from what appears to be from a ospro autorun program :S
Code: Select all
    Dim Icon
    Dim File As String
    Dim Folder As String

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim openDLG As New OpenFileDialog
        openDLG.Filter = "Executable Files (*.exe)|*.exe|All Files (*.*)|*.*"
        DialogResult = openDLG.ShowDialog(Me)
        If DialogResult = DialogResult.OK Then
            Dim FileName As String = openDLG.FileName
            Dim LastSlash As Integer = FileName.LastIndexOf("\")
            File = FileName.Substring(LastSlash + 1)
            TextBox1.Text = File
            openDLG.Dispose()
        End If
    End Sub

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        Dim DIR As New FolderBrowserDialog
        DIR.Description = "Select the path to save the 'autorun.inf' file to..."
        DialogResult = DIR.ShowDialog()
        If DialogResult = DialogResult.OK Then
            Folder = DIR.SelectedPath
            TextBox2.Text = (Folder)
        End If
        DIR.Dispose()
    End Sub

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        Dim openDLG As New OpenFileDialog
        openDLG.Filter = "Icon Files (*.ico)|*.ico|All Files (*.*)|*.*"
        DialogResult = openDLG.ShowDialog(Me)
        If DialogResult = DialogResult.OK Then
            PictureBox1.Image = Image.FromFile(openDLG.FileName)
            Dim LastSlash As Integer = openDLG.FileName.LastIndexOf("\")
            Icon = openDLG.FileName.Substring(LastSlash + 1)
        End If
        openDLG.Dispose()
    End Sub

    Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
        If CheckBox1.Checked Then
            Button3.Enabled = False
        Else
            Button3.Enabled = True
        End If
    End Sub

    Private Sub CheckBox2_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox2.CheckedChanged
        If CheckBox2.Checked Then
            TextBox3.ReadOnly = True
        Else
            TextBox3.ReadOnly = False
        End If
    End Sub

    Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
        TextBox3.Clear()
        TextBox3.AppendText("[autorun]" & vbNewLine)
        TextBox3.AppendText("open = " & File & vbNewLine)
        If CheckBox1.Checked Then
            TextBox3.AppendText("icon = " & File)
        Else
            TextBox3.AppendText("icon = " & Icon)
        End If
    End Sub

    Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        Try
            Dim writeFile As New IO.StreamWriter(Folder & "\autorun.inf", False)
            writeFile.WriteLine("[autorun]")
            writeFile.WriteLine("open = " & File)
            If CheckBox1.Checked Then
                writeFile.WriteLine("icon = " & File)
            Else
                writeFile.WriteLine("icon = " & Icon)
            End If
            writeFile.Flush()
            writeFile.Close()
        Catch exc As Exception
            MessageBox.Show(exc.ToString)
        End Try
    End Sub

    Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
        MsgBox("This software was developed by ObsprO.", MsgBoxStyle.Information, "ObsprO Autorun Creator")
    End Sub

    Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
        Me.Close()
    End Sub

Re: Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 3:51 pm
by Cheatmasterbw
It looks like it is:
Code: Select all
...
MsgBox("This software was developed by ObsprO.", MsgBoxStyle.Information, "ObsprO Autorun Creator")
...

Re: Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 4:01 pm
by dj1437
thats not my point, i never copied that code from anywhere, i copied a youtube link and thats what happened when i pasted into my adressbar

Re: Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 4:09 pm
by Cheatmasterbw
I know that, but i am just wondering why it happened.

Re: Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 4:59 pm
by Napster1488
Awesome :D maybe next Time when u copy a Link into Adressbar maybe then u get a Source Code for a Program to Implent JavaScript into a WebPage :D i could really need it :P

Re: Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 6:26 pm
by mandai
There can be situations where the clipboard is in use by other programs, this might stop it from being updated.

Re: Clipboard Glitch!!!

Posted: Sat Mar 26, 2011 6:30 pm
by Usman55
???
lol, you just leaked my source code! But I don't mind cuz yesterday I was thinking of reducing all of the source codes' cc price but then I forgot. If you people want, please reply, and I'll reduce all of the prices and give away all of 'em!