![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | getDetailsOf method does not work Hi, i wrote a module-function (VBA) using method GetDetailsOf(): Set FSO = CreateObject("Scripting.FileSystemObject") If FSO.FileExists(filePath) Then strParent = FSO.GetParentFolderName(filePath) strArgFileName = FSO.GetFileName(filePath) With CreateObject("Shell.Application").Namespace(strParent) Picturedimensions = .GetDetailsOf(.ParseName(strArgFileName), 26) End With End If Set FSO = Nothing GetDetailsOf returns (don't know why) empty string. Antivir checked, firewall checked, path and references also... and no idea Here is quite a solution to similar case but it does not work: http://209.85.229.132/search?q=cache...&ct=clnk&gl=pl regards |
My System Specs![]() |
| | #2 (permalink) |
| | Re: getDetailsOf method does not work This group is VBScript rather than VBA but your code is more or less agnostic between the two. I would get rid of the 'With part' and use full references and smaller steps. Then see what you have at each stage. For example: Dim item Set item = CreateObject("Shell.Application").Namespace(strParent) Now examine item in the debugger to see if it's what you expect. -- Joe Fawcett (MVP - XML) http://joe.fawcett.name "God Itself" <god@xxxxxx> wrote in message news:gqiade$bt3$1@xxxxxx Quote: > Hi, > > i wrote a module-function (VBA) using method GetDetailsOf(): > > Set FSO = CreateObject("Scripting.FileSystemObject") > > If FSO.FileExists(filePath) Then > > strParent = FSO.GetParentFolderName(filePath) > strArgFileName = FSO.GetFileName(filePath) > > With CreateObject("Shell.Application").Namespace(strParent) > Picturedimensions = .GetDetailsOf(.ParseName(strArgFileName), 26) > End With > > End If > > Set FSO = Nothing > > GetDetailsOf returns (don't know why) empty string. > > Antivir checked, firewall checked, path and references also... and no idea > > Here is quite a solution to similar case but it does not work: > http://209.85.229.132/search?q=cache...&ct=clnk&gl=pl > > regards |
My System Specs![]() |
| | #3 (permalink) |
| | Re: getDetailsOf method does not work Hi, i know that code is written in VBA (not in VBS) but the problem is not the syntax but reference to function GetDetailsOf there is "something" in my system what blocks this function. GetDetailsOf(,26) returns empty string instead i.e. "450 x 650". I have no idea what it can be... regards Użytkownik "Joe Fawcett" <joefawcett@xxxxxx> napisał w wiadomości news:uyKV9atrJHA.4592@xxxxxx Quote: > This group is VBScript rather than VBA but your code is more or less > agnostic between the two. > I would get rid of the 'With part' and use full references and smaller > steps. Then see what you have at each stage. > For example: > Dim item > Set item = CreateObject("Shell.Application").Namespace(strParent) > > Now examine item in the debugger to see if it's what you expect. > > -- > > Joe Fawcett (MVP - XML) > http://joe.fawcett.name > > > "God Itself" <god@xxxxxx> wrote in message > news:gqiade$bt3$1@xxxxxx Quote: >> Hi, >> >> i wrote a module-function (VBA) using method GetDetailsOf(): >> >> Set FSO = CreateObject("Scripting.FileSystemObject") >> >> If FSO.FileExists(filePath) Then >> >> strParent = FSO.GetParentFolderName(filePath) >> strArgFileName = FSO.GetFileName(filePath) >> >> With CreateObject("Shell.Application").Namespace(strParent) >> Picturedimensions = .GetDetailsOf(.ParseName(strArgFileName), 26) >> End With >> >> End If >> >> Set FSO = Nothing >> >> GetDetailsOf returns (don't know why) empty string. >> >> Antivir checked, firewall checked, path and references also... and no idea >> >> Here is quite a solution to similar case but it does not work: >> http://209.85.229.132/search?q=cache...&ct=clnk&gl=pl >> >> regards > > |
My System Specs![]() |
| | #4 (permalink) |
| | Re: getDetailsOf method does not work "God Itself" <god@xxxxxx> wrote in message news:gqii98$ne8$1@xxxxxx Hi, i know that code is written in VBA (not in VBS) but the problem is not the syntax but reference to function GetDetailsOf there is "something" in my system what blocks this function. GetDetailsOf(,26) returns empty string instead i.e. "450 x 650". I have no idea what it can be... regards Uzytkownik "Joe Fawcett" <joefawcett@xxxxxx> napisal w wiadomosci news:uyKV9atrJHA.4592@xxxxxx Quote: > This group is VBScript rather than VBA but your code is more or less > agnostic between the two. > I would get rid of the 'With part' and use full references and smaller > steps. Then see what you have at each stage. > For example: > Dim item > Set item = CreateObject("Shell.Application").Namespace(strParent) > > Now examine item in the debugger to see if it's what you expect. > > -- > > Joe Fawcett (MVP - XML) > http://joe.fawcett.name > > > "God Itself" <god@xxxxxx> wrote in message > news:gqiade$bt3$1@xxxxxx Quote: >> Hi, >> >> i wrote a module-function (VBA) using method GetDetailsOf(): >> >> Set FSO = CreateObject("Scripting.FileSystemObject") >> >> If FSO.FileExists(filePath) Then >> >> strParent = FSO.GetParentFolderName(filePath) >> strArgFileName = FSO.GetFileName(filePath) >> >> With CreateObject("Shell.Application").Namespace(strParent) >> Picturedimensions = .GetDetailsOf(.ParseName(strArgFileName), 26) >> End With >> >> End If >> >> Set FSO = Nothing >> >> GetDetailsOf returns (don't know why) empty string. >> >> Antivir checked, firewall checked, path and references also... and no >> idea >> >> Here is quite a solution to similar case but it does not work: >> http://209.85.229.132/search?q=cache...&ct=clnk&gl=pl >> >> regards (index 26). I tried several files(*.jpg, *.bmp, and others). I don't know why. -- Richard Mueller MVP Directory Services Hilltop Lab - http://www.rlmueller.net -- |
My System Specs![]() |
| | #5 (permalink) |
| | Re: getDetailsOf method does not work Hi, pls check this: http://209.85.229.132/search?q=cache...&ct=clnk&gl=pl there is solution to add a DWORD to shell extensions, but it doesn't work in my case. Empty string may be also result of windows update no 908531 anyway pls paste code from my first post to VBA in excel and call this function to receive dimensions. This is only a way to check whether GetDetailsOf work proprietly. i hove you use windows XP.. (,26) returns dimensions only in this windows! Now, i'm at work and this function works fine, but at home i have problem with this! regards Użytkownik "Richard Mueller [MVP]" <rlmueller-nospam@xxxxxx> napisał w wiadomości news:%23bSlVNurJHA.4684@xxxxxx Quote: > > "God Itself" <god@xxxxxx> wrote in message > news:gqii98$ne8$1@xxxxxx > Hi, > > i know that code is written in VBA (not in VBS) but the problem is not the > syntax but reference to function GetDetailsOf > > there is "something" in my system what blocks this function. > GetDetailsOf(,26) returns empty string instead i.e. "450 x 650". I have no > idea what it can be... I also get an empty string when I use GetDetailsOf to retrieve "Dimensions" (index 26). I tried several files(*.jpg, *.bmp, and others). I don't know why. |
My System Specs![]() |
| | #6 (permalink) |
| | Re: getDetailsOf method does not work "Richard Mueller [MVP]" <rlmueller-nospam@xxxxxx> wrote in message news:%23bSlVNurJHA.4684@xxxxxx Quote: > > "God Itself" <god@xxxxxx> wrote in message > news:gqii98$ne8$1@xxxxxx > Hi, > > i know that code is written in VBA (not in VBS) but the problem is not the > syntax but reference to function GetDetailsOf > > there is "something" in my system what blocks this function. > GetDetailsOf(,26) returns empty string instead i.e. "450 x 650". I have no > idea what it can be... > > regards > > Uzytkownik "Joe Fawcett" <joefawcett@xxxxxx> napisal w > wiadomosci news:uyKV9atrJHA.4592@xxxxxx Quote: >> This group is VBScript rather than VBA but your code is more or less >> agnostic between the two. >> I would get rid of the 'With part' and use full references and smaller >> steps. Then see what you have at each stage. >> For example: >> Dim item >> Set item = CreateObject("Shell.Application").Namespace(strParent) >> >> Now examine item in the debugger to see if it's what you expect. >> >> -- >> >> Joe Fawcett (MVP - XML) >> http://joe.fawcett.name >> >> >> "God Itself" <god@xxxxxx> wrote in message >> news:gqiade$bt3$1@xxxxxx Quote: >>> Hi, >>> >>> i wrote a module-function (VBA) using method GetDetailsOf(): >>> >>> Set FSO = CreateObject("Scripting.FileSystemObject") >>> >>> If FSO.FileExists(filePath) Then >>> >>> strParent = FSO.GetParentFolderName(filePath) >>> strArgFileName = FSO.GetFileName(filePath) >>> >>> With CreateObject("Shell.Application").Namespace(strParent) >>> Picturedimensions = .GetDetailsOf(.ParseName(strArgFileName), 26) >>> End With >>> >>> End If >>> >>> Set FSO = Nothing >>> >>> GetDetailsOf returns (don't know why) empty string. >>> >>> Antivir checked, firewall checked, path and references also... and no >>> idea >>> >>> Here is quite a solution to similar case but it does not work: >>> http://209.85.229.132/search?q=cache...&ct=clnk&gl=pl >>> >>> regards > I also get an empty string when I use GetDetailsOf to retrieve > "Dimensions" (index 26). I tried several files(*.jpg, *.bmp, and others). > I don't know why. > > -- > Richard Mueller > MVP Directory Services > Hilltop Lab - http://www.rlmueller.net > -- > not on Windows 2000. -- Richard Mueller MVP Directory Services Hilltop Lab - http://www.rlmueller.net -- |
My System Specs![]() |
| | #7 (permalink) |
| | Re: getDetailsOf method does not work Użytkownik "Richard Mueller [MVP]" <rlmueller-nospam@xxxxxx> napisał w wiadomości news:Ofic5lurJHA.1504@xxxxxx Quote: > If find the code works on Windows Server 2003 and XP, but not on Vista. Also > not on Windows 2000. |
My System Specs![]() |
| | #8 (permalink) |
| win2k, winxp, vista home premium x32 | Re: getDetailsOf method does not work What you wrote is for Windows XP. The GetDetailsOf() method you used is OS dependent & not compatible with Vista. |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| Passing "| find" in command executed with EXEC method does not work | VB Script | |||
| .ToLower() method doesn't work! | PowerShell | |||
| .ToLower() method doesn't work! | VB Script | |||
| method not many | Vista mail | |||
| Method invocation failed because [System.String] doesn't contain a method | PowerShell | |||