Share your advanced knowledge/code with the community.
Peter
 
Posts: 353
Joined: Mon Feb 24, 2014 10:17 pm

Module: Preferences

by Peter Thu Jun 01, 2017 11:50 am

Hello,

the PureBasic Preferences-Library for SpiderBasic:

https://github.com/spiderbytes/Preferences

Greetings ... Peter

Edit: Removed code; added github-Link
Last edited by Peter on Fri Jul 07, 2017 9:37 am, edited 1 time in total.
User avatar
SparrowhawkMMU
 
Posts: 247
Joined: Wed Aug 19, 2015 3:02 pm
Location: United Kingdom

Re: Module: Preferences

by SparrowhawkMMU Fri Jun 02, 2017 1:53 pm

I was not even aware of it in PureBasic! :D

Thanks Peter. Incidentally, do you have a github/gitlab account where you have all your great libraries/modules in a central place?

It would be nice if Fred added a user-contributed modules section to the SB website so that your code and that of the others who have contributed would be readily available and easy to find.
Peter
 
Posts: 353
Joined: Mon Feb 24, 2014 10:17 pm

Re: Module: Preferences

by Peter Fri Jul 07, 2017 9:40 am

SparrowhawkMMU wrote:Incidentally, do you have a github/gitlab account where you have all your great libraries/modules in a central place?

Since just now. ;-)

(see first posting)

Greetings ... Peter
User avatar
SparrowhawkMMU
 
Posts: 247
Joined: Wed Aug 19, 2015 3:02 pm
Location: United Kingdom

Re: Module: Preferences

by SparrowhawkMMU Fri Jul 07, 2017 10:15 am

+1
IdeasVacuum
 
Posts: 111
Joined: Tue Feb 25, 2014 1:27 pm

Re: Module: Preferences

by IdeasVacuum Tue Sep 19, 2017 11:11 pm

Hi Peter
Where is Preferences.prefs stored? :?
Peter
 
Posts: 353
Joined: Mon Feb 24, 2014 10:17 pm

Re: Module: Preferences

by Peter Wed Sep 20, 2017 6:50 am

IdeasVacuum wrote:Where is Preferences.prefs stored? :?

in your Browser.

Screenshot of my Google Chrome - Console (opened with <F12>:
Image

Greetings ... Peter
IdeasVacuum
 
Posts: 111
Joined: Tue Feb 25, 2014 1:27 pm

Re: Module: Preferences

by IdeasVacuum Wed Sep 20, 2017 1:35 pm

Hi Peter

Ah, I was expecting Preferences.pref to be a stand-alone file, no wonder I could not find it. So, it seems to work on Android too, but the app must create the initial data list first. I'm going to have another play with it, as a work-around for SB's need to ask the User to select a text file, which in most scenarios with regards to smartphone app data use is a definite no no.

EDIT: Well, it works but the data save is not persistent so next time the app is run, the most recent prefs are not there to read.
Going to try SQL........
Return to Tricks 'n' Tips

Who is online

Users browsing this forum: No registered users and 1 guest