PDA

Click to See Complete Forum and Search --> : Package And Deployment Problem


prafulpatil
Jan 5th, 2005, 08:00 AM
Hi Friends
I need your help. I have created my Package. I want to install the project on almost 800 computers. I can run the Set up by keeping Package at one location (Folder) and get installed my project on all Pcs. But problem is that when I modifies my exe then again to make available that exe to all PCs, I can keep that Exe on the shared location. But All Pcs need to delete the previous exe and copy the new exe. I just want to make it confim that Is there any way I can achieve this from one location may be from server....
Can you suggest me any other way?
Thanks in advance and bye
Praful

RhinoBull
Jan 5th, 2005, 09:39 AM
How do you reach all oft hose 800 worstations? Are they in your LAN ?
For those that are copy your package to a server and ask your network admin to create an autoinstall script - application will be installed when user login and all new updates will automatically be replaced.
For remote users you may need to send CD ...

Wokawidget
Jan 5th, 2005, 09:44 AM
You could write an auto update app that downloads the setup.exe package from a remote location...?

When a user launches the app, it checks for an upgrade, if there is one then it installs it...

Woka

agmorgan
Jan 5th, 2005, 12:27 PM
You could write an auto update app that downloads the setup.exe package from a remote location...?

When a user launches the app, it checks for an upgrade, if there is one then it installs it...

Woka
Conviniently I have already written an ActiveX control to let you do just that
:)

Check out the link in my sig

Wokawidget
Jan 5th, 2005, 04:52 PM
Cool. Will check it out.

agmorgan
Jan 5th, 2005, 05:16 PM
Ah. Technically it doesnt run a setup file but replaces the current exe.
This is acceptable assuming that you have only made changes that dont require extra dependancies.

Im sure you could modify it/rewrite it to include an option to download a setup file though. ;)

Wokawidget
Jan 5th, 2005, 05:48 PM
Hmmmm...

I am intregued.

If I open IE, and goto:

http://LocalHost/Woof.exe

Then IE asks if I want to download the file.
The same happens when I try and download the file with many download apps.

But when I use this address and do:

'this code is in the Update method
strFileName = Right(m_RemoteEXE, Len(m_RemoteEXE) - 7)
Set objFSO = New FileSystemObject
Set objFile = objFSO.GetFile(strFilename) 'THIS LINE ERRORS
strRemoteVer = objFSO.GetFileVersion(strFilename)

I get an error 53, File Not Found :(
If I comment this line out, and just try to get the remote version, then this doesn't error, but it returns the version as "".
The value of strFilename is LocalHost/Woof.exe

Any ideas?

Woka

prafulpatil
Jan 6th, 2005, 02:09 AM
Hi Guys ...I really Appreciate your promt reply..As I am newbie...I really did not understant everything you wrote in the reply. Can someone eloborate me in details....May be providing Code will help me...
Thanks and regards
Praful

Wokawidget
Jan 6th, 2005, 04:26 AM
In agmorgan post he mentions he already has code to do this.
Click on the Auto Update link in his sig.

If you need any help then give us a shout.

Woka

agmorgan
Jan 6th, 2005, 06:29 PM
Hmmmm...

I am intregued.

If I open IE, and goto:

http://LocalHost/Woof.exe

Then IE asks if I want to download the file.
The same happens when I try and download the file with many download apps.

But when I use this address and do:

'this code is in the Update method
strFileName = Right(m_RemoteEXE, Len(m_RemoteEXE) - 7)
Set objFSO = New FileSystemObject
Set objFile = objFSO.GetFile(strFilename) 'THIS LINE ERRORS
strRemoteVer = objFSO.GetFileVersion(strFilename)

I get an error 53, File Not Found :(
If I comment this line out, and just try to get the remote version, then this doesn't error, but it returns the version as "".
The value of strFilename is LocalHost/Woof.exe

Any ideas?

Woka


Win a prize for spotting the deliberate mistake :bigyello: :blush:
The problem is that I only tested it locally rather than on a server :blush:
I hard coded it to remove the "file://" part of the address in this line
strFileName = Right(m_RemoteEXE, Len(m_RemoteEXE) - 7)
Obviously this messes up the URL when the updated file is on a web server rather than the LAN.
The next problem comes with this line
Set fsoFile = FSO.GetFile(strFilename)
It appears that the FileSystemObject wont do http connections.
I think Ill have to add wininet.dll or WinSock and a couple of if statements to sort this out.

Wokawidget
Jan 7th, 2005, 04:00 AM
Hahaha I thought you were stripping off the "http://" part of the address :)

I have just written a DLL that does multiple updates, like Norton Live Update and Microsoft Windows Update.

It's still very rough, and needs cleaning up a little.

Damn, the code is on my home PC...Time to fone GF to email it to me :D Hahaha

Woka

Wokawidget
Jan 7th, 2005, 08:27 AM
OK Here is the code...

Like I said, bear with me, I am still working on it.

What you do to test is create a Virtual Dir in IIS, I dunno, call it Woof or something.
Then in the frmUpdate code you need:

mobjUpdate.RemotePath = "http://localhost/Woof/"


For the time being you must end this with a /

Then copy the files you want to download into that virtual dir.
Now create a txt file called Update.txt

This should be in the following format:
Filename;Version Number

So for the files in my example I would have:

Woof.exe;6
Fish.mp3;9
Badger.mp3;1

So, your files are now setup on the server.

What you do in frmUpdate is add the CURRENT files and versions by doing:

With mobjUpdate.Updates
.Clear
.Add "Woof.exe", 3
.Add "Fish.mp3", 4
.Add "Badger.mp3", 1
End With


Run the app.
What my code does is it can retrieve server info on the files, you can then pick and choose which updates you want to install. If the server version < current version, then you cannot pick that to update.
Once you have selected the updates you want click start download.
This downloads each file seperately giving you progress in the grid and a progress bar.

Like I said, this isn't finished yet. I have to add code to specify a dest folder as currently it just copies them to the temp drive.
But this is dead easy to change.

The code is all wrapped up in a simple DLL and can be added to any project that requires auto update or downloading capabilities.
The Download class can be used on it's own to download files.

Does this make sense?

Also, the code was put together quickly, a lot of refracturing required. Mainly with how events are handled, but it's not half bad already.

This code can be used to download random files, and/or setup applications.

Let me know what you think.

Regards,

Woka

Wokawidget
Jan 7th, 2005, 08:40 AM
The code can also be easily changed to accommadate version numbers like 1.3.56 or a, b or c. That's easy.
The code currently only downloads files that are out of date, but in the next few days I will add functionality whereas you MUST download a compulsary file, that may or may not be in the list (client side) of files you update...for example you may be searching for:

Woof.exe, 4
Moose.mp3, 2
Fish.mp3, 7

But the update file on the server will have an extra file in it, ie:

Woof.exe;5
Moose.mp3;2
Fish.mp3;9
NewFile.exe;REQUIRED

Then the auto updater will auto download this newfile.exe regardless.

Any other ideas for this?

Woka

john tindell
Jan 7th, 2005, 09:06 AM
Hey i was working on something like this but using web services, do you try an compress the files? Depending on what updates it can save a lot of time for people with dial-up. Just a thought

Wokawidget
Jan 7th, 2005, 09:20 AM
Nope, alas, the files arn't compressed.
Since you are using web services I am assuming you compress files at runtime with server side code before passing them back to the client, or are the files compressed before being placed on the server?

Woka

Wokawidget
Jan 7th, 2005, 09:24 AM
Also, my code will never be used by someone with dial up, so this isn't a problem since the files I am talking about arn't that big.

Woka

john tindell
Jan 7th, 2005, 10:26 AM
They are compressed at runtime, but as i was only trying it out, i just thought i would add compression for the fun of it.

Wokawidget
Jan 7th, 2005, 10:59 AM
Not a bad idea...but what would the performance be like if lots of people downloaded a 10Mb file at the same time. Your server would be number crunching like mad trying to compress the file at runtime...wouldn't it? Just a though, not sure as I have never tried it?

Woka

john tindell
Jan 7th, 2005, 11:16 AM
As I said I was only trying it out, but its a good idea. I was thinking about creating a program that uploaded the file to the remote server and it would compress and package them before they were avaliable to download, on the cleint side. Might have to dig up the project and try the package method.

Wokawidget
Jan 8th, 2005, 07:16 PM
Take a look at this:

http://www.vbforums.com/showthread.php?t=319226

Multi app/file auto updater.
Can be done automatic,or with wizard like in example.
Loads of features. New Product deployment. Mandatory updates...plus more.

Simple code and easy to change to accomodate more features and remote app properties.

Woka

DyCyn
Oct 14th, 2005, 10:22 PM
Win a prize for spotting the deliberate mistake :bigyello: :blush:
The problem is that I only tested it locally rather than on a server :blush:
I hard coded it to remove the "file://" part of the address in this line
strFileName = Right(m_RemoteEXE, Len(m_RemoteEXE) - 7)
Obviously this messes up the URL when the updated file is on a web server rather than the LAN.
The next problem comes with this line
Set fsoFile = FSO.GetFile(strFilename)
It appears that the FileSystemObject wont do http connections.
I think Ill have to add wininet.dll or WinSock and a couple of if statements to sort this out.Hi, have you managed to sort this out yet? Your control is exactly what I've been looking for! :thumb: