vb.net - Sub New() is not accessible in this context because it is 'Friend' -


So what does it mean and how do I fix it?

This puts a new keyword in the message is coming when I went below the line (lines) If I remove it I, I get an error at runtime so I need to find new applications. What am i doing wrong

  dim as Ops AeccPointStyle = new AeccPointStyle OPS = oDescKey.PointStyle Debug.Print (oPS.Name) Debug.Print (oPS.MarkerSymbolName)  

Also try the

  New AeccPointStyle Ops as the slow ops = oDescKey.PointStyle Debug.Print (oPS.Name) Debug.Print (oPS.MarkerSymbolName)  

Thank you

uPDATE 1 - meta-

1 -

  nothing dim Ops AeccPointStyle = as ops = oDescKey.PointStyle  

2 -

  as dim Ops AeccPointStyle = oDescKey.PointStyle  
< P> Both versions NullRefer Throw enceExceptions.

After the text "itemprop =" text ">

AeccPointStyle is a blank creator friend, which means only classrooms inside its assembly can call it Has been marked as.

But by looking at my code, I do not think you need to call New, just set it to nothing, or even better, set your variable with good value: Edit Your NullReferenceException:

Typically, this type of exception is raised when you say the value of the object with the value of something, this case Switch to, if o Disky was set to nothing, will be raised an exception.

If Oddsky is not worth the price, then something that executes the code is the pointstyle property, so it is safe to assume that PointStyle property throws a NullReferenceException. Try looking at the oDescKey.PointStyle variable in the debugger, you should see that it throws an exception.


Comments

Popular posts from this blog

c# - ListView onScroll event -

PHP - get image from byte array -

Linux Terminal Problem with Non-Canonical Terminal I/O app -