Randem Systems Support Board

InnoScript => InnoScript - General Questions, Report Bugs, Problems etc... => Topic started by: jamj on October 31, 2008, 04:22:08 AM

Title: Updated to v9.2 build 15
Post by: jamj on October 31, 2008, 04:22:08 AM
Hi,
1. It is some months since I last used InnoScript. When started it updated to 9.2 build 15. After building script in this version the message box appears indicating number of files - but the descriptions of the files are missing (eg 'unsafe files' etc)
 
2. I am adding r/w files to project installation. Is it OK to just add folder containing these files, or do they need to be added individually? [I want to install a Files folder.]
 
3. There are now drop down lists (app, cf, cf32 etc). My help file is for older version and does not indicate what these are. I can figure some but not others.  Which should I sellect for the Files folder which has my data files when installing on Xp and Vista?  
 
4. Can IS be set to default install in the correct path in Vista? It seems to default to C:Progam Files.
 
Thanks again
 
James
Title: Updated to v9.2 build 15
Post by: Randem on October 31, 2008, 11:51:31 AM
Aloha James
 
1 - Yes this is covered in the instruction what to do in this case. There are a few different ways to accomplish this depending on why the files are missing. You can find the InnoScript help file under Help->Instructions
 
2 - It's ok to add the whole folder where the r/w files are located, just remember to tell innoscript where they should be installed IE. {applocaldata}
 
3 - All the parameters in the drop down list can be found in the Inno Setup help file under Constants You should select {applocaldata}
 
4 - Correct Path??? Program Files is the correct path. You can set the default path to anything you want but you eliminate all the protection the OS offers. So why would you want to do this?
Title: Updated to v9.2 build 15
Post by: jamj on November 03, 2008, 12:53:19 AM
Hi,
1. I'm not sure that I made clear the problem.
It is not in building the script, but after the script is build a message appears (as normal) indicating processing of different files. The wording in the message is not 'visible' as it was in older version.
 
2. Good - just as I thought.
 
3. I was looking in wrong place - subtle difference between Innoscript and Inno Setup!
 
4. I am confused with vista.
I understand that MyProgram should not go in Program files. Indeed I have found that installing MyProgram in Program Files with r/w files results in vista creating a virtual store 'copy' which really messes things up.
Installing in Users\MyProgram also gives problems in reading a database. Installing in Users\Username\MyProgram seems to work OK.  
It is my understanding that Users\Username\MyProgram is where I should install MyProgram to. Am I correct in this?
That is what I meant by the 'correct path'.
 
Thanks
 
(Message edited by jamj on November 02, 2008)
Title: Updated to v9.2 build 15
Post by: Randem on November 03, 2008, 07:03:01 PM
Aloha James,
 
1 - Look at the log files, that is where this type of information is now.
 
4 - Yes it can be set to install where ever you want. If you really want to use the USERS folder you should include the LEGACY template in InnoScript, it will handle what you want. The Users folder is a last ditch effort for legacy applications that cannot be changed. Since you are in control of your app you should use the Program Files folder for your app and the APPDATAFOLDER for your data. Please read https://randemsystems.support/innoscript-general-questions-report-bugs-problems-etc/making-your-application-vista-windows-7-windows-8-compliant/ (https://randemsystems.support/innoscript-general-questions-report-bugs-problems-etc/making-your-application-vista-windows-7-windows-8-compliant/) for more information and help on this.
Title: Updated to v9.2 build 15
Post by: jamj on November 11, 2008, 11:51:06 AM
Hi,
It's been a week since I had chance to look at this again.
I have read your 'vistainstalls'.
Am I correct in thinking that when installing to Vista I can install to Program Files and have a subfolder which contains all my r/w files?
 
ie. ..Program FilesMy FolderMy Files, where My Folder contains exe and My Files contains database and other r/w files.
 
If this is correct understanding of your 'vistainstalls' then I have another problem.
My program has an activation file which is activated when program is paid for, and I dont really want this in with the other r/w files. I would like to hide it in some other folder, but where? I am not competent to write to registry.
 
Thanks again for help
James
Title: Updated to v9.2 build 15
Post by: Randem on November 11, 2008, 12:07:35 PM
ie. ..\Program Files\My Folder\My Files, where My Folder contains exe and My Files contains database and other r/w files.
 
