NimbleKit - fast iOS app development

Settings Bundle

Problem discussions

Re: Settings Bundle

Postby apt » Mon Apr 19, 2010 8:02 pm

I think its more like this actually but its still now updating.

AppVersion=NKGetAppVersion();
settings.setValueForKey(AppVersion,"Version");

Can I only get the values from the Setting Bundle and not set them?
Adrian Thompson
Founder
http://www.taptapp.co.uk

NimbleKit Registered User: U853078901
User avatar
apt
NimbleKit Expert
 
Posts: 356
Joined: Fri Jan 29, 2010 11:52 pm
Location: Sheffield, UK

Re: Settings Bundle

Postby sunny » Mon Apr 19, 2010 8:34 pm

Code: Select all
var version = NKGetAppVersion();
var settings = new NKSettings;
settings.setValueForKey(version, "Version");

did you try this?
User avatar
sunny
Staff
 
Posts: 2666
Joined: Sat May 30, 2009 5:18 am
Location: Palo Alto, California

Re: Settings Bundle

Postby apt » Mon Apr 19, 2010 9:07 pm

Just tried that suggestion and still not working. I'm assuming that 'Version' is the title of the setting bundle I'm trying to change as opposed to 'Item 0' for example.
Adrian Thompson
Founder
http://www.taptapp.co.uk

NimbleKit Registered User: U853078901
User avatar
apt
NimbleKit Expert
 
Posts: 356
Joined: Fri Jan 29, 2010 11:52 pm
Location: Sheffield, UK

Re: Settings Bundle

Postby apt » Mon Apr 19, 2010 9:22 pm

Never mind I've sorted it. Its the Key name thats needed not the title. The version its placed in includes quotes though, any way of stripping these out? See attached image.
Attachments
Screen shot 2010-04-19 at 22.21.06 pm.png
Quotes around string
Screen shot 2010-04-19 at 22.21.06 pm.png (9.21 KiB) Viewed 449 times
Adrian Thompson
Founder
http://www.taptapp.co.uk

NimbleKit Registered User: U853078901
User avatar
apt
NimbleKit Expert
 
Posts: 356
Joined: Fri Jan 29, 2010 11:52 pm
Location: Sheffield, UK

Re: Settings Bundle

Postby apt » Tue Apr 20, 2010 5:32 pm

Anyone got any ideas?
Adrian Thompson
Founder
http://www.taptapp.co.uk

NimbleKit Registered User: U853078901
User avatar
apt
NimbleKit Expert
 
Posts: 356
Joined: Fri Jan 29, 2010 11:52 pm
Location: Sheffield, UK

Re: Settings Bundle

Postby inveni0 » Tue Apr 20, 2010 8:23 pm

apt wrote:Anyone got any ideas?


Use the JavaScript replace() function...or, you could use split().
http://www.tizag.com/javascriptT/javascript-string-replace.php
inveni0
 
Posts: 213
Joined: Thu Jul 30, 2009 3:01 pm

Re: Settings Bundle

Postby apt » Tue Apr 20, 2010 9:03 pm

The thing is the quotes are not present in the variable within my app just when I've added the varible to the settings bundle via NKSettings() so I'm not sure trying to strip out something thats not present in the app will work.

For example if I do an NKAlert in the app I get the following:

Screen shot 2010-04-20 at 20.14.54 pm.png
Screen shot 2010-04-20 at 20.14.54 pm.png (33.99 KiB) Viewed 435 times


Adding it to the setting bundle I get this:

Screen shot 2010-04-19 at 22.21.06 pm.png
Screen shot 2010-04-19 at 22.21.06 pm.png (9.21 KiB) Viewed 435 times
Adrian Thompson
Founder
http://www.taptapp.co.uk

NimbleKit Registered User: U853078901
User avatar
apt
NimbleKit Expert
 
Posts: 356
Joined: Fri Jan 29, 2010 11:52 pm
Location: Sheffield, UK

Re: Settings Bundle

Postby sunny » Tue Apr 20, 2010 10:51 pm

settings don't add any symbols, it's probably OS adds that as variable is string
User avatar
sunny
Staff
 
Posts: 2666
Joined: Sat May 30, 2009 5:18 am
Location: Palo Alto, California

Re: Settings Bundle

Postby apt » Wed Apr 21, 2010 12:29 am

So no way around it? it looks very untidy :(
Adrian Thompson
Founder
http://www.taptapp.co.uk

NimbleKit Registered User: U853078901
User avatar
apt
NimbleKit Expert
 
Posts: 356
Joined: Fri Jan 29, 2010 11:52 pm
Location: Sheffield, UK

Re: Settings Bundle

Postby sunny » Wed Apr 21, 2010 3:07 pm

send a sample project to me, I'll se what can be done
User avatar
sunny
Staff
 
Posts: 2666
Joined: Sat May 30, 2009 5:18 am
Location: Palo Alto, California

PreviousNext

Return to Troubleshooting

Who is online

Users browsing this forum: No registered users and 0 guests