I found this example on MSDN for setting compression down to the folder level.

adsutil set w3svc/1/root/Home/StyleSheets/DoStaticCompression true

When I try something similar with

adsutil set
w3svc/1/root/MyWebSite/Subdirectory1/Subdirectory2/DoDynamicCompression true

I get an error message of "The path requested could not be found.
ErrNumber: -2147024893 (0x80070003)" Should I not be able to specify down to
one folder which files I want to be dynamically compressed? The deepest
level I can get to work is

adsutil set w3svc/1/root/MyWebSite/DoDynamicCompression true

Re: Problem setting IIS compression down to folder by Kristofer

Kristofer
Tue May 30 13:52:31 CDT 2006

Hello,

DoStaticCompression can be set on a IIsWebVirtualDir or IIsWebDirectory
according to the documentation. What i think, based on the error message
you get, is that /Subdirectory1/Subdirectory2/ is neither an
IIsWebVirtualDir nor IIsWebDirectory, but instead just a regular folder on
the file system. So you probably need to create this first (either by
using script or IIS Manager).

Documentation:
http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/59dbbc5e-93f4-4050-8338-570e1d4528b3.mspx?mfr=true


--
Regards,
Kristofer Gafvert
http://www.gafvert.info/iis/ - IIS Related Info


Harry Keck wrote:

>I found this example on MSDN for setting compression down to the folder
>level.
>
>adsutil set w3svc/1/root/Home/StyleSheets/DoStaticCompression true
>
>When I try something similar with
>
>adsutil set
>w3svc/1/root/MyWebSite/Subdirectory1/Subdirectory2/DoDynamicCompression
>true
>
>I get an error message of "The path requested could not be found.
>ErrNumber: -2147024893 (0x80070003)" Should I not be able to specify down
>to
>one folder which files I want to be dynamically compressed? The deepest
>level I can get to work is
>
>adsutil set w3svc/1/root/MyWebSite/DoDynamicCompression true

Re: Problem setting IIS compression down to folder by HarryKeck

HarryKeck
Tue May 30 15:09:02 CDT 2006

According to that article, I should be able to do

cscript C:\Inetpub\AdminScripts\adsutil.vbs set
w3svc/1/root/MyWebSite/Default.aspx/DoDynamicCompression True

but I get the same error. The deepest level I can get is still the main
virtual directory.

cscript C:\Inetpub\AdminScripts\adsutil.vbs set
w3svc/1/root/MyWebSite/DoDynamicCompression True



"Kristofer Gafvert" wrote:

> Hello,
>
> DoStaticCompression can be set on a IIsWebVirtualDir or IIsWebDirectory
> according to the documentation. What i think, based on the error message
> you get, is that /Subdirectory1/Subdirectory2/ is neither an
> IIsWebVirtualDir nor IIsWebDirectory, but instead just a regular folder on
> the file system. So you probably need to create this first (either by
> using script or IIS Manager).
>
> Documentation:
> http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/59dbbc5e-93f4-4050-8338-570e1d4528b3.mspx?mfr=true
>
>
> --
> Regards,
> Kristofer Gafvert
> http://www.gafvert.info/iis/ - IIS Related Info
>
>
> Harry Keck wrote:
>
> >I found this example on MSDN for setting compression down to the folder
> >level.
> >
> >adsutil set w3svc/1/root/Home/StyleSheets/DoStaticCompression true
> >
> >When I try something similar with
> >
> >adsutil set
> >w3svc/1/root/MyWebSite/Subdirectory1/Subdirectory2/DoDynamicCompression
> >true
> >
> >I get an error message of "The path requested could not be found.
> >ErrNumber: -2147024893 (0x80070003)" Should I not be able to specify down
> >to
> >one folder which files I want to be dynamically compressed? The deepest
> >level I can get to work is
> >
> >adsutil set w3svc/1/root/MyWebSite/DoDynamicCompression true
>

Re: Problem setting IIS compression down to folder by Kristofer

Kristofer
Tue May 30 15:35:59 CDT 2006

You need to understand that there is a difference between the files and
folders on the file system, and a node in the metabase. If there is only a
file on the file system, and you have not created a node in the metabase
with an admin object of IIsWebFile, you cannot set a property of this node
in the metabase, simply because it doesn't exist in the metabase.

So i say it again, you first need to create it in the metabase (either by
using a script or IIS Manager), and then set the property of it. You
cannot set a property of something that doesn't exist. That is impossible.

--
Regards,
Kristofer Gafvert
http://www.gafvert.info/iis/ - IIS Related Info


Harry Keck wrote:

>According to that article, I should be able to do
>
>cscript C:\Inetpub\AdminScripts\adsutil.vbs set
>w3svc/1/root/MyWebSite/Default.aspx/DoDynamicCompression True
>
>but I get the same error. The deepest level I can get is still the main
>virtual directory.
>
>cscript C:\Inetpub\AdminScripts\adsutil.vbs set
>w3svc/1/root/MyWebSite/DoDynamicCompression True
>
>
>
>"Kristofer Gafvert" wrote:
>
>>Hello,
>>
>>DoStaticCompression can be set on a IIsWebVirtualDir or IIsWebDirectory
>>according to the documentation. What i think, based on the error message
>>you get, is that /Subdirectory1/Subdirectory2/ is neither an
>>IIsWebVirtualDir nor IIsWebDirectory, but instead just a regular folder on
>>the file system. So you probably need to create this first (either by
>>using script or IIS Manager).
>>
>>Documentation:
>>http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/59dbbc5e-93f4-4050-8338-570e1d4528b3.mspx?mfr=true
>>
>>
>>--
>>Regards,
>>Kristofer Gafvert
>>http://www.gafvert.info/iis/ - IIS Related Info
>>
>>
>>Harry Keck wrote:
>>
>>>I found this example on MSDN for setting compression down to the folder
>>>level.
>>>
>>>adsutil set w3svc/1/root/Home/StyleSheets/DoStaticCompression true
>>>
>>>When I try something similar with
>>>
>>>adsutil set
>>>w3svc/1/root/MyWebSite/Subdirectory1/Subdirectory2/DoDynamicCompression
>>>true
>>>
>>>I get an error message of "The path requested could not be found.
>>>ErrNumber: -2147024893 (0x80070003)" Should I not be able to specify
>>>down
>>>to
>>>one folder which files I want to be dynamically compressed? The deepest
>>>level I can get to work is
>>>
>>>adsutil set w3svc/1/root/MyWebSite/DoDynamicCompression true
>>