Link to home
Start Free TrialLog in
Avatar of Dazm
Dazm

asked on

Windows directory


I would like to know in what directory each program is installed.

Yahoo! Messenger for example:
In Windows xp the default directory is C:\Program Files\...

In Windows 98 and  Windows Me, is the same directory.

Windows 98    "C:\Program Files\Yahoo!\Messenger"
Windows Me   "C:\Program Files\Yahoo!\Messenger"
Windows xp    "C:\Program Files\Yahoo!\Messenger"

But what about  Windows NT,  Windows 2000 and  Windows Server 2003 ?
Avatar of cschipper
cschipper

NT, 2000 and 2003 have als a program files folder
they are in the same place as XP afaik
Avatar of Chris Phillips
Check the registry key under HKLM\Software\Microsoft\Windows\CurrentVersion.

This has the location of Program Files and Common Files
Usually program files are installed in the %programfiles% directory. Where %programfiles% is an variable which usually points to C:\Program Files, although it is possible that it points to another (localized) directory or a specialized platform-dependent directory.

On the 64-bit versions of Windows, this folder is called C:\Program Files (x86) as the default C:\Program Files is reserved for 64 bit programs. Because of the %programfiles% variable, most 32 bit programs will point to the C:\Program Files (x86) folder by default.
Avatar of Dazm

ASKER


cschipper and acstua,
I don't know about that...
Thats right am asking this question.

All i know is that Windows 2000 does not have the same directory

Like a year ago i made a tool for a friend who had Windows 2000
He told me that my tool never work on his computer, Then i realize
that it may be for the directory => "C:\Program Files\Yahoo!\Messenger"

Now for chris_bol...
I am not running Windows 2000 at this time.

To make it a little more understandable...
All i need to know is the location of Yahoo! in Windows 2000.
going by this post https://www.experts-exchange.com/questions/21847105/Yahoo-Messenger-Script-errors.html
it would seem its still under program files
tho like - c:\program files\yahoo messenger\messenger\profiles

ill let yer know if i found out for sure, i did have a win2k machine about somewhere :)
Dazm.
Am I correct in thinking that your question is related in a way to your Visual Basic question here?:
https://www.experts-exchange.com/questions/21851760/Run-app-with-a-specific-version.html

In that question you are apparently trying to have an application (or installer) perform an operating system verification check before running (or installing), and in this question here you appear to be looking for a method of checking to see whether a program is already installed ie. by checking in the "Program Files" folder.

If that IS the case, then you would need to either check for the existence of the program's executable, or check the registry key:
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall
for the known sub-key created by a previous installation of that program, and then perhaps also check the values set against "DisplayName" and/or "DisplayVersion".

If this isn't what you are seeking to do, then just ignore this.

Avatar of Dazm

ASKER


acstua...
if "sunnycoder" was under Windows 2000...
Why did he had problems in finding that directory ?
Yahoo! Messenger is in a different directory in Windows 2000
Thats right he post this message => sunnycoder: No luck :-(
Oops! Well i don't know yet if Yahoo! is in that directory in Windows 2000

Comment from moh10ly

The Folder looks like this..
c:\program files\yahoo messenger\messenger\profiles

Comment from sunnycoder

No luck :-(


Nor for BillDL...
The other question sounds a little similar to this
But is totally different because this time is about
JavaScript on load page, so I need to know the right
directory of Yahoo! Mesenger thats all.
But it has nothing to do with the other question.

Thanks for your opinion BillDL, But yeah this is something different.
only saying what i found :)

Tried to install it on my w2k box, but msgr wouldnt even download :/
will try tomorrow if you want.
It would have been nice if you were clear that you needed the Yahoo! folder only. Because Yahoo Messenger can be anywhere on the system. If you want it to be in Z:\MyPrograms\Messaging\Yahoo, it's possible!

There's no way you can tell where it is, except when checking the registry-info or reading information from the .lnk files in the startmenu and desktop (which can be on a different location as well)

In my machine running XP pro 64-bit I could find the Yahoo installation directory in HKLM\Software\Wow6432Node\Yahoo\Essentials.
Avatar of Dazm

ASKER


Thanks acstua : )
it will be nice if you do that
I will apreciate, Thank you.


RiDo78...
Yeah, is true what you say...
But normally all users install Yahoo! Messenger in the default folder => C:\Program Files\...

at the time Yahoo! start the installation nobody worry about change directory.
Yahoo!, MSN, AOL, PalTalk, these programs give the user the option to select a target directory, but like i said, 95% of all users install all programs as the default installation.


"at the time Yahoo! start the installation nobody worry about change directory.
Yahoo!, MSN, AOL, PalTalk, these programs give the user the option to select a target directory, but like i said, 95% of all users install all programs as the default installation."

Well if you take that for granted, I could say that Yahoo usually installs in %programfiles%\Yahoo!. As I said, the %programfiles% is substituted for the Program Files directory, regardless of the name. Try 'cd %programfiles' at the command prompt. Setup-programs also use this information to find the Program Files directory so if you assume that most users do not change the directory manually, you're done.
defaulted on mine to C:\Program Files\Yahoo!\Messenger
Avatar of Dazm

