Is there a way to get the following information by using c# script.
PC Name Service Tag CPU type CPU speed size of the c:\ drive, Installed RAM, OS name, OS Product Key, Office Version, and Office Product Key.
Thanks.
WMI is what you're looking for.
http://www.codeproject.com/KB/cs/EverythingInWmi02.aspx
Let me add the link to Part 3 too, which concentrates on hardware via WMI
http://www.codeproject.com/KB/cs/EverythingInWmi03.aspx
MSDN is also a great resource for WMI scopes...
http://msdn.microsoft.com/en-us/library/aa394554(v=vs.85).aspx