Android Question Close Activity event

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

Similar threads

B4A Tutorial Camera2 - Still images and videos
B4A Library Camera2 - New camera library
B4A Library EZcamera
B4A Tutorial Google Maps
B4A Tutorial Integrating Firebase Services
  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...
  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