Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
en-us names for ShellApp.GetDetailsOf columns, plz
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  1 message - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Alexander Mueller  
View profile  
 More options Oct 17 2009, 1:53 pm
Newsgroups: microsoft.public.scripting.wsh, microsoft.public.scripting.vbscript, microsoft.public.scripting.jscript
Followup-To: microsoft.public.scripting.wsh
From: Alexander Mueller <mille...@hotmail.com>
Date: Sat, 17 Oct 2009 15:53:35 +0200
Local: Sat, Oct 17 2009 1:53 pm
Subject: en-us names for ShellApp.GetDetailsOf columns, plz
Hi

The following script lists the names of detail
identifiers as returned by ShellApp.GetDetailsOf
for the MyVideo or MyDocuments Shell folder.

Since Shell automation returns the names in
localized manner, e.g. I get German names on my
German XP machine, I would like to ask, if s.o.
could be as kind as to run the script on his/her
English Windows machine, pipe the output to file
and copy the file's content into a reply to
this post

//------ GetDetailsNames.js
var sh = new ActiveXObject("Shell.Application");
var CSIDL_PERSONAL = 0x0005; // My Documents
var CSIDL_MYVIDEO = 0x000e; // "My Videos" folder

var ns = null;
if (null == (ns = GetFolder(CSIDL_MYVIDEO)))
        if (null == (ns = GetFolder(CSIDL_PERSONAL)))
                WSH.Quit();

WSH.Echo("Folder:", ns.Self.Path);
WSH.Echo("ID  => DETAIL-NAME");
for (var i = 0; i < 100; i++) {
        try {
                var name = ns.GetDetailsOf(null, i);
                if (typeof name == "string" && name.length > 0)
                        WSH.Echo( i, i <10 ? " ":"" ,"=>", name)
        }
        catch(ex) {
                WSH.Echo(i, ex.number, ex.description)
        }

};

function GetFolder(id) {
        try  {
                return sh.Namespace(id);
        }
        catch(ex)       {
                return null;
        }
}

//------ END GetDetailsNames.js

Btw you can redirect the output with the cmd-batch file
below

Thx very much for your help,
sorry for crossposting,
sorry for posting JS in m.p.s.vbscript,
Alex

//------ pipeNames.cmd
REM make sure pipeNames.cmd and GetDetailsNames.js
REM are locate din the same folder and that this folder is
REM is the active Directory of the CMD-prompt while running
REM this cmd-script

cmd /c cscript //NOLOGO .\GetDetailsNames.js > .\GetDetailsNames.txt

//------ END pipeNames.cmd


    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2010 Google