Android Question How to close process

PABLO2013

Well-Known Member
Licensed User
Longtime User
I have a button that uses the wrapper of a third-party library, basically the end result is to record a file on the device, the issue is that although the library closes the file, the application does not close it and it remains open, if I try create another file, it saves the new information with the old and generates errors between data. I don't have access to the jar.

it use of b4xmainpage.


How can I close this it without closing the application ,tks
 

Sagenut

Expert
Licensed User
Longtime User
It's impossible to help you with these informations.
Please provide an example project to show the issue and provide even this third party library jar.
 
Upvote 0

PABLO2013

Well-Known Member
Licensed User
Longtime User
greetings, thanks, basically the code is inside a button.




B4X:
Sub CreateFile

    Try
            shape.SaveShp(fd.FilePath&"/"& fd.ChosenName)
            '.SaveShp , it has the internal .close method
    Catch
   
        ToastMessageShow("Error : " & ret & " : Path : " & fd.FilePath & CRLF & "File : " & fd.ChosenName, False)
   
    End Try

End Sub

But in the end if I call the procedure again, file created, it is still active and without closing, I do not want to close the application, only the process
 
Upvote 0

Marvel

Active Member
Licensed User
It seems to me that it's appending the data instead of replacing it.
Which library is it? Maybe you need to change something in the source code
 
Upvote 0

PABLO2013

Well-Known Member
Licensed User
Longtime User
Thanks Marvel, the library is from third parties and cannot be modified, I have to find a way from b4a
 
Upvote 0

Sagenut

Expert
Licensed User
Longtime User
We don't know which library you are using.
We don't know which version of Android you are testing on.
We don't know in which path you are trying to save your file.
We need you to post a small example which demonstrate the problem AND we need the library you are using.
 
Upvote 0
Top