Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Microsoft SQL Server 2008 Administration with Windows PowerShell
This is the forum to discuss the Wrox book Microsoft SQL Server 2008 Administration with Windows PowerShell by Ananthakumar Muthusamy, Yan Pan ; ISBN: 978-0-470-47728-1
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Microsoft SQL Server 2008 Administration with Windows PowerShell section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old June 21st, 2010, 11:37 AM
Registered User
 
Join Date: Jun 2010
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Question on

I'm a powershell newbie and having a problem with an example in the book. On page 177 the script at the bottom:

Code:
PS H:\> get-wmiobject -class win32_service -computername MyComputer | where-object{ ($_.name -like 'SQLSERVERAGENT') }.changestartmode('manual')
It says:

"Method invocation failed because [System.Management.Automation.ScriptBlock] doe
sn't contain a method named 'changestartmode'.
At line:1 char:125
+ get-wmiobject -class win32_service -computername MyComputer | where-object{ ($_
.name -like 'SQLSERVERAGENT') }.changestartmode <<<< ('manual')
+ CategoryInfo : InvalidOperation: (changestartmode:String) [], R
untimeException
+ FullyQualifiedErrorId : MethodNotFound"

What do I need to be looking at to figure out what is wrong? Thanks for any help.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Disappearing UserName & Question within Customized PasswordRecovery Question Template eddiemcham ASP.NET 3.5 Basics 13 June 13th, 2009 04:23 AM
Question aspcoder BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 3 May 15th, 2009 04:46 PM
One more question!! mike_remember ASP.NET 1.0 and 1.1 Professional 10 October 26th, 2006 03:01 PM
thanks but i have another question antony maiky CSS Cascading Style Sheets 1 August 20th, 2006 03:52 PM



All times are GMT -4. The time now is 11:05 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.