1. *** New version of B4J is available ***
    B4J v7.8
    Dismiss Notice

B4J Question Fix me my warning #2

Discussion in 'B4J Questions' started by universengo, Jun 19, 2019.

  1. universengo

    universengo Member

    My code is as below:
    Code:
    Sub txtAreaNull (txtLM As TextArea, tb As StringAs Boolean
        
    Dim tNull As Boolean = False
        
    If txtLM.Text="" Then
            fx.Msgbox(Main.MainForm,tb,
    "Warning!")
            txtLM.RequestFocus
            tNull = 
    True
            
    Return tNull
        
    End If
    End Sub
    The log is
    Nobody help me to fix this error.
    Thanks.
     
  2. Tayfur

    Tayfur Well-Known Member Licensed User

    Code:
    Sub txtAreaNull (txtLM As TextArea, tb As StringAs Boolean
        
    Dim tNull As Boolean = False
        
    If txtLM.Text="" Then
            fx.Msgbox(Main.MainForm,tb,
    "Warning!")
            txtLM.RequestFocus
            tNull = 
    True
            
    Return tNull
        
    End If
        
    Return tNull
    End Sub
     
    universengo likes this.
  3. José J. Aguilar

    José J. Aguilar Well-Known Member Licensed User

    universengo likes this.
  4. universengo

    universengo Member

    That is perfect!
    Thank Tayfur so much.
     
  5. universengo

    universengo Member

    My new code.

    Code:
    Sub txtAreaNull (txtLM As TextArea, tb As StringAs Boolean
        
    If txtLM.Text="" Then
            fx.Msgbox(Main.MainForm,tb,
    "Warning!")
            txtLM.RequestFocus
            
    Return True
        
    Else
            
    Return False
        
    End If
    End Sub
    Fixed a warning #2
     
    José J. Aguilar likes this.
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice