aldebaran
Posts: 23
Joined: Wed Dec 05, 2007 4:04 pm
Location: Hannover, Germany
Contact: Website

Tidying up components / resources is hard, is it?

After adding a sparsely populated folder with lots of subfolders, I ended up having about 50 new components many of them not including more than 2 or 3 resources; this is because AI adds a new component for every new (sub-)folder (cf. http://www.advancedinstaller.com/forums ... .php?t=743). Furthermore AI does not allow to move the resources (trying to get rid of components in doing so); this is restricted to very simple cases imho even more simpler than mentioned in the docs http://www.advancedinstaller.com/user-g ... ation.html.

To tidy up the "Features and Components" pane I created a new feature just acting as a container to hold (and evtl. hide) all the automatically generated components with their respective resources. To do so every single component had to be "fed to list" (F4) (lots of keystrokes and mouse-klicks). After populating the "list" I was able to mark all of them and put them to a previously created feature (despite the context-menu's entry reading "Move to New Feature").

This all seems pretty awkward. Is there a better way?

Greetings
Stefan Hackenthal
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Hi,

Please note that the Components in the "Organization" page are created by following Microsoft's guidelines:
http://msdn2.microsoft.com/en-us/librar ... S.85).aspx
http://msdn2.microsoft.com/en-us/librar ... S.85).aspx

Also, you can organize your resources into components by using drag and drop in the "Organization" page. Note that a component cannot be empty, it cannot contain only shortcuts and it cannot be deleted directly (in order to remove a component you must remove it's resources from the project).

Since the components are created by respecting the Windows Installer rules, it is recommended to alter their original structure only in very complex projects with a lot of features. In the rest of the cases (in simple projects with a small number of features) it is recommended to use the original structure if possible.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
aldebaran
Posts: 23
Joined: Wed Dec 05, 2007 4:04 pm
Location: Hannover, Germany
Contact: Website

Yes, I was aware of the fact that the components are created in a certain way not helpful to the user. I even mentioned an older posting, though, this was not as accurately describing the reasons for this arrangement as the two microsoft-links you provide.

Dragging and dropping of resources is in my case no option as it does not work / is not supported as I already mentioned in the original post.

Being aware of these limitations / restrictions I decided to make up a feature solely serving the purpose of being a container for components. In other words, the feature was not introduced because the user has an option to install it or not (based on whatever action) it is rather a means to keep my "Feature and Components"-panel tidy.

Doing this in AI took me more than 100 key presses / clicks as you cannot mark a certain range of components in the "Feature and Components"-panel. And this still seems awkward to me unless I overlooked some shortcut.

For the time being I guess the real answer to my question is:

Yes, AI is awkward in this respect. If you want it more tidy, flatten your directory structure and make your setup less complex.

Unfortunately the latter is no option as it is not in my hands to restructure an existing project in this regard.
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Hi,
Dragging and dropping of resources is in my case no option as it does not work / is not supported as I already mentioned in the original post.
Note that this feature does work as long as you respect these rules:
- a component cannot remain empty
- it cannot contain only shortcuts
- it cannot contain only file operations
- it cannot be deleted directly (you must drag its resources to another component)
- when using drag and drop, you must drop the resource over the name of the target component
Doing this in AI took me more than 100 key presses / clicks as you cannot mark a certain range of components in the "Feature and Components"-panel.
Please note that you can press SHIFT+F4 while a feature is selected in order to feed all the components of the feature into a list. In this list you can use the mouse to select the components you want to move to a new feature or for which you want to set the same properties.

You can read more about the "Organization" page here:
http://www.advancedinstaller.com/user-g ... ation.html
Yes, AI is awkward in this respect. If you want it more tidy, flatten your directory structure and make your setup less complex.
The components are created according to the Windows Installer rules in order to ensure that the package will be installed correctly. However, you can use the "Feed to list" feature to organize the project the way you need. Also, you can move the resources between components by using drag and drop.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
aldebaran
Posts: 23
Joined: Wed Dec 05, 2007 4:04 pm
Location: Hannover, Germany
Contact: Website

Well, as I said in the very first mail, the concrete setting did not allow me to drag and drop the resources in order to tidy up my components. I think this is out of question and it does not help to repeatedly list the circumstances that do allow me to do so. I have a concrete problem and while it is nice to hear that other people may not have it, it is of no help in my situation.

This limitation (or if you prefer not to have a negative connotation: "This playing by the rules of microsoft") is the very reason I did try to come up with a workaround in the first place. Over 50 components directly being part of the main feature makes them hard to overview. Now moving these components to a new feature is / was in my eyes awkward.

Using "Shift F4" somehow relaxes the situation but is still not ideal as you first always copy all (sub-)components to the list. I'd rather like to copy a range of components (generated e.g. by an added folder) to the list and then move them to a new feature. However the panel does not allow doing so, which is in my eyes an inconvenience.
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Hi,

Please note that you can drag and drop resources from a component to another only if you respect the Windows Installer rules (since the MSI packages are handled by Windows Installer, you must follow it's rules when creating installation packages).

Therefore, if you break the Windows Installer rules when moving a resource Advanced Installer will not let you move the resource.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”