tags:

views:

336

answers:

1

I am new to PowerShell, I am trying to change a property of an IIS website using the following syntax (which doesn't work)

(get-item 'IIS:\Sites\Default Website').logFile.directory = 'd:\'

It doesn't show any error but doesn't change the property either.

Anybody help?

+2  A: 

You may need either:

Set logFile to a new value with the correct directory

or

Set-ItemProperty 'IIS:\Sites\Default Website' -name ...

Jay Bazuzi
Perfect, this is exactly what I needed!
Tim