vb.net - Why am I getting System.NullReferenceException: Object reference not set to an instance of an object? -
this question has answer here:
- what nullreferenceexception, , how fix it? 33 answers
i'm trying assign instance of form form property
the system keeps showing error @ second line of code below
dim objfrm = new lsprog.sfile.frmtestrel(addressof sopdos, addressof sopdosline, addressof sopfac) _favoriteform.frminstance = objfrm _favoriteform.frmname = objfrm.name
if nullreferenceexception
need think null
, go , make sure initialise it.
you told us
_favoriteform.frminstance = objfrm
threw exception, _favoriteform
null
, needs initialised fist.
Comments
Post a Comment