Originally posted to "ASP components" forum, then saw that this forum fits better. <BR>-------------------------<BR>I&#039;m porting a VB6 object into VBscript so that it wont require dll registration. The problem I&#039;m having is referencing a property (public or private) from within a function. Here&#039;s a pared down version of the code: <BR><BR>&#039;Declaring the class <BR>class Board5 <BR>&nbsp;&nbsp;&nbsp;Public aPiece5(7, 7, 1) &#039;declare public var <BR>&nbsp;&nbsp;&nbsp;Public Function BoardGet5() <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;aPiece5( 1, 1, 1) = "Black" &#039;error here <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;BoardGet 5 = aPiece5 <BR>&nbsp;&nbsp;&nbsp;End function <BR>end class &#039;(Board5) <BR><BR>&#039;instantiating the class <BR>dim oBoard5, aDummy <BR>set oBoard5 = new Board5 <BR><BR>&#039;call the method <BR>aDummy = oBoard5.BoardGet5() <BR>Response.Write aDummy(1,1,1) <BR>Response.End <BR><BR>I get the error: <BR>Microsoft VBScript runtime (0x800A000D) Type mismatch: &#039;aPiece5&#039; <BR><BR>The line number for the error message points to the line that reads &#039;aPiece5(1, 1, 1) = "Black"&#039;. It&#039;s as if the property is not accessible within the function. This worked fine in VB6. Any thoughts would be appreciated. <BR><BR>Thanks.