View Full Version : Validating MT plan on Vista
NewsArchive
05-26-2008, 01:41 AM
Hi Friedrich,
One more question on the MT plan.
The installers I use are set to requireAdmin. My program is
manifested asInvoker.
I write the MP key to HKCU when my customer enters it into the
program.
How do I read it from the elevated installer so I can validate it?
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-26-2008, 01:42 AM
Arnor,
My Installer is elevated and so is my app
The installer writes the mp and date to HKCU
The app reads it perfectly
The updater being also elevated reads it also perfectly
all elevated read same place
All should be fine for you except that the app cannot read it if asInvoker
so the best is to 'copy' within Installer to an ini.....in data path that
the exe can read
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-26-2008, 01:43 AM
Hi Arnór,
> One more question on the MT plan.
>
> The installers I use are set to requireAdmin. My program is
> manifested asInvoker.
>
> I write the MP key to HKCU when my customer enters it into the
> program.
>
> How do I read it from the elevated installer so I can validate it?
Well, let us assume, you start your "asInvoker" application elevated (Run as
administrator). How do you read the registry value from your elevated
application to validate the subscription <g> If you have a "Standard user"
account then you can't read the correct HKCU value from an elevated
application.
Friedrich
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
NewsArchive
05-27-2008, 01:18 AM
Hi Friedrich,
>Well, let us assume, you start your "asInvoker" application elevated (Run as
>administrator). How do you read the registry value from your elevated
>application to validate the subscription <g> If you have a "Standard user"
>account then you can't read the correct HKCU value from an elevated
>application.
"How do I read it from the elevated installer so I can validate it?"
I'm looking for recommendations on ___how___ to actually do this. In
previous communication you suggested writing the MP to a registry
key??? Seems that that recommendation cannot work under Vista. I
feel like I'm on a wild goose chase where the target moves every time
I ask:(
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 01:18 AM
> "How do I read it from the elevated installer so I can validate it?"
>
> I'm looking for recommendations on ___how___ to actually do this. In
> previous communication you suggested writing the MP to a registry
> key??? Seems that that recommendation cannot work under Vista. I
> feel like I'm on a wild goose chase where the target moves every time
> I ask:(
Yes, writing the MP from the installer to the HKLM registry is no problem.
You can read that value from an elevated and unelevated application.
Did you tell us that you would like to update the maintenance key from your
own unelevated application?
Regards,
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
NewsArchive
05-27-2008, 01:19 AM
This is what I answered to one of your questions on April 05, 2008 (what we
are doing in SetupBuilder).
---
BTW, what we do in our own SetupBuilder IDE is the following. The IDE opens
a Clarion dialog box where the customer can paste the maintenance plan.
After the verification process, the maintenance key is written to registry.
IMPORTANT: if the IDE is running elevated, it is written to a
HKEY_LOCAL_MACHINE key. If it is running unelevated, it is written to a
CURRENT_USER registry key. The web update installer package can handle this
scenario. It checks the HKEY_LOCAL_MACHINE key first to verify the
subscription. If it is valid, it continues with the installation. If it is
invalid, it checks the CURRENT_USER key. If this retrieved value is valid,
it continues - otherwise, the installation is aborted.
Of course, you can do whatever you want with the subscription key. Write it
to the registry, to an INI or ASCII text file, write it to a TPS, SQL, or
whatever database file.
---
Or are you referring to another "recommendation"?
Regards,
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
NewsArchive
05-27-2008, 01:19 AM
Hi Friedrich,
>Did you tell us that you would like to update the maintenance key from your
>own unelevated application?
"The installers I use are set to requireAdmin. My program is
manifested asInvoker.
I write the MP key to HKCU when my customer enters it into the
program.
How do I read it from the elevated installer so I can validate it?"
Yes, I'm writing the MP key to the HKCU when the customer enters it in
to MY program.
From a thread last month:
Newsgroups: softvelocity.clarion.addons.setupbuilder
Subject: Re: Subscription keys
Date: 5 Apr 2008 14:02:00 -0500
"BTW, what we do in our own SetupBuilder IDE is the following. The
IDE opens a Clarion dialog box where the customer can paste the
maintenance plan. After the verification process, the maintenance key
is written to registry. IMPORTANT: if the IDE is running elevated, it
is written to a HKEY_LOCAL_MACHINE key. If it is running unelevated,
it is written to a CURRENT_USER registry key. The web update
installer package can handle this scenario. It checks the
HKEY_LOCAL_MACHINE key first to verify the subscription. If it is
valid, it continues with the installation. If it is
invalid, it checks the CURRENT_USER key. If this retrieved value is
valid, it continues - otherwise, the installation is aborted."
Does this apply to BOTH normal install and the Web update or just the
web update and does this scenario work under Vista WS2008?
As far as I can tell the WebUpdate must run elevated. My app does not
run elevated. Can the WebUpdate still read the HKCU keys under
Vista/WS2008? Can the normal install still read the HKCU keys under
Vista/WS2008? I was under the impression that an elevated program is
running under the admin account, not the user account and has a
different HKCU key and would therefor not find it.
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 01:20 AM
>>Did you tell us that you would like to update the maintenance key from
>>your
>>own unelevated application?
>
> "The installers I use are set to requireAdmin. My program is
> manifested asInvoker.
>
> I write the MP key to HKCU when my customer enters it into the
> program.
>
> How do I read it from the elevated installer so I can validate it?"
Yes, the above information is in your *new* message.
You made the following kind statement:
> I feel like I'm on a wild goose chase where the target moves every time I
> ask:(
What I mean is, did you tell it in your *previous* communication where I
suggested writing the MP to a registry?
Please note that I said (I think you are refering to this previous
communication)
> Of course, you can do whatever you want with the subscription key. Write
> it to the registry, to an INI or ASCII text file, write it to a TPS, SQL,
> or whatever database file.
> From a thread last month:
>
> Newsgroups: softvelocity.clarion.addons.setupbuilder
> Subject: Re: Subscription keys
> Date: 5 Apr 2008 14:02:00 -0500
>
>
> "BTW, what we do in our own SetupBuilder IDE is the following. The
> IDE opens a Clarion dialog box where the customer can paste the
> maintenance plan. After the verification process, the maintenance key
> is written to registry. IMPORTANT: if the IDE is running elevated, it
> is written to a HKEY_LOCAL_MACHINE key. If it is running unelevated,
> it is written to a CURRENT_USER registry key. The web update
> installer package can handle this scenario. It checks the
> HKEY_LOCAL_MACHINE key first to verify the subscription. If it is
> valid, it continues with the installation. If it is
> invalid, it checks the CURRENT_USER key. If this retrieved value is
> valid, it continues - otherwise, the installation is aborted."
>
> Does this apply to BOTH normal install and the Web update or just the
> web update and does this scenario work under Vista WS2008?
Yes, the above is completely correct. And yes, this scenario works for web
update, full install, and maintenance plan verification when running
elevated or unelevated. The SetupBuilder IDE (asInvoker) does this on all
Windows versions (including Vista and 2008).
Regards,
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
NewsArchive
05-27-2008, 01:22 AM
Hi Friedrich,
>Yes, the above is completely correct. And yes, this scenario works for web
>update, full install, and maintenance plan verification when running
>elevated or unelevated. The SetupBuilder IDE (asInvoker) does this on all
>Windows versions (including Vista and 2008).
So the elevated installer CAN read from the user registry key?
This is really confusing<g> I had the firm believe after reading what
you have written over the years on Vista/WS2008 that an elevated
program (installer for example) could NOT reliably read/write HKCU
because when elevated it's supposed to be running under the admin
account.
I could put this in a file somewhere, but dealing with Vista/WS2008 it
seems that every folder I come up with for my program to write to
won't work for the installer or the other way around<g>
Sorry if I sound frustrated, I need a break;)
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 01:22 AM
Hi Arnór,
>>Yes, the above is completely correct. And yes, this scenario works for
>>web
>>update, full install, and maintenance plan verification when running
>>elevated or unelevated. The SetupBuilder IDE (asInvoker) does this on all
>>Windows versions (including Vista and 2008).
>
> So the elevated installer CAN read from the user registry key?
Yes, you CAN read from the HKCU registry key from an elevated application,
but there is a huge difference between the Administrator and Standard user
account. If you provide a "real" mixed-mode application (that works from
the Admin and Standard user account) then you have to take care of this
difference.
Let us assume, you are logged-in to the Administrator account and running an
application elevated. Your elevated application can write and read to/from
the HKCU key. The same application running unelevated will read/write the
same registry key. No problem.
-BUT- (there is always a -BUT-)
You are logged in as Standard User now and running the application elevated.
Please note that you have your own privat profile now. If you run the
application elevated and you read/write the HKCU key, then you read/write
the values from the Administrator account!!! Not from your Standard User
account!!! Completely different "locations". And if your application is
running unelevated and tries to read HKCU information from a key written by
an elevated application then you are accessing again completely different
locations.
> This is really confusing<g> I had the firm believe after reading what
> you have written over the years on Vista/WS2008 that an elevated
> program (installer for example) could NOT reliably read/write HKCU
> because when elevated it's supposed to be running under the admin
> account.
Well, and that is correct. That's why I wrote in our previous
communication:
---
> IMPORTANT: if the IDE is running elevated, it is written to a
> HKEY_LOCAL_MACHINE key. If it is running unelevated, it is
> written to a CURRENT_USER registry key.
---
> I could put this in a file somewhere, but dealing with Vista/WS2008 it
> seems that every folder I come up with for my program to write to
> won't work for the installer or the other way around<g>
>
> Sorry if I sound frustrated, I need a break;)
In fact, there is no difference between the installer and your application.
Why? Because if your user runs your application "as administrator" then it
is also running elevated and your own program gets access to the information
located in the Admin profile.
Do you see what I mean?
Friedrich
NewsArchive
05-27-2008, 01:23 AM
Conclusion ?
Hit the safety rail on lap 5 and win a new copy of XP ..... <BG>
Friedrich, you were saying my problems with Microsoft certification gave you
nigthmares , what about this for others ? :)
JP
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-27-2008, 01:23 AM
> Conclusion ?
>
> Hit the safety rail on lap 5 and win a new copy of XP ..... <BG>
>
> Friedrich, you were saying my problems with Microsoft certification gave
> you nigthmares , what about this for others ? :)
<BG>
What we do is, we handle both HKEY_LOCAL_MACHINE and CURRENT_USER keys.
The installer (running elevated) writes the maintenance key to
HKEY_LOCAL_MACHINE.
If the application (running elevated or unelevated, you never know) updates
the maintenance key, it writes the new MP to HKEY_LOCAL_MACHINE or
CURRENT_USER (if the app can't write to the first, it writes to the latter).
All applications (running elevated or unelevated) doing maintenance key
verification read the HKEY_LOCAL_MACHINE key first to verify the
subscription. If it is valid, okay. If it is invalid, it checks the
CURRENT_USER key. If both are invalid, the maintenance is expired/invalid.
That's it <g>
Friedrich
NewsArchive
05-27-2008, 01:24 AM
Hi Friedrich,
>You are logged in as Standard User now and running the application elevated.
>Please note that you have your own privat profile now. If you run the
>application elevated and you read/write the HKCU key, then you read/write
>the values from the Administrator account!!! Not from your Standard User
>account!!! Completely different "locations". And if your application is
>running unelevated and tries to read HKCU information from a key written by
>an elevated application then you are accessing again completely different
>locations.
This is _exactly_ why I'm asking about this. I'm running the
application _non elevated_ under a _standard account_ and the app is
_not_ running "As Administrator" I think this is the scenaro that
most apps would normally run under.
You said: "If you provide a "real" mixed-mode application (that works
from the Admin and Standard user account) then you have to take care
of this difference."
Again, that is exactly the situation I'm talking about and I need help
with how to "take care of this difference" :) I don't want to run my
app elevated. I don't want users to have to run it "As Administrator"
I don't know if the user is using an admin or standard account and
practically don't care. I don't use any keys or folders that might
require elevation under Vista and the program is well behaved under a
standard account.
The user enters the MP in my program and I write it to HKCU as I've
said before. He clicks the "Check for updates" That runs the
webupdate elevated (under Vista/WS2008). Now what?
So, _how_ can this be solved, realistically, for this situation? Or
will the SB installer (set to requireAdmin) handle it automatically
for a non elevated, non-admin account and this is thereby a complete
non-issue?
I could put this into a file, but again, under Vista/WS2008 what would
be appropriate location where both non elevated, standard user and
elevated admin or elevated standard could read and write to it? Are
we having fun yet?<bg>
I think you need to address this issue in the documentation about the
MP subscriptions. I'm sure that a lot of users will be running into
how exactly to implement this under Vista/WS2008. I think my scenario
is basically a very text book Vista aware install.
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 01:24 AM
Arnor,
Why do you want the user to enter the MP from your app instead of leaving
all that to SB to handle ?
In DMC the user sees what I show him : The MP code and expiry date point
When he updates or installs he can then and ONLY there enter the new MP if
he has one : in installer and in updater I check the MP and if not good then
I open a dialog for the user to change it
Again checked by SB and if not valid that's the end of the road otherwise it
is stored and the expiry date written to registry were I read it from DMC
OK, DMC runs elevated because of other problems, but in your case add a
single line in SB to write to an ini file or if you prefer write a dll to
add to a tps or an sql backend or whatever you want.....
Under Vista any data dir can receive an ini file
And that is the end of your problem ....
Let the specialist handle the dirty work and simply read the ini file
created by your installer updater and display
Now IF you really insist on having your app enter the MP store that in an
ini file again and get SB to read it from there and then check it.....
SB is so powerfull you can do whatever you want with it : even hit a safety
rail on lap 5 at 230 kmh and still win the 1st price :) of all installers!
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-27-2008, 01:25 AM
Hi Jean-Pierre,
>Why do you want the user to enter the MP from your app instead of leaving
>all that to SB to handle ?
Because entering the MP is not associated with any SB action in the
software and doesn't need to be and shouldn't be.
Consider this:
A customer buys a product. He gets a 2 month MP and receives the
keycode and the MP code in an email from me. He already has the
software installed so all he needs now is the key and the MP. No SB
interaction needed.
This is how SB does it, and according to what Friedrich has said, this
is all done inside SB. When you go to "Help | Maintenance Plan" in
SB, you are not running the SB install to enter it - it's part of the
software. Why should I not be able to do the same? I simply want to
learn how to do it:)
The issue is simply how and where to store the MP key from my software
so that the installer or webupdater can 100% reliably find it, read it
and verify it.
Hmm... Need to check something...
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 01:26 AM
Hi Jean-Pierre,
>Hmm... Need to check something...
Nope. Am I being stubborn on this or what?<g> Oh, yeah, you bet! I
do have some French blood in me several generations back and I think
it's really showing through on this one<bg>
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 01:26 AM
Arnor,
Your client will NOT need MP till he updates ?
So let him enter it then only
Afraid he will loose it ?
Send it in an XML along with the licence like I do and register both same
time toether like I do
Store in reg if app runs elevated or store in ANY ini file anywhere you want
in ANY data path accessible under Vista o even the mice eating the electric
wires....why ? because no one wants to use a Vista machine <VBG>
Simply in your installer or and Updater add a line to read that ini file and
check validity.....simple easy and quick
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-27-2008, 01:27 AM
Hi Jean-Pierre,
>Store in reg if app runs elevated or store in ANY ini file anywhere you want
>in ANY data path accessible under Vista
I've said this about 20 times here already, the app is NOT elevated
and it's not going to be elevated<vbg> That DOES put limitations on
where you can place datafiles where they are readily accessible from a
non-elevated app and the elevated installer. I can't write to Program
Files. Could you please tell me what (CSIDL) folder I can write to
from a non-elevated program that the elevated program (installer) can
see?
I can't write to any of the common folders. I can write to the local
folders, but then the installer won't know where they are. I don't
remember any folder that I could use where both sides are able to
read/write to it with the limitations that I know are applied to
non-elevated programs.
I use Vista and I test under Vista using standard user account and
non-elevated programs and I know some of the limitations.
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 03:18 AM
Hi Arnór,
> I've said this about 20 times here already, the app is NOT elevated
> and it's not going to be elevated<vbg> That DOES put limitations on
> where you can place datafiles where they are readily accessible from a
> non-elevated app and the elevated installer. I can't write to Program
> Files. Could you please tell me what (CSIDL) folder I can write to
> from a non-elevated program that the elevated program (installer) can
> see?
I have developed a demo for you. Please download the following file:
http://www.lindersoft.com/projects/vistademo.zip
It includes three SetupBuilder source code scripts:
1. InstallMP_Elevated.sb6 (INSTALL ELEVATED)
Please compile this script and run it from a Standard user account under
Vista. It will create a \Icetips\Demo folder under CSIDL_COMMON_DOCUMENTS
and then write a test MP.INI file that includes a dummy maintenance plan
value.
[Test]
MP=0000000000
The "InstallMP_Elevated.exe" file is an equivalent to your standard
installation application. It runs elevated.
2. ModifyMP_Unelevated.sb6 (READ/WRITE UNELEVATED)
Please compile this script and run it from a Standard user account under
Vista. This is an "asInvoker" application! It reads the maintenance plan
value (previously installed by an elevated application) and displays the
value. In this case, 0000000000. Then it writes a new maintenance plan
value, in this case 1111111111.
The "ModifyMP_Unelevated.exe" is an equivalent to your own "asInvoker"
application. It runs unelevated.
3. ModifyMP_Elevated.sb6 (READ/WRITE ELEVATED)
Please compile this script and run it under a Standard user account under
Vista. This is a "requireAdministrator" application! It reads the
maintenance plan value (previously modified by an unelevated application)
and displays the value. In this case, 1111111111. Then it writes a new
maintenance plan value, in this case 2222222222.
The "ModifyMP_Elevated.exe" is an equivalent to your own application running
elevated.
All accounts (Administrator/Standard user) can read/write the same data from
an application running elevated/nonelevated.
4. Uninstall InstallMP_Elevated
Does this help? What do you think?
Friedrich
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
NewsArchive
05-27-2008, 08:26 AM
When do you come here to write some code for me please ? <VBG>
If THIS is not service then what is ?
Bravo again
JP
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-27-2008, 08:26 AM
>
> When do you come here to write some code for me please ? <VBG>
>
<VBG> :)
Friedrich
NewsArchive
05-27-2008, 08:27 AM
BTW dead link ....
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-27-2008, 08:27 AM
>
> BTW dead link ....
>
Works okay here. And already 28 downloads <g>.
Friedrich
NewsArchive
05-27-2008, 08:27 AM
Hi Friedrich,
>I have developed a demo for you. Please download the following file:
>
>http://www.lindersoft.com/projects/vistademo.zip
Thank you VERY MUCH:)
>2. ModifyMP_Unelevated.sb6 (READ/WRITE UNELEVATED)
>
>Please compile this script and run it from a Standard user account under
>Vista. This is an "asInvoker" application! It reads the maintenance plan
>value (previously installed by an elevated application) and displays the
>value. In this case, 0000000000. Then it writes a new maintenance plan
>value, in this case 1111111111.
>
>The "ModifyMP_Unelevated.exe" is an equivalent to your own "asInvoker"
>application. It runs unelevated.
That's all I need to do:)
I guess there is no way to do this using the registry? But I can deal
with the ini as long as I can read and write to it from both elevated
and non-elevated, admin and standard accounts:)
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-27-2008, 08:27 AM
Hi Arnór,
>
> Thank you VERY MUCH:)
>
You are very welcome :)
> That's all I need to do:)
>
> I guess there is no way to do this using the registry? But I can deal
> with the ini as long as I can read and write to it from both elevated
> and non-elevated, admin and standard accounts:)
No, this is the only possible way I see. But it's not the worst solution.
The advantage is that an uninstall really removes everything now. If you
are using an "unelevated" application to write information to the HKCU then
there is no way to remove that (registry) information during the product
uninstall process.
We'll use the same method to handle subscription storage in the SetupBuilder
7 IDE ;-)
Friedrich
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
NewsArchive
05-28-2008, 01:55 AM
>>
>> BTW dead link ....
>>
>
> Works okay here. And already 28 downloads <g>.
Friedrich,
OK, you wrote this for Arnor, and so he had to download it 28 times?! :-D
Reminds of this quote in My Blue Heaven starring Steve Martin (Vincent
'Vinnie' Antonelli)
http://www.imdb.com/title/tt0100212/
Hannah Stubbs (assistant district attorney): The books...
Vincent 'Vinnie' Antonelli: You have something against books?
Hannah Stubbs: I have nothing about books! I am curious about the books in
your trunk.
Vincent 'Vinnie' Antonelli: You see, I was thinking of writing my story, so
I bought this one on how to do it.
Hannah Stubbs: Why do you need 25 copies of it?
Vincent 'Vinnie' Antonelli: In case I want to read it more than once...
:-D
David
--
From David Troxell - Product Scope 7 - Encourager Software
Clarion Third Party Profile Exchange Online
http://encouragersoftware.com/profile/clarlinks.html
http://www.encouragersoftware.com/
http://www.profileexchanges.com/blog/
NewsArchive
05-28-2008, 01:57 AM
Hi David,
> OK, you wrote this for Arnor, and so he had to download it 28 times?! :-D
>
> Reminds of this quote in My Blue Heaven starring Steve Martin (Vincent
> 'Vinnie' Antonelli)
>
> http://www.imdb.com/title/tt0100212/
>
> Hannah Stubbs (assistant district attorney): The books...
> Vincent 'Vinnie' Antonelli: You have something against books?
> Hannah Stubbs: I have nothing about books! I am curious about the books in
> your trunk.
> Vincent 'Vinnie' Antonelli: You see, I was thinking of writing my story,
> so
> I bought this one on how to do it.
> Hannah Stubbs: Why do you need 25 copies of it?
> Vincent 'Vinnie' Antonelli: In case I want to read it more than once...
<BG> ;-)
Friedrich
NewsArchive
05-28-2008, 01:59 AM
Hi Friedrich,
>No, this is the only possible way I see. But it's not the worst solution.
>The advantage is that an uninstall really removes everything now. If you
>are using an "unelevated" application to write information to the HKCU then
>there is no way to remove that (registry) information during the product
>uninstall process.
Hmm... Hadn't thought of that. I use the HKCU quite a bit in the
Build Automator.
Ok, don't get too comfortable, here's another scenario for you<g>:
3 users share the same PC. User A has a Build Automator license with
MP valid until June 1, 2009. User B has Build Automator license with
MP valid until Dec 1, 2009. User C has Build Automator license
without MP.
Now what?<g> How can that kind of scenario be handled?
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-28-2008, 02:00 AM
Easy : sell the 2 computers :)
--
Thank you
Cordialement - Best regards
Jean-Pierre GUTSATZ
CGF
Data Management Center - A tool to let you Migrate Import Export Transfer
all your Data very easily
www.dmc-fr.com
Certified by Microsoft : "Works with Vista" & "Works with Windows Server
2008"
NewsArchive
05-28-2008, 02:01 AM
> Ok, don't get too comfortable, here's another scenario for you<g>:
>
> 3 users share the same PC. User A has a Build Automator license with
> MP valid until June 1, 2009. User B has Build Automator license with
> MP valid until Dec 1, 2009. User C has Build Automator license
> without MP.
>
> Now what?<g> How can that kind of scenario be handled?
All with the same serial number <g>. Can you do the following:
CSIDL_COMMON_DOCUMENTS\Icetips\Demo\<SerialNumber>
Friedrich
NewsArchive
05-28-2008, 02:02 AM
Hi Friedrich,
>All with the same serial number <g>. Can you do the following:
>
>CSIDL_COMMON_DOCUMENTS\Icetips\Demo\<SerialNumber>
I'm using Armadillo so I'd then have to make the SB install somehow
aware of the keycode so it could read the mp and verify - and I'd be
back on square one<g>
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-28-2008, 02:05 AM
Hi Friedrich,
>2. ModifyMP_Unelevated.sb6 (READ/WRITE UNELEVATED)
>
>Please compile this script and run it from a Standard user account under
>Vista. This is an "asInvoker" application! It reads the maintenance plan
>value (previously installed by an elevated application) and displays the
>value. In this case, 0000000000. Then it writes a new maintenance plan
>value, in this case 1111111111.
>
>The "ModifyMP_Unelevated.exe" is an equivalent to your own "asInvoker"
>application. It runs unelevated.
Since this was the scenarion that I really needed to test I copied
this over to my vista machine, started it with my "Regular User"
account and started testing. What I found was that the non-elevated
script would NOT create the folder. I modified it so that if the INI
was not found it would attempt to write it. It failed and the folder
- "CSIDL_COMMON_DOCUMENTS\Icetips\Demo" was not created. So I tried
the elevated install and it created the folder and created the ini and
then the unelevated would work.
Then I tried a very small clarion project where I started by creating
the folder and then used PutIni. That worked without any issues. So
it seems that whatever you are using to create the folder fails when
non-elevated. I use SHCreateDirectoryEX to create the folder
structure and this is the code I used:
Program
Map
End
Include('ITUtilityClass.inc'),ONCE
ITS ITShellClass
INI CString(2049)
Code
INI = ITS.GetSpecialFolder(IT_CSIDL_COMMON_DOCUMENTS) & '\Icetips\Test'
ITS.CreateDirectory(INI)
INI = INI & '\MyINI.INI'
PutIni('Test','Test','Test',INI)
This worked flawlessly when nonelevated and created the folder and
updated the INI file:)
Problem solved:)
I think it would be a good idea for you to update the Setup Builder
documentation with guidelines on how to do this under Vista/WS2008
when the developer wants to be in charge of updating the MP.
Best regards,
Arnór Baldvinsson
Icetips Creative, Inc.
San Antonio, Texas, USA
www.icetips.com
Subscribe to information from Icetips.com:
http://www.icetips.com/subscribe.php
NewsArchive
05-28-2008, 02:06 AM
Hi Arnór,
>>The "ModifyMP_Unelevated.exe" is an equivalent to your own "asInvoker"
>>application. It runs unelevated.
>
> Since this was the scenarion that I really needed to test I copied
> this over to my vista machine, started it with my "Regular User"
> account and started testing. What I found was that the non-elevated
> script would NOT create the folder. I modified it so that if the INI
> was not found it would attempt to write it. It failed and the folder
> - "CSIDL_COMMON_DOCUMENTS\Icetips\Demo" was not created. So I tried
> the elevated install and it created the folder and created the ini and
> then the unelevated would work.
Yes, this is intentional because the "ModifyMP_Unelevated.sb6" test project
does not have any "Create Folder" function. In real life, you run the
installer first and then start your application <g>.
Add the "Create Folder" function and you should be done. The same is true
for the "ModifyMP_Elevated.sb6" project (it will also not create
CSIDL_COMMON_DOCUMENTS\Icetips\Demo).
Does this work?
> I think it would be a good idea for you to update the Setup Builder
> documentation with guidelines on how to do this under Vista/WS2008
> when the developer wants to be in charge of updating the MP.
Not sure if this would be a good idea. Perhaps Jane or Charles will release
a "Vista for ******** Developers" in the future.
When I suggest something (in written form) and it does not work in a
specific case and specific scenario then users can always say "But
Friedrich, you write on page X that...". There are so many things that can
go wrong under Vista...
That's why we have the following in the SetupBuilder documentation:
"The SetupBuilder documentation assumes that you are proficient in the use
of the Windows operating system. If you need help using the Windows
operating system, please consult its user documentation."
The developer should decide where to store the data (even Microsoft does not
tell you where to store it under Vista/2008 <g>).
Friedrich
--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910
"point. click. ship" - that's SetupBuilder
Create Windows Vista ready installations in minutes
-- Official Comodo Code Signing and SSL Certificate Partner
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.