PDA

View Full Version : Dummies for setup builder



NewsArchive
04-18-2011, 12:48 AM
Hi all

First time i'm using setupbuilder 7. I was using the baics of setupbuilder
3.5 but now i have upgraded. I am really impressed.

Is there any examples or how to:

Create a pane where the user can update SQL parameters during install

and

A pane where the user gets promped if this is the server ? If it is the
server then some of the registry data must change.

So if there is some script examples it woud be much appreciated


Regards


Andreas

NewsArchive
04-18-2011, 12:49 AM
Hi Andreas,

Thank you for your kind words!

I would suggest download the "Examples Package" and the excellent "Learning
SetupBuilder Part I" (see attached screenshot).

http://www.setupbuilder.com/downloads_licensed.htm

Does this help?

Friedrich

NewsArchive
04-18-2011, 12:51 AM
Hi Friedrich

Thanks I found the examples. Now you can see the power of the scripting.

Im like a kid with a new toy - just want to use it and just reference the
instructions and examples :)

Just one place i am stuck.

I created a runtime variable %SET_CENTRALDATA%

Then in the scipt editor under [ modify System]

I do a get Registry Key value (current user)
Then I have an edit dialog where i edit the variable.
I made another edit dialog after that to see if the varible had change - and
it was.
I then have a Edit Registry dialog to update the key. (attached file)

But it does not change the value. So i must be missing something.

Just for a test I changed the Key value name and it did add a new key value
but not with the edited value.


Any ideas

Thank you

Andreas Garvs

NewsArchive
04-18-2011, 06:43 AM
Hi Andreas,

Perhaps you are looking under the wrong key? Is "\cimos\cimos" the correct
key here?

BTW, please note that you should never write to "per-user" data locations
(e.g. HKEY_CURRENT_USER) from your installer!

Friedrich

NewsArchive
04-18-2011, 06:44 AM
I think the following is an interesting reading:

http://www.lindersoft.com/forums/showthread.php?t=20795

Friedrich

NewsArchive
04-18-2011, 06:44 AM
Thanks Friedrich

Makes a lot of sence - The grey matter a bit slow.

is there an artice / example to see if a specfic version of SQL is installed
on the mashine ?


Regards

Andreas

NewsArchive
04-18-2011, 06:44 AM
Hi Andreas,

> Makes a lot of sence - The grey matter a bit slow.
>
> is there an artice / example to see if a specfic version of SQL is
> installed on the mashine ?

What you can do is to retrieve the information from the Windows registry and
enumerate the "instances".

For example:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names

MSDN and MSSQL Forums have quite a few very interesting articles available.

Friedrich

NewsArchive
04-18-2011, 06:45 AM
Hi Friedrich

It is in the right key because i could see it add a new key value.
It writes the origional data from the get registry not the edited data.

So under best practices where would i write the key values to ? instead of
current user.

I have attached the project i was playing with. Maybe that might help

Thanks

Andreas

NewsArchive
04-18-2011, 06:46 AM
Hi Andreas,

> It is in the right key because i could see it add a new key value.
> It writes the origional data from the get registry not the edited data.
>
> So under best practices where would i write the key values to ? instead of
> current user.
>
> I have attached the project i was playing with. Maybe that might help

See attached screenshot. This is incorrect. You do NOT display the dialogs
to ask for the information before you write the key values ;-)

Does this help?

Friedrich

NewsArchive
04-18-2011, 06:47 AM
BTW, a quick note. You define the "Ready to Install" wizard AFTER the Loop
Wizard (see attached screenshot). That means, you start the installation
process before that dialog gets displayed.

Friedrich

NewsArchive
04-19-2011, 02:18 AM
Andreas,

If you're new to SetupBuilder, Friedrich's explanation may not be totally
clear.

Displaying dialog screens in SB involves two things:
1. Define the dialog screen(s)
2. Run a "Loop Wizard" that actually displays them.

In your script, you do define the screens before you edit the registry.

But you don't actually display them to the user at that point.

You need to move the edit registry script item to AFTER the Loop Wizard that
displays your dialog screen(s).

Jane