ASKER


Yesterday i was trying to investigate the Yahoo! root in one of my friends online,
He gives me permission to enter in his machine using net meeting... but he did not
had installed Yahoo! Messenger in his computer, and this is what i find.

C:\NTWIN\...

Now lets see the different in Windows xp

C:\Programs Files\...

C:\Windows\...
Avatar of Dazm

ASKER


For me is hard to believe that Windows 2000 have this root => C:\Program Files\Yahoo!\Messenger

I try this script with few users on Yahoo! Chat Rooms

<SCRIPT>
onload=window.open('file://C:/Program files/Yahoo!/Messenger')
</SCRIPT>

1.) Open Notepad and paste the script
2.) Save it as Root.html
3.) Open Root.html

Users with Windows 2000 said they didn't find anything
But users with Windows xp said YES!!! HAHAHAHAHAHA
Dazm

There are a few issues with your previous postings.

acstua looked for examples to support his belief that Yahoo Instant Messenger installed by default to a particular directory, and quoted the previously asked question by sunnycoder at:
https://www.experts-exchange.com/questions/21847105/Yahoo-Messenger-Script-errors.html

moh10ly suggested :
"Have you tried to move all your IM HISTORY to different Directory...?"
to which sunnycoder responded:
"Not sure which directory you are refering to. I could not find any directory named HISTORY in yahoo folder".

You later stated :
"If sunnycoder was under Windows 2000, why did he had problems in finding that directory?
Yahoo! Messenger is in a different directory in Windows 2000. Thats right he post this message => sunnycoder: No luck".

Look again at sunnycoder's feedback, and notice that he DOES appear to have the Yahoo program folder, but did not have a HISTORY folder.

acstua later downloaded and installed Yahoo Instant Messenger on a Windows 2000 system to double-check the default installation directory, and reported back :
"Defaulted on mine to C:\Program Files\Yahoo!\Messenger".

Why do you find it so unbelievable that Yahoo Instant Messenger installs to that folder? :
>>> "For me is hard to believe that Windows 2000 have this root => C:\Program Files\Yahoo!\Messenger". <<<

You stated "Yesterday I was trying to investigate the Yahoo! root in one of my friends online ... but he did not have Yahoo! Messenger installed in his computer".

Why not have your friend install YIM (presumably this is a Windows 2000 system you were talking about), and see what directory it installs to on that computer.

Don't forget that there are quite a few different Yahoo programs, utilities, and applications that can be installed on any computer, so the "root" (as you refer to it) really is:
C:\Program Files\Yahoo!\
or, more correctly (as stated by RiDo78):
%programfiles%\Yahoo!\

These will obviously create their own sub-folders, so keeping them all under the \Yahoo!\ folder makes sense, eg.

C:\Program Files/Yahoo!/Shared/
C:\Program Files/Yahoo!/Shared/Graphics
C:\Program Files\Yahoo!\Companion\
C:\Program Files\Yahoo!\Companion\Installs\
C:\Program Files\Yahoo!\Common\
C:\Program Files\Yahoo!\Messenger\
C:\Program Files\Yahoo!\Messenger\Skins
etc, etc.

Two examples of the C:\Program Files\Yahoo!\ folder being used as the program folder for Yahoo utilities after a quick search on google.  Both are HiJack This! logs that state in the header of the report:

Logfile of HijackThis vx.xx.x
Platform: Windows 2000 SP4 (WinNT 5.00.2195)

http://forum.starmen.net/?t=msg&th=13768&start=0
O3 - Toolbar: Yahoo! Companion - C:\Program Files\Yahoo!\Companion\Installs\etc, etc

http://www.dslreports.com/forum/remark%252C10526441~root=security~mode=flat
O8 - Yahoo! Dictionary - file:///C:\Program Files\Yahoo!\Common/ycdict.htm
O8 - Yahoo! Search - file:///C:\Program Files\Yahoo!\Common/ycsrch.htm

You will find such examples of the Yahoo program folder at C:\Program Files\Yahoo! quoted all over the internet in help/discussion forums, so it seems like a little more than mere coincidence that they all have Yahoo utilities installed to the same folder - even on a Polish version of Windows 2000:
http://komputery.katalogi.pl/temat61365/

You said that Windows 2000 users tried your script from an html document and that "they didn't find anything".
What exactly do you mean by "didn't find anything"?
If the folder didn't exist, I would have expected it to show a "Cannot Find Server or DNS Error" local page.  You can confirm this result using an obviously nonexistent directory in the script.

Perhaps the Windows 2000 users have tighter security concerning the running of scripts from within a web page?  In my experience, the average Windows 2000 user knows a lot more about security than the average Windows XP user hanging around in a Yahoo Chat Room, which might account for the result.
Well said BillDL...
Avatar of Dazm

ASKER


Four words...

I am not sure if give you the ok or not
Because i am not yet totally convinced.

