I had two bugs in the addcode line... here is the corrected one.

 Code:
$objsc.addcode('Set Session=CreateObject("Microsoft.Update.Session","' + $strWks + '")')