I believe the error you got is compiling error, not runtime error. That is, your code does not compile.
1. The first compiling error:
Not like VB, in C#, you need to pass parameteres for the optional argument:
2. The second compiling error: that is because C# is strong type language, ab "object" natually does not have property that from an specific class instance. YOu need to cast the "object" into a correct specific type before to access the property. In your case, you need: