mybase.showdialog event fired without apparent reason

Posted by António Mendes on Stack Overflow See other posts from Stack Overflow or by António Mendes
Published on 2010-06-08T16:39:15Z Indexed on 2010/06/08 16:42 UTC
Read the original article Hit count: 450

Filed under:
|
|

Hi,

i'm new to vb .net and oop although i have learned the basics. I'm working in VB and .NET CF 3.5 and i'm trying to pass and received a value with showdialog. The issue here is when i'm done with a procedure in Load, for some reason MyBase.Showdialog (line 3) gives an error of "NullReferenceException was unhandled", but the same procedure doesn't have anything to do with Showdialog. Also, this same error happens with me in other forms when i use AlphaImageButton from AlphaMobileControls. I even created an custom AlphaImageButton with a DialogResult Property and set it to None with no avail.

Public Overloads Function ShowDialog(ByRef sArg As String) As String

    sParam = Split(sArg, vbTab)
    sArtigo = sParam(0)
    If MyBase.ShowDialog() = Windows.Forms.DialogResult.OK Then
        Return lblQuant.Text
    End If
    Return Nothing
End Function

© Stack Overflow or respective owner

Related posts about .NET

Related posts about vb