Why my script doesn't load ok in those computers?
is it there a diference in Win2000 and WinNT?

Avatar of Dazm

ASKER


Oops! 36 words : )
Avatar of Dazm

ASKER


I feel like... I cannot accept this answer.

RiDo78: Well said BillDL...

I do not like to be hypocritical, cus if i click the Acept buttom
I'll make you velieve that this was the correct and finall answer.

But...

To be honest, I do not feel satisfied with the result of this answer.
Dazm
I'm not really sure what the problem is, but your question was what directory does Yahoo Instant Messenger install to on Windows NT,  Windows 2000 and  Windows Server 2003.
Admittedly, nobody has offered a conclusive answer yet with respect to Windows NT and Windows Server 2003, but acstua went to the bother of installing YIM on his Windows 2000 system for you and reported his findings.  There are several other references to other peoples' Windows 2000 systems with YIM installed to the same directory.

As far as I see it, the only way you would totally convince yourself of this is to install YIM yourself on a Windows 2000 system and check the results.  Before you do so, however, it might be wise to read this page from September 2005:
http://blog.taragana.com/index.php/archive/yahoo-venturing-into-adware-stay-away-from-yahoo-instant-messenger/

Ask those Windows 2000 users on the Yahoo chat room who previously reported that your script found nothing to open a command prompt window and type the command:
cd %programfiles%
Do theirs change directory to C:\Program Files\ or some other directory?

Listen, sometimes the answer is just 'not possible'. You can assign an B or C grade if you want... personally I don't care about the points. Especially not in a 20-point question. I can't talk for others, but I assume they think the same way. We're here to help, and that's what we're trying to do.

And I would like to give you some advice. Please be clear about your intentions as it really helps solving the problem. Take this question for example, we got information piece by piece. First you ask:
> "I would like to know in what directory EACH program is installed."
You do provide an yahoo example, but you ask for EACH program. Oh and you throw in some information about the location of yahoo on certain Operating Systems.

Later you make it more clear that you would like to know the differences in location on certain operating systems.

Another post later it became clear that you don't want to know the location of EACH program, but only Yahoo! Messenger.

Last not least you came up with some sort of javascript that should open the Yahoo program folder.


If you told us straight away that you were writing a javascript and you need to know the exact location of Yahoo!Messenger on any random machine, we could have saved quite some work. As it is generally not possible for javascript to access system-variables, so %programfiles% would fail. (You can enter it in your (i)explorer window manually if you want though). And registery-queries are out of the question for javascripts.

So if you want your script to work, you need to know the exact location of a folder to open it. And believe me, on ALL english windows-versions, the default location of program files is C:\PROGRAM FILES. Only the 64 bit versions have two  folders: C:\PROGRAM FILES (x86) for the 32-bit programs and C:\PROGRAM FILES, which is used for the native 64-bit software.

But be aware that the directory might have a different name on localized NON-english versions of Windows or where the administrator has forced a different name. IT IS ALSO POSSIBLE that securitysettings block your script, because you try to access the local system, which is *should* not be allowed for Javascripts.


I'm sorry to dissapoint you, but as far as I can see it is not possible to build a descent and reliable javascript. But try this instead:
===
%systemdrive%
cd %programfiles%\Yahoo!\Messenger
start .
===
Copy everything BETWEEN the === signs to notepad and save it as test.bat. Now run it
ASKER CERTIFIED SOLUTION
Avatar of BillDL
BillDL
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
aye ive got about 5 2k3 servers, but im not sticking yahoo on there :)

and ive lost the will to help much more here ;(
Avatar of Dazm

ASKER


Ok, Thanks acstua

Thank you BillDL

No tnx.
Thank you, Dazm.
Avatar of Dazm

ASKER


: (  RiDo78

You have no idea how much i appreciate you help
Is just that i have problems expressing my self : (

But yeah, i also want to thank you

Thank you Brother
Avatar of Dazm

ASKER


Do any of you know how can I delete this question?
I feel like this is a dumb question : (
Thank you guys.
There's no such thing really as a dumb question.
If you don't know the answer, and you don't have any immediately available way of finding something out, then you have to ask the question - even if it later LOOKS like it has been a dumb question.  When the answer to a question is relatively straightforward, then it can later make the question look as if it was a dumb one, even if at the time it wasn't.

Take a look at one of my questions and make up your own mind if it was a dumb one or not:
https://www.experts-exchange.com/questions/21137237/Start-Menu-not-folding-out-when-cursor-hung-over-it.html

I wouldn't worry too much about it though, because the question is now a PAQ (previously asked question), and in a few days no further comments will be able to be added to it.  It will be filed away on the server along with the other questions that thousands of other members later wished that they hadn't needed to ask.

Bill
Avatar of Dazm

ASKER


You right Bill...
But you know what?
I don't think you question was a dumb one...
I see that there was an immediate explanation about the solution.
And according with Ask and Google, you may be the first person with
that particular problem : )... So once again, Thanks for you opinion Bill

...And thanks to have helped me in my question.

Thank you Bill