A Windows XP help forum. PCbanter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » PCbanter forum » Microsoft Windows 7 » Windows 7 Forum
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Positioning the Windows Explorer windows



 
 
Thread Tools Rate Thread Display Modes
  #121  
Old March 16th 18, 04:08 PM posted to alt.windows7.general
Zaidy036[_5_]
external usenet poster
 
Posts: 427
Default Positioning the Windows Explorer windows

On 2/28/2018 6:36 AM, Zaidy036 wrote:
Paul wrote:
Zaidy036 wrote:
Ken Springer wrote:
Windows 7 Pro

Using a desktop shortcut, is it possible to open a Windows Explorer
window to a specific folder and position on the desktop?

In this specific case, I'd like to have a shortcut open Folder A in a
window that is snapped to the left, and a 2nd shortcut open Folder B
snapped to the right.

snip
Home again but do not have time to write entire batch. Following is
process that I would ude to make the required batch:
===============
Start with two simple batches and after testing combine into one with
selecting logic.

--- Basic batch LEFT---
Batch to test for CMD window and move to Left on monitor and rename

first check if cmd window exists
if not display warning and after pause exit
:: This nircmd moves cmd window to my left (non-primary) of two monitors
WORKING as Administrator
START "" /WAIT "C:\Program Files\nircmd-x64\nircmd.exe" win setsize
stitle "Administrator" -1300 0 1300 1090

:: Use Nircmd to rename this window as "Left"
Pause
Exit

--- Basic batch RIGHT ---
Batch to test for CMD window and move to Right on monitor and rename
:: Repeat Left but move cmd window to Right and rename.
Pause
Exit

TEST that both above work for you

Then a new batch to combine above

At beginning of batch check if Left and/or Right windows exist
- if neither exist use basic batch LEFT cmds
- if only Right exists use basic batch LEFT cmds
- if only Left exists use basic batch Right cmds
- if both exist then
ask which one to replace
delete one to be replaced
run batch cmd section needed.
==========

--
Zaidy036
Ads
  #122  
Old March 17th 18, 03:34 AM posted to alt.windows7.general
B00ze
external usenet poster
 
Posts: 472
Default Positioning the Windows Explorer windows

On 2018-03-15 23:27, Mayayana wrote:

"B00ze" wrote

| Wow, we have to iterate through all the Windows.

Only IE and Explorer windows.


Ah, ok, good enough.

| Do you have to make
| them visible before you can move them around?

I don't know. On XP it's instant for me. On 7 it's a
bit slow. But on both I don't find it distracting.

| What if I want to open one window to C:\ and one to D:\ ? There
| is no folder name, and if there was they'd be the same :-(

Try it. Add a msgbox:
For Each Win in Wins
sName = Win.LocationName
MsgBox sName 'add this line


Ah yes, they get the name of the volume and the drive letter; good. But
I think it might be hopeless. When I tried this (with the msgbox) under
my user, after disabling the Clover BHO, I ended-up with FOUR windows
lol! Two Internet Explorer ones, and two regular Explorer ones. Same
thing was happening with the previous version of the script by the way.
So I "Switched User" to the Administrator, and lo'and'behold, even WITH
the Clover BHO running, both scripts behaved as they should (basically,
two new TABs were opened in the current Explorer; this is the BHO doing
this). Think I'll just continue to click my Clover/Explorer icon twice
every time I boot the PC lol (I always open two).

Best Regards,

--
! _\|/_ Sylvain /
! (o o) Memberavid-Suzuki-Fdn/EFF/Red+Cross/SPCA/Planetary-Society
oO-( )-Oo Don't let Kirk show you what he calls The Captain's Log.

  #123  
Old March 17th 18, 12:54 PM posted to alt.windows7.general
Mayayana
external usenet poster
 
Posts: 6,438
Default Positioning the Windows Explorer windows

"B00ze" wrote

| Ah yes, they get the name of the volume and the drive letter; good. But
| I think it might be hopeless. When I tried this (with the msgbox) under
| my user, after disabling the Clover BHO, I ended-up with FOUR windows
| lol! Two Internet Explorer ones, and two regular Explorer ones.

Did you clean up the paths? For the root
folder I get something like ANNEX (D
It's listing the volume name.
So to make it work if you want to open root
folders, you'd need to adjust Fol1Name
accordingly:


Fol1 = "D:\"
Fol1Name = "ANNEX (D"
'--ANNEX is the volume name on my D drive.

I'm not running as admin. Win7-64. But I do shut off
UAC. I think I've got IE10 if I remember correctly.
(I seem to remember that IE11 wouldn't install. It kept
complaining about needing to update things that had
already been updated. Leave it to Microsoft to have
broken installers for *their own* software on their own
OS...
Or it may have been like the man in the car
offering candy to a child: "Yes, you can have this
shiny new IE11 for free. You just have to climb in my car
to get it. Let us through your firewall to rummage around
on your system and the candy is yours. There you
go. That wasn't so hard, now, was it?")

There shouldn't be two IEs because by the time it's
visible it's been converted to an Explorer window. It
sounds like you've got more than one funky shell
extension on your system.

| Think I'll just continue to click my Clover/Explorer icon twice
| every time I boot the PC lol (I always open two).
|

The point was to open two folder windows in specific
places. If all you need is two specific folder windows open
at startup then why not just drop the shortcuts into
Startup?

But something tells me you might feel rather
deflated if you had a simple, easy, dependable way
to get the job done. ..... "Now what?"


  #124  
Old March 20th 18, 04:38 AM posted to alt.windows7.general
B00ze
external usenet poster
 
Posts: 472
Default Positioning the Windows Explorer windows

On 2018-03-17 08:54, Mayayana wrote:

"B00ze" wrote

| Ah yes, they get the name of the volume and the drive letter; good. But
| I think it might be hopeless. When I tried this (with the msgbox) under
| my user, after disabling the Clover BHO, I ended-up with FOUR windows
| lol! Two Internet Explorer ones, and two regular Explorer ones.

Did you clean up the paths? For the root
folder I get something like ANNEX (D
It's listing the volume name.
So to make it work if you want to open root
folders, you'd need to adjust Fol1Name
accordingly:


I just left it at this:

Fol1 = "C:\"
Fol2 = "D:\"
Fol1Name = "Fol1"
Fol2Name = "Fol2"

Because I'd added the msgBox to see what the window name would be. Just
to see what would happen today, I ran the newer script right away and
ended-up with the same behaviour as when I tested the first script: Two
Internet windows and 1 new TAB in already opened Explorer. So I went
ahead and disabled the Clover BHO and I ended-up with 4 windows again (2
internet 2 regular). I'd have to unInstall Clover to be sure...

I'm not running as admin. Win7-64. But I do shut off
UAC. I think I've got IE10 if I remember correctly.
(I seem to remember that IE11 wouldn't install. It kept
complaining about needing to update things that had
already been updated. Leave it to Microsoft to have
broken installers for *their own* software on their
own OS...


Lol, it's funny you say that. I currently have MSIExec running like 3
times a day trying to "repair" Office 2016 because it thinks some
components are missing. Re-installing Office doesn't fix it. It's
annoying because it creates EventLog entries and also creates a log file
in C:\Temp, ignoring completely the fact that %TEMP% points to somewhere
else. I think it was broken by one of the many updates Microsoft pushed
for Office. When a Microsoft product breaks there is a high chance that
it was broken by, yup, Microsoft. Now I don't know for a fact that an
update broke Office (or the MSI database) but I can't think of anything
else I've installed that would go and play around with Office component
registrations.

Or it may have been like the man in the car
offering candy to a child: "Yes, you can have this
shiny new IE11 for free. You just have to climb in my car
to get it. Let us through your firewall to rummage around
on your system and the candy is yours. There you
go. That wasn't so hard, now, was it?")

There shouldn't be two IEs because by the time it's
visible it's been converted to an Explorer window. It
sounds like you've got more than one funky shell
extension on your system.


Yeah, I don't get it at all, the code opens 2 windows, not 4, so why do
I end-up with 4 lol...

| Think I'll just continue to click my Clover/Explorer icon twice
| every time I boot the PC lol (I always open two).

The point was to open two folder windows in specific
places. If all you need is two specific folder windows open
at startup then why not just drop the shortcuts into
Startup?


Oh I was just curious to see if we could position them as desired; on
Win7 they remember their size but they are positioned by the OS.

But something tells me you might feel rather
deflated if you had a simple, easy, dependable way
to get the job done. ..... "Now what?"


Lol, I just think the code is so neat, I want to see it work ;-)

Best Regards,

--
! _\|/_ Sylvain /
! (o o) Memberavid-Suzuki-Fdn/EFF/Red+Cross/SPCA/Planetary-Society
oO-( )-Oo A centipede is an ant made to government specs.

  #125  
Old March 20th 18, 12:54 PM posted to alt.windows7.general
Mayayana
external usenet poster
 
Posts: 6,438
Default Positioning the Windows Explorer windows

"B00ze" wrote

| I just left it at this:
|
| Fol1 = "C:\"
| Fol2 = "D:\"
| Fol1Name = "Fol1"
| Fol2Name = "Fol2"
|

That could be part of the problem. The later script
works fine for me on Win7.
The gist of it is that 2 IEs are started, then sent
to a folder address, which turns them into Explorer
instances. The folder windows are then accessed
using Shell.Application, which is the automation
object of Explorer.

The only way to find the open folders from the script,
in order to position them, is by iterating the Windows
collection, which is all open Explorer or IE instances.
Then each window can be identified by LocationName,
LocationURL, etc. (Remember that officially each window
is an IE instance, but only the actual IEs can be treated
as IE. Instances of Explorer only partially implement the
IE object model. And importantly, the folder window
document object is a ShellFolderView object (which wraps
the ListView that displays folders and files), not an
IE document. The whole thing is full of potholes, and
poorly documented.)

OK.... So you've got the windows and you test
LocationName to locate the windows you want to
position. Since you've opened C:\ and you're
looking for "Fol1" you're never going to find it.
(Unless you also have a Fol1 folder open.)

You can't just go changing the code willy nilly
and expect it to work in interesting ways. Unless
you think breaking it is interesting.

If you're curious, there's a collection of useful
Shell.Application scripts he

https://www.jsware.net/jsware/scrfiles.php5#shlap

They cover pretty much anything you can do
with it that's worth doing. There are basically
two classes of function with Shell. One is to
automate basic desktop functions like cascading
windows or opening a folder. The other is mainly
for use by shell extensions and uses the ShellFolderView
to access content and events in a folder ListView.
It allows you to list items, change the selected item,
etc.

| Leave it to Microsoft to have
| broken installers for *their own* software on their
| own OS...
|
| Lol, it's funny you say that. I currently have MSIExec running like 3
| times a day trying to "repair" Office 2016 because it thinks some
| components are missing.

That seems to be a common problem. Supposedly
it results from a faulty or interrupted install. But
if re-installing doesn't fix it then that doesn't sound
like the problem.
It sounds very tedious. I guess you could just
disable the windows Installer service. But you'd need
to re-enable it next time you want to install or
uninstall something that uses an MSI.


  #126  
Old March 20th 18, 01:14 PM posted to alt.windows7.general
Spalls Hurgenson
external usenet poster
 
Posts: 123
Default Positioning the Windows Explorer windows

On Tue, 27 Feb 2018 13:05:55 -0700, Ken Springer
wrote:

Windows 7 Pro


Using a desktop shortcut, is it possible to open a Windows Explorer
window to a specific folder and position on the desktop?


In this specific case, I'd like to have a shortcut open Folder A in a
window that is snapped to the left, and a 2nd shortcut open Folder B
snapped to the right.


This was my number one complaint when I initially switched to Windows
7. I just use ShellFolderFix to correct it

https://www.sevenforums.com/free-dev...ions-size.html

Just load it in the background, and open an explorer folder. Move it
to wherever. When you close it, SFF will remember its size and
postition and where in the file structure you are. Reopen that same
folder, it pops the window back to the same location.

So, for instance, when I open explorer to show "My computer", it pops
up that window on my main monitor. When I open a folder to "Work
Docs", the window opens up on the left monitor so I can see the files
with my application open on the main. My "Quick notes" folder opens in
a narrow bar on the right of the screen.

Some minor disadvantages of this system: it saves the size/position
when you close the window, so if you've moved the window a bit, it
will remember its new location rather than your preferred location. It
doesn't have a feature to set a folder location through a shortcut so
you can't force a location. There is a tiny (a fraction of a second)
lag between opening a folder and it moving to the right space, so
there's a little "pop" after the window opens and jumps to the right
place. But otherwise it's easy to use and does exactly what I want it
to do.


  #127  
Old March 20th 18, 01:34 PM posted to alt.windows7.general
Mayayana
external usenet poster
 
Posts: 6,438
Default Positioning the Windows Explorer windows

"Spalls Hurgenson" wrote

| In this specific case, I'd like to have a shortcut open Folder A in a
| window that is snapped to the left, and a 2nd shortcut open Folder B
| snapped to the right.
|
| This was my number one complaint when I initially switched to Windows
| 7. I just use ShellFolderFix to correct it
|

You're talking about remembering folder
positions. He's talking about wanting one
click to open and position 2 folders. That's
two different things.


  #128  
Old March 21st 18, 03:44 AM posted to alt.windows7.general
B00ze
external usenet poster
 
Posts: 472
Default Positioning the Windows Explorer windows

On 2018-03-20 08:54, Mayayana wrote:

"B00ze" wrote

| I just left it at this:
|
| Fol1 = "C:\"
| Fol2 = "D:\"
| Fol1Name = "Fol1"
| Fol2Name = "Fol2"
|

That could be part of the problem. The later script
works fine for me on Win7.


I don't think that's part of the problem; the loop on Win in Wins just
wont find the windows, so it will not re-position them, but this doesn't
create any additional windows. I think it's Clover, it's an ugly hack -
it's really nice to have TABs in Explorer, but it breaks a few things,
like your VBS. The behaviour is unpredictable, that's the strange thing...

The gist of it is that 2 IEs are started, then sent
to a folder address, which turns them into Explorer
instances. The folder windows are then accessed
using Shell.Application, which is the automation
object of Explorer.


Yeah, I really don't understand ending-up with 4 windows, I'm pretty
sure it's Clover, even with the BHO disabled.

The only way to find the open folders from the script,
in order to position them, is by iterating the Windows
collection, which is all open Explorer or IE instances.
Then each window can be identified by LocationName,
LocationURL, etc. (Remember that officially each window
is an IE instance, but only the actual IEs can be treated
as IE. Instances of Explorer only partially implement the
IE object model. And importantly, the folder window
document object is a ShellFolderView object (which wraps
the ListView that displays folders and files), not an
IE document. The whole thing is full of potholes, and
poorly documented.)

OK.... So you've got the windows and you test
LocationName to locate the windows you want to
position. Since you've opened C:\ and you're
looking for "Fol1" you're never going to find it.
(Unless you also have a Fol1 folder open.)


No, I won't, but I never went further than displaying the window names
with msgBox (so that I could set the window name variables correctly)
because of the weird behaviour I'm experiencing with Clover running...

You can't just go changing the code willy nilly
and expect it to work in interesting ways. Unless
you think breaking it is interesting.


Lol, you gotta admit it's fairly simple, it's easy to play around with...

If you're curious, there's a collection of useful
Shell.Application scripts he

https://www.jsware.net/jsware/scrfiles.php5#shlap


Lol, that script archive has a "Warning Unpredictable" file in the
Windows manipulation folder hehehe. I rarely code in VBS so I'm unlikely
to be calling Shell-Application anyway. The one complex thing I coded in
VBS, quite a while ago, I don't even understand anymore - it works, but
it's pretty crazy and I can't change it anymore lol. Oh, you just
reminded me that I wanted to have a look at the MSI tools on jsWare. I
don't know what happened to the Firefox tab I was keeping opened on that
page. Re-opened it.

They cover pretty much anything you can do
with it that's worth doing. There are basically
two classes of function with Shell. One is to
automate basic desktop functions like cascading
windows or opening a folder. The other is mainly
for use by shell extensions and uses the ShellFolderView
to access content and events in a folder ListView.
It allows you to list items, change the selected item,
etc.

| Leave it to Microsoft to have
| broken installers for *their own* software on their
| own OS...
|
| Lol, it's funny you say that. I currently have MSIExec running like 3
| times a day trying to "repair" Office 2016 because it thinks some
| components are missing.

That seems to be a common problem. Supposedly
it results from a faulty or interrupted install. But
if re-installing doesn't fix it then that doesn't sound
like the problem.


Well, when I re-installed Office, I had a look at the "Programs and
Features" right afterwards - specifically at the list of Microsoft
Updates, and ALL the Office ones had a "Today" date, as if they were
stored in WinSXS and re-applied live as I re-installed Office. I think
that is not accurate, because one of the updates adds a feature to
Office and that feature was missing until I went into Windows-Update and
re-applied all the Office updates. But who knows. The Event Log is not
super useful either, here is an example (MSIExec generates 4 events each
time):

Detection of product '{90160000-0051-0000-1000-0000000FF1CE}', feature
'ProductFiles', component '{77586F20-86BA-4A4F-8A47-10B34A263C86}'
failed. The resource
'HKEY_CLASSES_ROOT(64)\CLSID\{000C0126-0000-0000-C000-000000000046}\'
does not exist.

If I look at HKEY-Classes, 000C0126-0000-0000-C000-000000000046 is
MSO.DLL and it obviously isn't missing, Office would not work at all if
it was. I cannot find the component itself in the registry, so I'm not
quite sure where it is stored (if I could just get rid of that component
registration, the errors would go away).

It sounds very tedious. I guess you could just
disable the windows Installer service. But you'd need
to re-enable it next time you want to install or
uninstall something that uses an MSI.


Hahaha, no that would just be annoying having to re-enable it every time
something needed to update. I think I'll go on TechNET and complain
there. Chances are some clueless "helper" will tell me to do a Clean
Boot and other irrelevant troubleshooting steps, but there is a very
small chance someone who knows MSI will pipe-in. SMALL chance tho. I
once tried to have TechNET analyze a user-mode dump of an Intel driver
and I was told it was too complicated for TechNET...

Best Regards,

--
! _\|/_ Sylvain /
! (o o) Memberavid-Suzuki-Fdn/EFF/Red+Cross/SPCA/Planetary-Society
oO-( )-Oo Cap'n Crunch found dead - Cerial killer suspected.

  #129  
Old March 21st 18, 01:06 PM posted to alt.windows7.general
Spalls Hurgenson
external usenet poster
 
Posts: 123
Default Positioning the Windows Explorer windows

On Tue, 20 Mar 2018 09:34:17 -0400, "Mayayana"
wrote:

"Spalls Hurgenson" wrote

| In this specific case, I'd like to have a shortcut open Folder A in a
| window that is snapped to the left, and a 2nd shortcut open Folder B
| snapped to the right.


| This was my number one complaint when I initially switched to Windows
| 7. I just use ShellFolderFix to correct it


You're talking about remembering folder
positions. He's talking about wanting one
click to open and position 2 folders. That's
two different things.

Actually, the request mentioned two shortcuts, not one. It is possible
he added further specifications in a later post but if he did, I
missed it.

But based on the original request, ShellFolderFix would seem to suit
his needs. He can create a shortcut to C:\FOLDER1, open it, position
it, close it and the next time he uses that shortcut SFF will move the
C:\FOLDER1 window to its previous location. He can do the same with
C:\FOLDER2, and SFF will remember that location too, even if it is
different from C:\FOLDER1

The only real issue being that the location isn't stored in a
shortcut. This means the location isn't permanently saved (the folder
location will be updated if the user moves the folder) nor can the
information be transferred to another computer.

Original poster seemed to want a simple solution for a computer
illiterate user. This one seems far less complex than delving into VBS
or other scripting programs.

Well, no matter. It's just another option the original poster can
consider.

  #130  
Old March 21st 18, 02:02 PM posted to alt.windows7.general
Mayayana
external usenet poster
 
Posts: 6,438
Default Positioning the Windows Explorer windows

"B00ze" wrote

| Oh, you just
| reminded me that I wanted to have a look at the MSI tools on jsWare.
|

You won't find anything there to help with a bad
MS Office install. There are tools for unpacking
MSIs, editing them, and using them as easy-to-use
and portable databases. But there's nothing about
actually dealing with install issues.

I originally came across MSIs when I was writing
some software for a blind friend and wanted to
install SAPI5 (speech API) to his Win98 computer.
At the time, MS was selling Windows Installer hard
and refused to release a SAPI5 installer. There were
only 2 options:

1) Install the 100+- MB SAPI SDK.

2) Download 100 MB of "merge modules and
build a SAPI5 installer from scratch.

That was all to get 6 MB of files and about
a dozed Registry settings installed!
At first I decided to figure out MSIs, since MS
said it was the future. But the more I looked into
it, the more I decided it was an indefensible
monstrosity and that my time would be better
spent figuring out how to bypass it. I ended up
writing scripts to auto-build installers for things
like SAPI5.

As it turned out, making an unpacker was useful
in order to allow people to check out what an
installer would do before installing. An editor
was useful in order to adjust problematic settings
in an installer. And all kinds of things can be done
with MSIs as databases.
But an MSI for installing software.... To me that's
a harebrained idea so I haven't spent time deailing
with them. Fortunately, it's mostly only MS that
use them. Some big partner companies are pressured
to use them, either by MS or by IT people who like
the way they can track software across a network
more easily with MSIs. But even many of the non-MS
MSIs are only MSI wrappers around other kinds of
installers.


| Well, when I re-installed Office, I had a look at the "Programs and
| Features" right afterwards - specifically at the list of Microsoft
| Updates, and ALL the Office ones had a "Today" date, as if they were
| stored in WinSXS and re-applied live as I re-installed Office. I think
| that is not accurate, because one of the updates adds a feature to
| Office and that feature was missing until I went into Windows-Update and
| re-applied all the Office updates. But who knows. The Event Log is not
| super useful either, here is an example (MSIExec generates 4 events each
| time):
|
| Detection of product '{90160000-0051-0000-1000-0000000FF1CE}', feature
| 'ProductFiles', component '{77586F20-86BA-4A4F-8A47-10B34A263C86}'
| failed. The resource
| 'HKEY_CLASSES_ROOT(64)\CLSID\{000C0126-0000-0000-C000-000000000046}\'
| does not exist.
|
| If I look at HKEY-Classes, 000C0126-0000-0000-C000-000000000046 is
| MSO.DLL and it obviously isn't missing, Office would not work at all if
| it was. I cannot find the component itself in the registry, so I'm not
| quite sure where it is stored (if I could just get rid of that component
| registration, the errors would go away).
|

