I was wondering how do I make a patcher like for example. I make a listbox, textbox, and a button. The listbox has nothing yet and someone who downloaded has nothing too. I add "Hi" and click the button. My listbox will now have "Hi". How do I make it when someone who downloaded has the word "Hi" without downloading again?
How do I make a patcher?
Page 1 of 110 Replies - 2021 Views - Last Post: 05 July 2009 - 08:07 PM
Replies To: How do I make a patcher?
#2
Re: How do I make a patcher?
Posted 05 July 2009 - 03:01 PM
koolazngy94, on 5 Jul, 2009 - 01:51 PM, said:
I was wondering how do I make a patcher like for example. I make a listbox, textbox, and a button. The listbox has nothing yet and someone who downloaded has nothing too. I add "Hi" and click the button. My listbox will now have "Hi". How do I make it when someone who downloaded has the word "Hi" without downloading again?
download ? are you downloading the text? or who ever has this app, when oppened, it shows hi as a item in the listbox?
#3
Re: How do I make a patcher?
Posted 05 July 2009 - 03:04 PM
Is like I updated my program. When someone open it, it will automatically update for them with the new list.
#4
Re: How do I make a patcher?
Posted 05 July 2009 - 03:54 PM
i get it.
the way I would do it is I would create a text file and then tell the application to display the text on open...
in you're form.load even try this
so when you load you're form it will check for that, download, then display... the last line might actually read all text in the file and not place it in items per text line...
but I am new to programming and this is what I came up for one of my apps and it works for me. good luck
the way I would do it is I would create a text file and then tell the application to display the text on open...
in you're form.load even try this
If My.Computer.FileSystem.FileExists(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt") Then
Me.Refresh()
Else
My.Computer.Network.DownloadFile("http://yoursitehere/list.txt", _
My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt")
End If
If My.Computer.FileSystem.FileExists(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt") Then
ListBox1.Items.Add(My.Computer.FileSystem.ReadAllText(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt"))
End If
so when you load you're form it will check for that, download, then display... the last line might actually read all text in the file and not place it in items per text line...
but I am new to programming and this is what I came up for one of my apps and it works for me. good luck
This post has been edited by unlimited24: 05 July 2009 - 03:56 PM
#5
Re: How do I make a patcher?
Posted 05 July 2009 - 04:11 PM
@unlimited24 Can you please stay within the rules of the forum and show no code unless the OP has shown at least a token effort in solving their problem
#6
Re: How do I make a patcher?
Posted 05 July 2009 - 04:15 PM
oh so sorry PsychoCoder... was eager to help my first person in a language that I'm studying I guess I forgot
#7
Re: How do I make a patcher?
Posted 05 July 2009 - 05:02 PM
Well I think I got it now. Thanks unlimited. But right now, I'm reinstalling my VB.NET so I can fix that one error.
#8
Re: How do I make a patcher?
Posted 05 July 2009 - 06:52 PM
There another problem. How do I make it automatically add the file to the website without me uploading it?
--EDIT--
wait can we just use mysql?
--EDIT--
wait can we just use mysql?
This post has been edited by koolazngy94: 05 July 2009 - 06:59 PM
#9
Re: How do I make a patcher?
Posted 05 July 2009 - 07:43 PM
Quote
wait can we just use mysql?
Yes, I believe you could. It would likely be easier than having to upload files every so often.
#10
Re: How do I make a patcher?
Posted 05 July 2009 - 07:53 PM
That isn't particularly what I would consider a "patch" though.
If your program is just using a text file (or database) to load data for internal purposes or whatever that would be a start, but if you are talking as in physically updating your executable you could look at this video.
If your program is just using a text file (or database) to load data for internal purposes or whatever that would be a start, but if you are talking as in physically updating your executable you could look at this video.
#11
Re: How do I make a patcher?
Posted 05 July 2009 - 08:07 PM
Ok, so I decided to go with unlimited idea but I what I want is if the file exist, it will be deleted and will be redownloaded.
Full Code
Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
If ComboBox1.Text = "Call of Duty 5" Then
My.Computer.Network.DownloadFile("http://havocpc.110mb.com/COD5.txt", _
My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/COD5.txt")
End If
Full Code
Public Class Form1
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Me.Close()
End Sub
Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
If ComboBox1.Text = "Call of Duty 5" Then
My.Computer.Network.DownloadFile("http://havocpc.110mb.com/COD5.txt", _
My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/COD5.txt")
End If
If My.Computer.FileSystem.FileExists(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/COD5.txt") Then
ListBox1.Items.Add(My.Computer.FileSystem.ReadAllText(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt"))
End If
If ComboBox1.Text = "The Conduit" Then
My.Computer.Network.DownloadFile("http://havocpc.110mb.com/Conduit.txt", _
My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/Conduit.txt")
End If
If My.Computer.FileSystem.FileExists(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/Conduit.txt") Then
ListBox1.Items.Add(My.Computer.FileSystem.ReadAllText(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt"))
End If
If ComboBox1.Text = "Soldat" Then
My.Computer.Network.DownloadFile("http://havocpc.110mb.com/Soldat.txt", _
My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/Soldat.txt")
End If
If My.Computer.FileSystem.FileExists(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt") Then
ListBox1.Items.Add(My.Computer.FileSystem.ReadAllText(My.Computer.FileSystem.SpecialDirectories.MyDocuments & "/list.txt"))
End If
End Sub
End Class
This post has been edited by koolazngy94: 05 July 2009 - 08:09 PM
Page 1 of 1
|
|

New Topic/Question
Reply




MultiQuote






|