Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6047189
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T07:19:26+00:00 2026-05-23T07:19:26+00:00

Problem Description I am writing application for Android and use native code, And test

  • 0

Problem Description

I am writing application for Android and use native code, And test it on Android-Emulator. In order to see what happens in JNI code I create file in Android /data/LogTest/ folder and write my log information in it.

FILE * pFile;
pFile = fopen ("/data/LogTest/Log.txt"", "w");
// .... 
// Write some logs to file ...
// ....

When I run in the first time Android application everything goes Okay, I can see logs in Log.txt file. But when I close Android application and run it again nothing happening. Like application can’t write Logs to the file second time.

Self Ideas

I think that the main reason of this problem is that, when I create file at first time the creator application Name is for ex. 456 after when I try to write some more information to file application Name is for ex. 856 and so application 856 can’t write to file that have created application 456.

Question

  1. How I can launch application with same name, in order Android let me to write to file in second time.
  2. Or maybe the main reason o problem is not that Application every time get rundom names.
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T07:19:27+00:00Added an answer on May 23, 2026 at 7:19 am

    I think you are not allowed to write in that folder. Read through the answers here. Either use the sdk card or your application directory to store files.

    File Operations in Android NDK

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Problem Description I'm writing module for Android (JAVA) that use native code (C) .
I'm writing application for downloading CSV file from web and inserting data into table
I'm writing an application where people ask questions, and get answers in the form
I'm writing a little application under Linux (embedded on ARM) that is running two
The application, I am writing, generates an ArrayList of Characters at certain stage. At
I am writing a Clojure macro that accepts a description of a panel using
I am using DataTables plugin to fetch and paginate my table use ajax calls.
this piece of code is driving me crazy. I'm trying to print a help
I'm writing some PHP that will interact with MySQL to 1. upload and 2.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.