I'd do a search on that CLSID and repeated repair of
Office install. You're probably not alone.

| I think I'll go on TechNET and complain
| there. Chances are some clueless "helper" will tell me to do a Clean
| Boot and other irrelevant troubleshooting steps, but there is a very
| small chance someone who knows MSI will pipe-in. SMALL chance tho. I
| once tried to have TechNET analyze a user-mode dump of an Intel driver
| and I was told it was too complicated for TechNET...
|

I can save you the time:

Hello and thank you for asking a question. I
understand you saying that you have a problem
with an MS Office install. Is that correct? Please
describe the problem again and also list
your Windows version, hardware information,
make and model of your car, and names of
your children. Then please reinstall Windows,
reinstall MS Office, and set a system restore
backup.... Did you remember to disable all
browser extensions and boot into Safe Mode for
good measure?
Then please run Windows Update and allow
it to finish. Then return here and ask your
question again.

Once again, thank you so much for asking a
question. Was this helpful? Please fill in the
questionaire below, and have a nice day. And
don't forgt to vote for me. It helps me get
Microsoft Medals next to my name.

Ed Helpalot MS MVP/ABC/Ph.D/MSW/Lic.MD/Etc




  #131  
Old March 22nd 18, 04:19 AM posted to alt.windows7.general
B00ze
external usenet poster
 
Posts: 472
Default Positioning the Windows Explorer windows

On 2018-03-21 10:02, Mayayana wrote:

"B00ze" wrote

| Oh, you just
| reminded me that I wanted to have a look at the MSI tools on jsWare.

You won't find anything there to help with a bad
MS Office install. There are tools for unpacking
MSIs, editing them, and using them as easy-to-use
and portable databases. But there's nothing about
actually dealing with install issues.


No no, it's not for dealing with the Office 2016 problem, it's for
editing MSI's ;-) Specifically, I want to be able to deal with those
where when I unpack them with 7-Zip, all I get are a few resources and
ANOTHER database inside (like "1" or "[1]" with no file extension). I
tried ORCA once but quickly gave-up lol. It's like 95 different tables
cross-referencing each other. I was expecting a script, and nothing
else, not a crazy database with all kinds of fields and properties I did
not understand.

I originally came across MSIs when I was writing
some software for a blind friend and wanted to
install SAPI5 (speech API) to his Win98 computer.
At the time, MS was selling Windows Installer hard
and refused to release a SAPI5 installer. There were
only 2 options:


That's quite a while ago, nowadays they release everything as MSI or MSU
(which I presume is the same thing) or good old CABs.

1) Install the 100+- MB SAPI SDK.

2) Download 100 MB of "merge modules and
build a SAPI5 installer from scratch.

That was all to get 6 MB of files and about
a dozed Registry settings installed!
At first I decided to figure out MSIs, since MS
said it was the future. But the more I looked into
it, the more I decided it was an indefensible
monstrosity and that my time would be better
spent figuring out how to bypass it. I ended up
writing scripts to auto-build installers for things
like SAPI5.


You can build MSI's with plain old Windows? No extra tool needed? I
tried an eval version of one of the most well-known/advanced MSI Builder
tool (I can't find the name, something that costs plenty of dollars) and
also quickly gave up ;-)

As it turned out, making an unpacker was useful
in order to allow people to check out what an
installer would do before installing. An editor
was useful in order to adjust problematic settings
in an installer. And all kinds of things can be done
with MSIs as databases.


Yeah, that's why I'm interested in your tools. I can do administrative
installs and get what I want that way, but it doesn't always work.

But an MSI for installing software.... To me that's
a harebrained idea so I haven't spent time deailing
with them. Fortunately, it's mostly only MS that
use them. Some big partner companies are pressured
to use them, either by MS or by IT people who like
the way they can track software across a network
more easily with MSIs. But even many of the non-MS
MSIs are only MSI wrappers around other kinds of
installers.


Yeah, lots of MSIs unpack to a single slightly smaller EXE installer,
lol. But MSIs are nice because you can push those through Group Policy.
And there's software registration too - you can query MSI installed
stuff via WMI, ask it to uninstall itself remotely via WinRM, etc. I
agree tho, it's a monstrosity.

| Well, when I re-installed Office, I had a look at the "Programs and
| Features" right afterwards - specifically at the list of Microsoft
| Updates, and ALL the Office ones had a "Today" date, as if they were
| stored in WinSXS and re-applied live as I re-installed Office. I think
| that is not accurate, because one of the updates adds a feature to
| Office and that feature was missing until I went into Windows-Update and
| re-applied all the Office updates. But who knows. The Event Log is not
| super useful either, here is an example (MSIExec generates 4 events each
| time):
|
| Detection of product '{90160000-0051-0000-1000-0000000FF1CE}', feature
| 'ProductFiles', component '{77586F20-86BA-4A4F-8A47-10B34A263C86}'
| failed. The resource
| 'HKEY_CLASSES_ROOT(64)\CLSID\{000C0126-0000-0000-C000-000000000046}\'
| does not exist.
|
| If I look at HKEY-Classes, 000C0126-0000-0000-C000-000000000046 is
| MSO.DLL and it obviously isn't missing, Office would not work at all if
| it was. I cannot find the component itself in the registry, so I'm not
| quite sure where it is stored (if I could just get rid of that component
| registration, the errors would go away).
|

I'd do a search on that CLSID and repeated repair of
Office install. You're probably not alone.


Nha, I'm alone lol, searching on DuckDuckGo returns nothing. No idea
why! It was all working fine, then one day BAM, MSIExec says I'm missing
Office stuff. I would have to once again remove Office, and this time
run the Office CleanUp tool, then reInstall, but I would loose all my
settings (if the CleanUp tool does its job) and I'm not really
interested in that. I got most of the settings backed-up as .REG files
etc, but it's still a pain to re-configure Office.

| I think I'll go on TechNET and complain
| there. Chances are some clueless "helper" will tell me to do a Clean
| Boot and other irrelevant troubleshooting steps, but there is a very
| small chance someone who knows MSI will pipe-in. SMALL chance tho. I
| once tried to have TechNET analyze a user-mode dump of an Intel driver
| and I was told it was too complicated for TechNET...
|

I can save you the time:

Hello and thank you for asking a question. I
understand you saying that you have a problem
with an MS Office install. Is that correct? Please
describe the problem again and also list
your Windows version, hardware information,
make and model of your car, and names of
your children. Then please reinstall Windows,
reinstall MS Office, and set a system restore
backup.... Did you remember to disable all
browser extensions and boot into Safe Mode for
good measure?
Then please run Windows Update and allow
it to finish. Then return here and ask your
question again.


Hahaha! Yeah, that's exactly what I think will happen ;-) They will
eventually say "restore Windows" - Like sure, I will loose 1.5 years of
tweaking and customization and software installing? I got partition
images I can go back to, and then re-install the Windows updates and see
if that's the problem, but I'm not yet interested in spending a whole
day trying to fix this...

Once again, thank you so much for asking a
question. Was this helpful? Please fill in the
questionaire below, and have a nice day. And
don't forgt to vote for me. It helps me get
Microsoft Medals next to my name.

Ed Helpalot MS MVP/ABC/Ph.D/MSW/Lic.MD/Etc


LMAO! MS MVP/ABC/PHD/etc!

Regards,

--
! _\|/_ Sylvain /
! (o o) Memberavid-Suzuki-Fdn/EFF/Red+Cross/SPCA/Planetary-Society
oO-( )-Oo Tribbles who love Klingons, on the next Oprah!

  #132  
Old March 22nd 18, 01:38 PM posted to alt.windows7.general
Mayayana
external usenet poster
 
Posts: 6,438
Default Positioning the Windows Explorer windows

"B00ze" wrote

|Specifically, I want to be able to deal with those
| where when I unpack them with 7-Zip, all I get are a few resources and
| ANOTHER database inside (like "1" or "[1]" with no file extension).

Ah. Don't unpack them with 7-Zip. Depending on
how you do it you might get tables or you might
get "custom actions". (Things like EXEs and VBScripts
that companies like InstallShield embed to customize
installer functionality.)
But 7-Zip doesn't actually understand the format.
It's unpacking it as a compound storage file. Like
a Word DOC. I explain that on my site. It's like slicing
a car into sections. You get parts of the car,
but it's not a relevant way to dissect the car.

The only thing 7-Zip is good for is to extract a
CAB if there is one (or more). But even then, as
you probably know, it's "traditional" to mangle file
names in side the CAB beyond recognition. The
CAB contents need to be cleaned up to be useful.


| I
| tried ORCA once but quickly gave-up lol. It's like 95 different tables
| cross-referencing each other. I was expecting a script, and nothing
| else, not a crazy database with all kinds of fields and properties I did
| not understand.
|

You'll find the same thing with my editor. That's
what an MSI is. See the other scripts on the page.
You can fiddle with resources in the MSI. You
can extract the CAB. You can extract tables as
text files. You can edit tables to fix things like a
program that works on Win7 but refuses to install
on Win7. I even wrote a script that allows you to
customize the installer splash screen with a different
picture or notes to yourself for future reference.
But there's nothing like an install script or INI.

That's the problem with MSIs. That's why I worked
on unpacking them instead of using them as
installers. (But to be fair, as mentioned earlier, they
do provide a way for corporate admins to track
software more easily. They standardize the system
of install and removal... sort of.)

An install builder can add custom actions, but in
general it is a database with 100+- tables and massive
cross-referencing. It would make Rube Goldberg green
with envy. If he'd known, he probably would have
stopped making cartoons, having seen a scale of
superfluous complexity that he'd never even dreamed
of. Idiocy elevated to genius.

I think it's important to remember that while
Microsoft's #1 product is monopoly maintenance and
software is probably at #2 or #3, the manufacture
of abstruseness is also one of their top products.
It supports an entire industry of programmers,
instructors, and people with trumped up titles
like "MVP". Exactly analogous to the bizarre number
of years that plumbers have to work as helpers
and doctors have to spend in school: The harder it is
to break in, the more money one can charge.

But it is possible to make sense of the whole
thing. See my VBS version of the unpacker for the
details. (The EXE version does exactly the same
thing. The EXE just uses the msi.dll API while the
VBS uses the dispatch COM interface. And the EXE
is more "robust" if you need to do something like
unpack a 1 GB installer with 18 CABs.)

It also helps to get the MSI CHM, which is quite
good. It even has a tutorial on what they call
WQL. (Windows QL, a subset of SQL.)

But for every rule in an MSI there's also an
exception. There are lots of cases where "such
and such works this way *if* the other thing is true".

I've also had to update my code periodically
after finding faulty MSIs that nevertheless
worked to run an install. (That's in the update
notes. One was from an MS MVP. Another was
from Microsoft themselves!)

