Android Question Close Activity event

Discussion in 'Android Questions' started by klingon467, Jun 17, 2015.

  1. klingon467

    klingon467 Member Licensed User

    Hi,
    i want to close my activity form...
    Instead of the command: StartActivity(rCam)

    StopActivity(rCam) ???? does not exist ????

    i have try with:
    Code:
    If chChat.Enabled = True Then
      
    StartActivity(rCam)
       
    Else If chChat.Enabled = False Then
    Dim ms As mShared
    ms.Initialize(rCam)
    ms.closeActivity
       
    Else
         
    log(LastException.Message)
       
    End If
    Code:
    'Class module mShared
    Sub Class_Globals
        
    Dim myp As Activity
    End Sub
    Public Sub Initialize(act As Activity)
    myp=act
    End Sub
    Sub closeActivity
        myp.Finish
    End Sub
    but not work????

    i have this exception
     
  2. klingon467

    klingon467 Member Licensed User

    Sorry!
    i resolved so:

    into form "rCam" i add this:

    Code:
    Sub closeActivity
        
    Activity.Finish
    End Sub
    and i have call so:
    Code:
    CallSub(rCam, "closeActivity")
     
Loading...