No, you CANNOT have any r/w files in the Program Files folder anywhere if you plan on using them to be written to, sub folder or not. You need to use the USERAPPDATA folder as noted.
 
What is stated in the vistainstalls web page you place the database and support files in the Program Files folder at install time then at program startup time you copy these r/w files to the USERAPPDATA where they can be used as r/w by the application.
 
For registration, you need to use the registry or a file in the r/w folder or somewhere else on the computer for this information. In either case you need to encrypt the data stored for safer storage.
Title: Updated to v9.2 build 15
Post by: jamj on November 12, 2008, 12:26:01 AM
Ah....
I was getting conflicting ideas.
What confused me was the installing to Program Files...
I had not followed the point about then moving them.
 
This is now clear.
 
Thank you again.
James
 
(Message edited by jamj on November 11, 2008)
Title: Updated to v9.2 build 15
Post by: Randem on November 12, 2008, 01:37:46 PM
Good, Now if these database and other files are to be used by all users on the computer you probably want to copy the files to the COMMONAPPDATA folder so the everyone has access to the same database. If you use the USERAPPDATA folder then each user will have a copy of their own database and files not sharing data with each other.
Title: Updated to v9.2 build 15
Post by: jamj on November 13, 2008, 10:40:19 AM
Yes, the COMMONAPPDATA folder would be the one I want.
Thank you for that help. Its little things that often give the most grief
Title: Updated to v9.2 build 15
Post by: Randem on November 13, 2008, 11:24:58 AM
Great, remember you HAVE to create a folder in the COMMONAPPDATA for your data.
Title: Updated to v9.2 build 15
Post by: jamj on November 17, 2008, 12:23:19 PM
Sorry to trouble you again, but..
1. I sometimes want to read a database that is on another computer (server) - what folder should this be in and how do I read path to it. Currently I have path stored in r/w file on local computer. Is this still best way.
 
2. I have been trying to incorporate your SpecialFolders code to move and get path to folders. Please excuse my lack of knowledge, but I can't get this to work. I have tried placing all modules etc into own program and putting  
 
    Set SpecialFolders = New clsSpecialFolders
 
    With SpecialFolders
     
        .ApplicationDataFolderLocal = FixPath(fGetSpecialFolderLocation(CSIDL_LOCAL_APPDATA)) & App.CompanyName &  & App.EXEName &  
    End With
into form load of own program. This gets .ApplicationDataFolderLocal but does nothing else. Obviously I am skipping part of code but what am I doing wrong?
Modules are quite new to me!
James
Title: Updated to v9.2 build 15
Post by: Randem on November 17, 2008, 05:17:33 PM
No bother at all. This is what the forum is for.
 
1 - You can place the database in any folder that you create on the server. Having the path stored on the local computer is fine.
 
2 - I can't tell what yo are doing wrong without seeing the code you are using. You can attach the project and I can take a look at it.
Title: Updated to v9.2 build 15
Post by: jamj on November 21, 2008, 11:49:12 AM
Have been busy at other matters, so only getting back to this.
I have looked further at your 'special folders' code and think that a little more work will enable me to understand it enough to use this.
However I noticed a bug in modStartup: Main -  
FileCopy FixPath(App.Path) & Database\
should read  
FileCopy FixPath(App.Path) & Databases\
to correspond to previous line
sStr = SpecialFolders.ApplicationDataFolderLocal & Databases\
Regards
James
Title: Updated to v9.2 build 15
Post by: Randem on November 21, 2008, 04:58:22 PM
Yes, that was a typo.
 
Thanks, it has been corrected.
Title: Updated to v9.2 build 15
Post by: jamj on November 25, 2008, 11:55:20 AM
Hi again,
I have added the Special Folders code to my project, and made the modStartUp the start up form of project. At the bottom of modStartUp Main I changed Form1.show to my own frmServerPath.Show. This frmServerPath is not displayed on screen, but after checks is unloaded and it directs to frmMain.show. When frmMain is loaded I get error from the modStartup on the line where code is 'frmServerPath.Show' indicating that this form has been unloaded.
I could write error code to handle this but I would rather not have the error in the first place! What have I done wrong?
Should start up form be something other than module, and if so how do I call module?
Title: Updated to v9.2 build 15
Post by: Randem on November 25, 2008, 12:31:56 PM
The design is that control at application termination returns to modStartUp. So, either you have your main form load then load the undisplayed form from the main form so that control is not relinquished.