The closest thing to a script, in a normal install,
is the InstallExecuteSequence table. The steps are
done in numeric order from the Sequence column.
(The numbers are meaningless except as and
values. It could be steps 1,2,3 but people usually
like to get mysterious and name the first step, say,
1500 with the next step being 3600... just to mess
with you.
The LaunchConditions table is where the install
might be restricted from running under certain
coditions.
But most of it is just very poorly organized details
about actually doing the install.


| You can build MSI's with plain old Windows? No extra tool needed? I
| tried an eval version of one of the most well-known/advanced MSI Builder
| tool (I can't find the name, something that costs plenty of dollars) and
| also quickly gave up ;-)
|

Maybe InstallShield?
Yes, you can build your own MSIs. It's all in msi.dll.
I just created a database to store my old email recently.
(It's available on the scripts page.) It stores them
all in an MSI, with extensive search capability.

But if you want to build one to actually install
software... the problem is not being able to do it
but rather getting the hang of that vast system
of interconnected tables. And that's only for a vanilla
installer. If you want something a bit more spicy
then you have to embed custom actions.... Which
explains why companies like InstallShield can charge
so much. That's probably also another reason why
MS made the whole thing so unusable. It's like
shopping carts on websites: For every person who
actually knows how to write HTML and script, there
are 1,000 doing drag/drop websites on Wordpress,
who will never need to understand their own webpage
code.
Since few people will ever get the hang of MSIs,
InstallShield can sell a variation on the WYSIWYG
editor.

I always use my own installer. When Microsoft sold
VB6, it came with the source code of the installer
they provided. I trimmed that down to make my own.
It's handy because it's not only simple and clean but
also allows for easy customizing of the UI. Though my
installer doesn't have the extras needed to do something
like install an office suite across a network, run an
updater/spyware on completion, or any of the other
fancy stuff that installers can do these days. Mine
is only for basic desktop software installs.

| Yeah, lots of MSIs unpack to a single slightly smaller EXE installer,
| lol. But MSIs are nice because you can push those through Group Policy.
| And there's software registration too - you can query MSI installed
| stuff via WMI, ask it to uninstall itself remotely via WinRM, etc.
|

Exactly. Many companies don't want to bother with the
mess, but they have to pack inside an MSI if they want
to sell to corporate customers with cranky IT people.


  #133  
Old March 24th 18, 02:30 AM posted to alt.windows7.general
B00ze
external usenet poster
 
Posts: 472
Default Positioning the Windows Explorer windows

On 2018-03-22 09:38, Mayayana wrote:

"B00ze" wrote

|Specifically, I want to be able to deal with those
| where when I unpack them with 7-Zip, all I get are a few resources and
| ANOTHER database inside (like "1" or "[1]" with no file extension).

Ah. Don't unpack them with 7-Zip. Depending on
how you do it you might get tables or you might
get "custom actions". (Things like EXEs and VBScripts
that companies like InstallShield embed to customize
installer functionality.)


It's supposed to pick the largest object inside the MSI and unpack that,
but this rarely works. You can use #:e mode, which sometimes works, but
like you said what I mostly get is a bunch of useless objects (I tried
just now on the Python MSI; gives me a bunch of CABs and a bunch of
ZIPs; not a fully installed project).

But 7-Zip doesn't actually understand the format.
It's unpacking it as a compound storage file. Like
a Word DOC. I explain that on my site. It's like slicing
a car into sections. You get parts of the car,
but it's not a relevant way to dissect the car.


Lol, I went to your site, that's exactly what you say ;-)

The only thing 7-Zip is good for is to extract a
CAB if there is one (or more). But even then, as
you probably know, it's "traditional" to mangle file
names in side the CAB beyond recognition. The
CAB contents need to be cleaned up to be useful.


Not necessarily, for example the Python CAB inside the MSI has all good
names, but there's no PATH...

| tried ORCA once but quickly gave-up lol. It's like 95 different tables
| cross-referencing each other. I was expecting a script, and nothing
| else, not a crazy database with all kinds of fields and properties I did
| not understand.

You'll find the same thing with my editor. That's
what an MSI is. See the other scripts on the page.
You can fiddle with resources in the MSI. You
can extract the CAB. You can extract tables as
text files. You can edit tables to fix things like a
program that works on Win7 but refuses to install
on Win7. I even wrote a script that allows you to
customize the installer splash screen with a different
picture or notes to yourself for future reference.
But there's nothing like an install script or INI.


Well, there's the InstallExecuteSequence table (and the
adminInstallSequence). Unpacking the CAB with no paths is mostly
useless, but sometimes there is no adminInstallSequence, so that to do?

An install builder can add custom actions, but in
general it is a database with 100+- tables and massive
cross-referencing. It would make Rube Goldberg green
with envy. If he'd known, he probably would have
stopped making cartoons, having seen a scale of
superfluous complexity that he'd never even dreamed
of. Idiocy elevated to genius.


Lol

I think it's important to remember that while
Microsoft's #1 product is monopoly maintenance and
software is probably at #2 or #3, the manufacture
of abstruseness is also one of their top products.
It supports an entire industry of programmers,
instructors, and people with trumped up titles
like "MVP". Exactly analogous to the bizarre number
of years that plumbers have to work as helpers
and doctors have to spend in school: The harder it is
to break in, the more money one can charge.


I'm not sure that they do it on purpose, but they do end-up with
everything being extra complicated, and everything depending on
something else which itself depends on something else. I think it's
because they cater to businesses, and those don't realize what they're
getting into - they don't understand that for Office to have this super
rarely used capability, but for which business X swears it cannot live
without, the whole thing has to be made convoluted and impossible to
support; all the business cares about is that shiny new capability that
they'll use once...

But it is possible to make sense of the whole
thing. See my VBS version of the unpacker for the
details. (The EXE version does exactly the same
thing. The EXE just uses the msi.dll API while the
VBS uses the dispatch COM interface. And the EXE
is more "robust" if you need to do something like
unpack a 1 GB installer with 18 CABs.)


Sure, I can spend a couple months learning it, but when I installed ORCA
I was hoping I'd get the main gist of it inside of an hour lol.

It also helps to get the MSI CHM, which is quite
good. It even has a tutorial on what they call
WQL. (Windows QL, a subset of SQL.)


I think there's a link to that on your website?

But for every rule in an MSI there's also an
exception. There are lots of cases where "such
and such works this way *if* the other thing is true".

I've also had to update my code periodically
after finding faulty MSIs that nevertheless
worked to run an install. (That's in the update
notes. One was from an MS MVP. Another was
from Microsoft themselves!)


Oh of course, they constantly break their own rules...

The closest thing to a script, in a normal install,
is the InstallExecuteSequence table. The steps are
done in numeric order from the Sequence column.
(The numbers are meaningless except as and
values. It could be steps 1,2,3 but people usually
like to get mysterious and name the first step, say,
1500 with the next step being 3600... just to mess
with you.


I'll have a look at that.

The LaunchConditions table is where the install
might be restricted from running under certain
conditions.


Not sure I've ever needed to mod this, we usually just enable
"compatibility mode" and that gets us through the install...

But most of it is just very poorly organized details
about actually doing the install.

| You can build MSI's with plain old Windows? No extra tool needed? I
| tried an eval version of one of the most well-known/advanced MSI Builder
| tool (I can't find the name, something that costs plenty of dollars) and
| also quickly gave up ;-)
|

Maybe InstallShield?


Maybe, I can't remember which it was but it was really expensive...

Yes, you can build your own MSIs. It's all in msi.dll.
I just created a database to store my old email recently.
(It's available on the scripts page.) It stores them
all in an MSI, with extensive search capability.


Yeah, I saw that on your page ;-)

But if you want to build one to actually install
software... the problem is not being able to do it
but rather getting the hang of that vast system
of interconnected tables. And that's only for a vanilla
installer. If you want something a bit more spicy
then you have to embed custom actions.... Which
explains why companies like InstallShield can charge
so much. That's probably also another reason why
MS made the whole thing so unusable.


I really don't know why it's so complicated, but I was unable to find an
open-source MSI install package generator when I looked (but there are
many regular EXE installer generators).

I always use my own installer. When Microsoft sold
VB6, it came with the source code of the installer
they provided. I trimmed that down to make my own.
It's handy because it's not only simple and clean but
also allows for easy customizing of the UI. Though my
installer doesn't have the extras needed to do something
like install an office suite across a network, run an
updater/spyware on completion, or any of the other
fancy stuff that installers can do these days. Mine
is only for basic desktop software installs.

| Yeah, lots of MSIs unpack to a single slightly smaller EXE installer,
| lol. But MSIs are nice because you can push those through Group Policy.
| And there's software registration too - you can query MSI installed
| stuff via WMI, ask it to uninstall itself remotely via WinRM, etc.

Exactly. Many companies don't want to bother with the
mess, but they have to pack inside an MSI if they want
to sell to corporate customers with cranky IT people.


Lol, I wouldn't say Cranky. Plus, there are many complex business
software that don't use MSI and that are a REAL pain to install; but
since they do something critical to businesses, they put up with it...

Regards,

--
! _\|/_ Sylvain /
! (o o) Memberavid-Suzuki-Fdn/EFF/Red+Cross/SPCA/Planetary-Society
oO-( )-Oo LISP: Lots of insignificant single parentheses.

  #134  
Old March 24th 18, 01:36 PM posted to alt.windows7.general
Mayayana
external usenet poster
 
Posts: 6,438
Default Positioning the Windows Explorer windows

"B00ze" wrote

| But 7-Zip doesn't actually understand the format.

| Lol, I went to your site, that's exactly what you say ;-)
|

It's weird the way people will only trust things they
know and not think for themselves. As I mentioned there,
even wikipedia and installsite say 7-Zip works. There are
a surprising number of people who don't understand MSIs
but are happy to pass on that misinformation.... apparently
including the author of 7-Zip. His program is very good
and I use it for a number of things. And it's OSS. And
it's well known. But that doesn't make it capable of
slicing bread.
I guess that's what make Coke, Pepsi, Miller and Bud
so popular: It doesn't have to be good for you or even
taste good to be a big seller. It just has to be on TV,
because people prefer to trust TV over their own
perceptions. Likewise, people want to use the software
that everyone else uses. (Adobe have built an empire
on that insecurity.)

| Well, there's the InstallExecuteSequence table (and the
| adminInstallSequence). Unpacking the CAB with no paths is mostly
| useless, but sometimes there is no adminInstallSequence, so that to do?
|

Sometimes there's no admin install. It's not required.
That's intended for network installs, where the files
are unpacked in a way that remote users can install
a copy.
That's another common misconception. Many people
think that an admin install command line is the same
as unpacking the installer. It's different, it's not
always possible, and it requires admin authority.

| I think it's important to remember that while
| Microsoft's #1 product is monopoly maintenance and
| software is probably at #2 or #3, the manufacture
| of abstruseness is also one of their top products.
| It supports an entire industry of programmers,
| instructors, and people with trumped up titles
| like "MVP". Exactly analogous to the bizarre number
| of years that plumbers have to work as helpers
| and doctors have to spend in school: The harder it is
| to break in, the more money one can charge.
|
| I'm not sure that they do it on purpose, but they do end-up with
| everything being extra complicated

I imagine it's probably a combination of things:

* A desire to fabricate abstruseness for business reasons.

* Decisions made by committee.

* An engineer's OCD-esque obsession with quasi-precision.

(I say quasi not because they tend to be imprecise but
because they insist on applying precision to all things,
whether relevant or not.
I once did a job for a computer engineer who wanted me
to caulk between his bathroom sink and it's pedestal. I
explained that such things don't need caulking. He literally
had a tantrum. Probably an engineer friend had told him
that he'd heard it should be caulked to avoid phlogiston
leaks, or some such. So I caulked the sink. It did no harm.
And he was an engineer, after all, while I was just a
dumbass contractor. There was no sense trying to talk
logically with him. Logic is the god of engineers, not the
tool.)

But I agree. It's not always a "whackjob creation".
The original MSI SDK CAB actually had real file names,
except where it needed to differentiate between 32
and 64.

| It also helps to get the MSI CHM, which is quite
| good. It even has a tutorial on what they call
| WQL. (Windows QL, a subset of SQL.)
|
| I think there's a link to that on your website?
|

Woops. I need to update that. Both of those links
are dead now. Microsoft have broken all links to virtually
all SDK and doc files. One now has to download the entire
Win32 SDK to get them. This came up recently in the
Win10 group. All help files are now in the SDK only, and
they're all HXS files, which require a special reader.

I'm reposting the steps below to download that mess,
get the HXS files out of it, and convert them to usable
CHMs. (You can just install the SDK if you're on a
supported system, but it's very, very big, and most people
will have no interest in most of it.)

| I really don't know why it's so complicated, but I was unable to find an
| open-source MSI install package generator when I looked (but there are
| many regular EXE installer generators).
|

It's Windows-only, so not likely to inspire OSS. There
is a pun-infested package from MS call "Wix". (It
contains files like "heat", "smoke", and "soot". Get it?

Wix is a package for building MSIs. Personally I found
it more opaque than working with msi.dll directly. And it
seems to be commandline. As far as I'm concerned, if
they can't bother to make a GUI then I can't bother to
waste my time in console windows.

I doubt Wix would be useful for unpacking or editing
MSIs. It's meant for building installers. But if you want
to use it for that it might be worth a look.

http://wixtoolset.org/

| Exactly. Many companies don't want to bother with the
| mess, but they have to pack inside an MSI if they want
| to sell to corporate customers with cranky IT people.
|
| Lol, I wouldn't say Cranky. Plus, there are many complex business
| software that don't use MSI and that are a REAL pain to install; but
| since they do something critical to businesses, they put up with it...

I say cranky semi-joking. But I think that is a
real factor. Most IT people don't really know
Windows all that well. Their business is to run
scripts. Someone gives them a WMI script to do
software inventories periodically, and they expect
that to do their work for them. But WMI software
inventory is only going to work with MSI installs,
because it's all designed to work together to provide
documentation. So the IT people want MSI installers.

I get searches at my site, probably a handful per
week, from people looking for scripts to list
installed software *and* last used date. Only IT
people would care about such a stat, but for them
it's an important part of their job.

---------------------------------
Here's the details about getting the MSI CHM.
Also useful for anyone who wants any help files:
WMI, MSI, IE, DHTML, WSH, shell, active accessibility, etc.
---------------------------------

1)
This link should work to get the real ISO of the Win7 SDK
rather than a nonsense "web installer" link:

https://download.microsoft.com/downl...SDK_EN_DVD.iso

Otherwise, try this and make sure you get the
X86 version:

https://www.microsoft.com/en-us/down....aspx?id=18950

2)
Open the ISO using 7-Zip. Inside the Setup\WinSDKDocWin32
folder, take out cab5.cab. Inside that, find and extract this file:

WinSDK_Msi_hxs_63E4AB21_6DAC_4A1C_A24C_25B77BC5DA1 0_x86

(A good example of the file names. It could have been msi.hxs,
but nooooooooooo. It needed a GUID for good measure. The
"Win32SDK" and "x86 and numerous "_" marks are *pure*
superfluousness.

3)
Go here to get the HXS to CHM converter:

https://www.jsware.net/jsware/hxs2chm.php5

(You'll also need to download Microsoft's free
HTML Help Workshop.)

4)
With that you can get yourself a WMI CHM reference that
includes all methods, classes, etc. The HXS to CHM converter
might require a bit of setup -- it needs the help workshop
and 7-Zip paths to work -- but once set up the conversion
is basically a 1-click operation.

Anyone who wants other docs might want to convert
the whole shebang: Extract all 6 CABs from the help folder
and use the converter to convert them all to CHM in one
shot. Then you get Windows Script Host, IE DOM, shell....
pretty much anything that MS has docs for -- which takes
forever to look up online -- has a corresponding help file.

With that you end up with full, accessible, local help,
but without the gargantuan bloat of a full Windows SDK
installation, and without the help files being limited
in terms of how you can read them. All Windows versions
support CHM help files as a native format.




  #135  
Old March 28th 18, 04:31 AM posted to alt.windows7.general
B00ze
external usenet poster
 
Posts: 472
Default Positioning the Windows Explorer windows

On 2018-03-24 09:36, Mayayana wrote:

"B00ze" wrote

| But 7-Zip doesn't actually understand the format.

| Lol, I went to your site, that's exactly what you say ;-)
|

It's weird the way people will only trust things they
know and not think for themselves. As I mentioned there,
even wikipedia and installsite say 7-Zip works. There are
a surprising number of people who don't understand MSIs
but are happy to pass on that misinformation.... apparently
including the author of 7-Zip. His program is very good
and I use it for a number of things. And it's OSS. And
it's well known. But that doesn't make it capable of
slicing bread.


Well, it does manage to extra what's in the CAB relatively often, so if
all you need is that .INF and .SYS driver, 7-Zip is sufficient. People
use it I guess because they have it already, since LZMA is pretty good
(I wonder how it compares to LZX.)

I guess that's what make Coke, Pepsi, Miller and Bud
so popular: It doesn't have to be good for you or even
taste good to be a big seller. It just has to be on TV,
because people prefer to trust TV over their own
perceptions. Likewise, people want to use the software
that everyone else uses. (Adobe have built an empire
on that insecurity.)


That is true, people will use what other people tell them is good, but I
do that too lol. I am using Calibre for storing and reading eBooks
because people here told me it was the best thing. I tested it out and
found it did lots of stuff I found useful. Doesn't mean I use only that;
I've got some eBook datatypes tied to Sumatra, but some are tied to the
Calibre reader and I use Calibre as a library manager. Oh and I drink
better beer than that (Leffe as a kind of Mass-market beer,
micro-brewery beers otherwise.)

| Well, there's the InstallExecuteSequence table (and the
| adminInstallSequence). Unpacking the CAB with no paths is mostly
| useless, but sometimes there is no adminInstallSequence, so that to do?
|

Sometimes there's no admin install. It's not required.
That's intended for network installs, where the files
are unpacked in a way that remote users can install
a copy.


Yeah, it's annoying when it's not there and you need just a portion of
the installer...

That's another common misconception. Many people
think that an admin install command line is the same
as unpacking the installer. It's different, it's not
always possible, and it requires admin authority.


I didn't quite know if was a completely different table/sequence until
you told me though, I just knew it sometimes did not work and I did not
know why. When you said Admin-Install-Sequence I got it right away.

| I think it's important to remember that while
| Microsoft's #1 product is monopoly maintenance and
| software is probably at #2 or #3, the manufacture
| of abstruseness is also one of their top products.
| It supports an entire industry of programmers,
| instructors, and people with trumped up titles
| like "MVP". Exactly analogous to the bizarre number
| of years that plumbers have to work as helpers
| and doctors have to spend in school: The harder it is
| to break in, the more money one can charge.
|
| I'm not sure that they do it on purpose, but they do end-up with
| everything being extra complicated

I imagine it's probably a combination of things:

* A desire to fabricate abstruseness for business reasons.
* Decisions made by committee.
* An engineer's OCD-esque obsession with quasi-precision.


They want to tie everything to Windows and to their other products, so
they will always try to re-use everything they can, so that's part of
the reason why everything they do requires some other Microsoft thing to
work. Why it's all super complicated I'm not sure, maybe they think
ahead: "how can we make sure we're going to re-use this in 10 other
products?" Yeah, decisions made by committee is probably a big driver of
complexity.

