Re: LiveUpdate. Downloads from web and updates multiple client files.
the demoUI project is in the vbLiveUpdate folder.
But u should write your own UI for this.
The dlls acan be placed anywhere on the PC...as long as they are registered with the registry. This is doen automatically when u compile, or u can use RegSvr32 "path to dll" to manually register dlls.
I would suggest you find some resources onj the web about using dlls in apps, as you seem to be a little bit new to it, and this project si certainly quite complicated.
woka
Re: LiveUpdate. Downloads from web and updates multiple client files.
Hi All,
This LiveUpdate application by Wokawidget, can I use it for a local network using shared folders? Say for example, I have a file name InfoReportXP.exe and is located in \\PC1\INFOREPORTXP, how can I take advantage of this LiveUpdate program without connecting to the internet since the file is located in a Local Area Network? Does this program allows checking the date of modification instead of checking the version of a file?
Please advise...
Thanks,
Doms
Re: LiveUpdate. Downloads from web and updates multiple client files.
i am not sure. give \\PC1\ a try instead of the IP address.
I was thinking of modified date, but then I decided against this. U can code that in yourself, it's entirely up to you, but the code currently works off a version number.
Woka
Re: LiveUpdate. Downloads from web and updates multiple client files.
ok hey woka,
I put the LiveUpdate aside for a little while and now I'm back on it.
I seem to be having the same problem as Flattery where it's not detecting the new line in the text file.
I am testing with your demoUI, the updates it comes with and the Updates.txt file supplied as well. When it downloads the Updates.txt to the C:\ drive and processes the data, it does not detect the line break properly in the SetUpdate function, so it cannot split the updates properly. I will try adding ;; at the end of each line like flattery did and use the following code in the function:
VB Code:
strData() = Split(pstrData, ";;", , vbTextCompare)
EDIT 1:
Ok that works, i put it all on 1 line and separated each update by a double semi-colon ( ;; ). The txt file doesn't look as tidy as originally, but it works!
EDIT 2:
Is there any way to show what version it's downloading/updating to, rather than just saying that it updated the product? So lets say the user has version 1 on their computer, and they check for the updates, and there is a version 2 available. Before the user clicks next to download the update, it would list the product being updated and the version that it's updating to. Is that possible?
Also, is there any way to run the live update silently, so like quickly check if an update is available everytime the user starts the program, and if there is an available update, it would run the LiveUpdater GUI then.
EDIT 3:
one more question. How do I add updates to install to mobjLiveUpdate_StartProductInstall? Would I do something like this?:
VB Code:
Private Sub mobjLiveUpdate_StartProductInstall(Product As vbLiveUpdate.Product, Success As Boolean)
Dim iExit As Long
Launch(mobjLiveUpdate.SaveTo & Product.Update.FileName)
Success = True
End Sub
Is that correct?
EDIT 4:
arrggg... ok I'm getting an annoying problem. When I open the VB group of projects that came with the zip file and run the demoUI, the liveUpdate works PERFECTLY.... BUT When I compile the DLLs and run the demoUI separately using the compiled DLLs as references, the liveUpdate works fine until the end. It finds the updates, downloads the updates, but when it gets to the last page where it shows which updates were downloaded, it doesn't show anything in the list. No errors. Why does it work fine when I run it in the vb group, but it doesn't work when I use the compiled DLLs as a reference.
The only changes I made were to the vbLiveUpdate project. I changes the line (see the code above ... strData() = ....) And that works fine in the vb group. Any ideas? Sorry to post so many questions.
Re: LiveUpdate. Downloads from web and updates multiple client files.
1) Not sure why. Worked perfectly well with the text file and code I used. I used notepad to create the text file.
2)
a) Yes, in the UI just display the version number property. You will have to add a property to the update class to handle this and populate it from the text file.
b) Silent...errr....yes. Look at my demo as it has this in there.
3) Yes, or you could combine that with my multi threading code to run it aync. The link is in my sig and full source code and demo code is available to download.
4) No idea. Add MsgBox's to parts of the code and use them to trace when it gets up to.
Alas I do not have VB6 on my PC anymore and so cannot run this code :(
I'll get it put back on soon.
Woof
Re: LiveUpdate. Downloads from web and updates multiple client files.
Thanks for the cool program Woka
i have a problem with my app
i want to liveupdate a database on the users PCs with last new rows i added to it
could your app help me
Re: LiveUpdate. Downloads from web and updates multiple client files.
I supose yea.
What u can do is have an Update.txt file or something that either contained the raw data, or some SQL scripts to update the DB.
Then just use the liveupdate app to download this txt file....once downloaded then your app can do what ever it wants with the file/data in the txt file.
Woka
Re: LiveUpdate. Downloads from web and updates multiple client files.
Re: LiveUpdate. Downloads from web and updates multiple client files.
Re: LiveUpdate. Downloads from web and updates multiple client files.
I realize that this is an old thread although Ive been trying to use this script. Got it working and all and trying to modify it slightly to allow each file to specify its own filepath in the updates.txt This is what I came up with. I modified the OpenFile() sub in download.cls to this.
Code:
Private Sub OpenFile()
Dim temp As String
Dim parse() As String
If Dir(mstrLocalPath) = vbNullString Then
Err.Raise 76
End If
If Not (Dir(mstrLocalPath & GetFilename(mstrRemoteFile)) = vbNullString) Then
Kill mstrLocalPath & GetFilename(mstrRemoteFile)
End If
If InStr(GetFilename(mstrRemoteFile), "Updates.txt") > 0 Then
mstrLocalPath = "C:\Program Files\Sony\Station\Infantry\nodbot\"
mlngFreeFile = FreeFile
Open mstrLocalPath & GetFilename(mstrRemoteFile) For Binary Access Write Lock Write As #mlngFreeFile
Else
Open "C:\Program Files\Sony\Station\Infantry\nodbot\Updates.txt" For Input As #1
Do Until EOF(1)
Line Input #1, temp
parse = Split(temp, ";")
If InStr(GetFilename(mstrRemoteFile), parse(3)) > 0 Then
mstrLocalPath = parse(6)
End If
mlngFreeFile = FreeFile
Open mstrLocalPath & GetFilename(mstrRemoteFile) For Binary Access Write Lock Write As #mlngFreeFile
Loop
Close #1
Kill "C:\Program Files\Sony\Station\Infantry\nodbot\Updates.txt"
End If
End Sub
Anybody have any other ideas?