NDK sqlite

557 views
Skip to first unread message

Marwa Abayed

unread,
Mar 20, 2012, 3:55:42 PM3/20/12
to android-ndk
hi,
how can i use sqlite in native code with ndk , i want to access to
settings.db
thks

liuyix

unread,
Mar 21, 2012, 8:46:17 AM3/21/12
to andro...@googlegroups.com
you can find some infomation on http://lmgtfy.com/?q=use+sqlite+in+native+code+with+ndk

在 2012年3月21日星期三UTC+8上午3时55分42秒,Marwa Abayed写道:

David Given

unread,
Mar 21, 2012, 7:20:18 PM3/21/12
to andro...@googlegroups.com
On 21/03/12 12:46, liuyix wrote:
> you can find some infomation
> on http://lmgtfy.com/?q=use+sqlite+in+native+code+with+ndk

The less passive aggressive answer is that NDK code doesn't have access
to the built-in sqlite library, but sqlite is so small and so trivial to
compile that it's easy to add to your project. See here:

http://stackoverflow.com/questions/5523067/sqlite-with-android-ndk

--
┌─── dg@cowlark.com ───── http://www.cowlark.com ─────

│ "Never attribute to malice what can be adequately explained by
│ stupidity." --- Nick Diamos (Hanlon's Razor)

signature.asc

Marwa Abayed

unread,
Mar 21, 2012, 10:15:46 PM3/21/12
to andro...@googlegroups.com
I don't find the ways to access to settings.db , any help please

David Turner

unread,
Mar 22, 2012, 6:33:58 AM3/22/12
to andro...@googlegroups.com
On Thu, Mar 22, 2012 at 3:15 AM, Marwa Abayed <marwa....@gmail.com> wrote:
I don't find the ways to access to settings.db , any help please

You can't access it from normal applications. Use framework methods through JNI to access the settings database instead.
 
Le mardi 20 mars 2012 20:55:42 UTC+1, Marwa Abayed a écrit :
hi,
how can i use sqlite in native code with ndk , i want to access to
settings.db
thks

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/rti1vArKOYEJ.

To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en.

Marwa Abayed

unread,
Mar 22, 2012, 8:44:46 AM3/22/12
to andro...@googlegroups.com
thanks digit , can you explain more plz because i don't found the method 


Le jeudi 22 mars 2012 11:33:58 UTC+1, Digit a écrit :
On Thu, Mar 22, 2012 at 3:15 AM, Marwa Abayed <marwa....@gmail.com> wrote:
I don't find the ways to access to settings.db , any help please

You can't access it from normal applications. Use framework methods through JNI to access the settings database instead.
 
Le mardi 20 mars 2012 20:55:42 UTC+1, Marwa Abayed a écrit :
hi,
how can i use sqlite in native code with ndk , i want to access to
settings.db
thks

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/rti1vArKOYEJ.

To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk+unsubscribe@googlegroups.com.

David Turner

unread,
Mar 22, 2012, 8:58:52 AM3/22/12
to andro...@googlegroups.com
http://developer.android.com/reference/android/provider/Settings.Secure.html

To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/0XDlysRNdGAJ.

To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.

Marwa Abayed

unread,
Mar 22, 2012, 9:10:13 AM3/22/12
to andro...@googlegroups.com
yes i done this and when i want to insert into secure i fill permission denied 

mic _

unread,
Mar 22, 2012, 11:41:27 AM3/22/12
to andro...@googlegroups.com
Do you have the relevant permissions in your manifest? (http://developer.android.com/reference/android/Manifest.permission.html#WRITE_SECURE_SETTINGS)

/Michael

To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/Pe1XV2cbHl0J.

To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.

Marwa Abayed

unread,
Mar 22, 2012, 1:18:12 PM3/22/12
to andro...@googlegroups.com
yes but still not working and in the log error write_secure_settings
Reply all
Reply to author
Forward
0 new messages