View Full Version : Example: Simple Updater
RizlaUK
07-01-2006, 04:53 AM
Hey guys, i was needing a updater for my app and i came up with this, its nothing super, infact most of it is copyed stright from the manual (with a few edits), it will check for a connection, if ok it will download a zip file and install the contents to a predefined folder (would be app install folder) i put it all togeather into 1 function (Update()) , like i said, nothing super but it might help someone out,
so here it is, my 1st example
esati
07-30-2006, 10:08 PM
i saw your project updater that is great
but can you tell me about this code
Folder.Create(_ProgramFilesFolder.."\\update_demo");
convert to HTML
qao
Intrigued
07-30-2006, 10:54 PM
This is from the AMS 6 help file:
Example 2
Folder.Create(_ProgramFilesFolder.."\\Flashy");
Creates a new folder called "Flashy" in the user's Program Files folder.
Note: _ProgramFilesFolder is a built-in variable that contains the path to the user's Program Files folder.
esati
07-30-2006, 11:04 PM
This is from the AMS 6 help file:
ok i understand you but can i use with html code
<html>
<script></script>
qao
Intrigued
07-30-2006, 11:16 PM
Do you want to create a folder using HTML code?
Intrigued
07-30-2006, 11:42 PM
Take a look at this simple project. I believe I have an example like it posted here or on amsuser.com. But, it takes the path as exampled above and puts such into a String which then is used to replace a placeholder in the HTML file (which is just six (6) '######' symbols).
So, the file is "read" into a String in AMS. The the String (which is all of the HTML code now) is searched for six (6) '######' symbols. When it finds (if) it then procedes to change that out for the _ProgramFilesFolder builtin variable and the folder path.
Try the project out and also check out the code in the On Show event area.
Notice how I have two HTML files? One is a template (holds the HTML code with the six (6) '######' symbols). And the other is where we 'paste in' the new searched string data. Or, the updated String information.
Best of luck and I hope this helps.
The file is over at amsuser.com, here:
http://www.amsuser.com/ams/examples/AMSVariableCodeToHTMLPage-AMS6-Intrigued.apz
esati
07-31-2006, 08:30 AM
the link you have specified has corrupted please uptade the link
csd214
07-31-2006, 08:54 AM
the link you have specified has corrupted please uptade the link
No, the link is nott corrupted. Please check your Internet settings.
esati
07-31-2006, 02:09 PM
when i download your link in my pc performance this message
http://img465.imageshack.us/img465/438/untitledzq3.jpg
Intrigued
07-31-2006, 04:28 PM
Try this:
Right-click on the link and choose Save Link As and choose where you want to save such.
rhosk
08-01-2006, 05:13 AM
Nope, fwiw, file doesn't work for me either.
Intrigued
08-01-2006, 08:55 AM
Each time I click on the link it works for me and others.
Check your I.E./Firefox settings and any Popup Stopper type programs settings, if you have such installed.
Hi Intrigued,
I get the same error when attempting to open/unzip the file - it downloads fine.
The file downloads with a zip extension - can you unzip it on your computer? Are you using winzip to zip it up?
Thanks!!!
Sue
Intrigued
08-01-2006, 09:15 AM
If that one does not work I did an update that also now is in the form of a custom Function:
http://www.indigorose.com/forums/showthread.php?t=16876
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.