(I say quasi not because they tend to be imprecise but
because they insist on applying precision to all things,
whether relevant or not.


I once did a job for a computer engineer who wanted me
to caulk between his bathroom sink and it's pedestal. I
explained that such things don't need caulking. He literally
had a tantrum. Probably an engineer friend had told him
that he'd heard it should be caulked to avoid phlogiston
leaks, or some such. So I caulked the sink. It did no harm.
And he was an engineer, after all, while I was just a
dumbass contractor. There was no sense trying to talk
logically with him. Logic is the god of engineers, not the
tool.)


Lol, phlogiston leaks! Maybe he just wanted it really "solid" you know,
glue everything down. Things lasted a lot longer back when the world did
not engineer everything to remove the slightest unnecessary gram of
material, when you'd go "alright just make it twice as thick so we're
covered" instead of testing everything and making decisions solely based
on those tests. He might've been in that 60's mood: Glue it all down.

But I agree. It's not always a "whackjob creation".
The original MSI SDK CAB actually had real file names,
except where it needed to differentiate between 32
and 64.

| It also helps to get the MSI CHM, which is quite
| good. It even has a tutorial on what they call
| WQL. (Windows QL, a subset of SQL.)
|
| I think there's a link to that on your website?

Woops. I need to update that. Both of those links
are dead now. Microsoft have broken all links to virtually
all SDK and doc files. One now has to download the entire
Win32 SDK to get them. This came up recently in the
Win10 group. All help files are now in the SDK only, and
they're all HXS files, which require a special reader.


I already have the Win 7.1 SDK, but I have not installed it all.

I'm reposting the steps below to download that mess,
get the HXS files out of it, and convert them to usable
CHMs. (You can just install the SDK if you're on a
supported system, but it's very, very big, and most people
will have no interest in most of it.)

| I really don't know why it's so complicated, but I was unable to find an
| open-source MSI install package generator when I looked (but there are
| many regular EXE installer generators).

It's Windows-only, so not likely to inspire OSS. There
is a pun-infested package from MS call "Wix". (It
contains files like "heat", "smoke", and "soot". Get it?

Wix is a package for building MSIs. Personally I found
it more opaque than working with msi.dll directly. And it
seems to be commandline. As far as I'm concerned, if
they can't bother to make a GUI then I can't bother to
waste my time in console windows.


lol, I -was- kinda hoping for a GUI, but something simple you know,
something you could script with and let it build the MSI for you, so as
to hide completely the mess underneath. And of course, more importantly,
something that could take an existing MSI and present it the same way...

I doubt Wix would be useful for unpacking or editing
MSIs. It's meant for building installers. But if you want
to use it for that it might be worth a look.

http://wixtoolset.org/


Wow, I read the first few chapters of the tutorial, it's much better
than editing a thousand tables! All you need is an XML file. I don't
really like XML as I don't have a good XML editor, but I guess Notepad++
could do (I still use UltraEdit v7, like from 20 years ago.) Too bad I'm
not really looking to build MSIs at the moment; however I may read the
entire thing just to learn about MSI's ;-) Plus it could be a good skill
to have, to package stuff that otherwise does not register in WMI, like
adding an Icon to a user's desktop via SCCM...

| Exactly. Many companies don't want to bother with the
| mess, but they have to pack inside an MSI if they want
| to sell to corporate customers with cranky IT people.
|
| Lol, I wouldn't say Cranky. Plus, there are many complex business
| software that don't use MSI and that are a REAL pain to install; but
| since they do something critical to businesses, they put up with it...

I say cranky semi-joking. But I think that is a
real factor. Most IT people don't really know
Windows all that well. Their business is to run


I'm kinda like that, I programmed on mainframes before (not anymore) and
other architectures, but never Windows. To learn how Windows really
works you need to be coding FOR Windows. What I do now is scripts lol;
started on PowerShell recently but only made the one script to date, I
haven't needed much more so far...

scripts. Someone gives them a WMI script to do
software inventories periodically, and they expect
that to do their work for them. But WMI software
inventory is only going to work with MSI installs,
because it's all designed to work together to provide
documentation. So the IT people want MSI installers.


Lol, for me so long as SCCM can inventory it, I'm happy ;-) WIX looks
good for that - package stuff that doesn't normally register...

I get searches at my site, probably a handful per
week, from people looking for scripts to list
installed software *and* last used date. Only IT
people would care about such a stat, but for them
it's an important part of their job.


---------------------------------
Here's the details about getting the MSI CHM.
Also useful for anyone who wants any help files:
WMI, MSI, IE, DHTML, WSH, shell, active accessibility, etc.
---------------------------------

1)
This link should work to get the real ISO of the Win7 SDK
rather than a nonsense "web installer" link:

https://download.microsoft.com/downl...SDK_EN_DVD.iso


Funny, I have the SDK 7.1 already (GRMSDK) from which I have installed
the tools, but I do not see a WinSDKDoc folder. Plus, when I run it to
see what check-boxes I can tick, it complains that I don't have .NET 4,
says I have a pre-release NET framework (and one more Microsoft thing
broken by Microsoft.) Downloading your linked ISO now. Ahhh, it's the
7.0 (NET35) SDK, somehow much bigger than the 7.1 one...

Open the ISO using 7-Zip. Inside the Setup\WinSDKDocWin32
folder, take out cab5.cab. Inside that, find and extract this file:
WinSDK_Msi_hxs_63E4AB21_6DAC_4A1C_A24C_25B77BC5DA1 0_x86


I see it...

(A good example of the file names. It could have been msi.hxs,
but nooooooooooo. It needed a GUID for good measure.


;-)

Go here to get the HXS to CHM converter:
https://www.jsware.net/jsware/hxs2chm.php5
(You'll also need to download Microsoft's free
HTML Help Workshop.)


Funny, I had HTML Help Workshop, but did not find I really needed it so
I got rid of the installer. I've downloaded it again. Sadly, it is now
time to go to bed, so I'll follow-up with this later. Your webpage is of
course hilarious lol: Of course they HAD to XMLify the help, they
XMLified everything else! You think there's a HXS reader in the free
Visual Studio Community? (or whatever name the free one calls itself
these days) I wanted to get it, but each time I go there, there's like
10 different versions and I never know which one to get (Ah, I think
it's called VS-Code now, and there's only this 1 version).

With that you can get yourself a WMI CHM reference that
includes all methods, classes, etc. The HXS to CHM converter
might require a bit of setup -- it needs the help workshop
and 7-Zip paths to work -- but once set up the conversion
is basically a 1-click operation.


Yeah, the HTA looks good, plus you've got a script to create an unpacked
version which is pretty neat...

Anyone who wants other docs might want to convert
the whole shebang: Extract all 6 CABs from the help folder
and use the converter to convert them all to CHM in one
shot. Then you get Windows Script Host, IE DOM, shell....
pretty much anything that MS has docs for -- which takes
forever to look up online -- has a corresponding help file.


I wonder if I should just run the installer in that folder and let it
install it all, so I get neat little icons with human readable names for
all the docs - I can convert afterwards and unInstall when I'm all done...

With that you end up with full, accessible, local help,
but without the gargantuan bloat of a full Windows SDK
installation, and without the help files being limited
in terms of how you can read them. All Windows versions
support CHM help files as a native format.


Thanks!

--
! _\|/_ Sylvain /
! (o o) Memberavid-Suzuki-Fdn/EFF/Red+Cross/SPCA/Planetary-Society
oO-( )-Oo Gravity is a myth The earth sucks.

 




Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off






All times are GMT +1. The time now is 06:23 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 PCbanter.
The comments are property of their posters.