Discussion Forums  >  Config Data, JSON, App Refresh

Replies: 13    Views: 275

allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
07/25/13 12:03 PM (10 years ago)

Snippet Keeper Error

I created a payment calculator for the app that I made using buzztouch. I created a new class file with the .h, .m, and .xib files. I used the JSON snippet keeper to point to it off my main menu. Chris helped me get all that straight. Now, everything compiles correctly when I run it in the sim. I go through the menu items and everything works till I get to the menu item for the snippet keeper. When I click on it, xcode opens up main.m and highlights this line in green: int retVal= UIApplicationMain(argc,argv,@"UIApplication",@"vehiclebuyingcoach_appDelegate"); There is a little green arrow point to it that says: Thread 1:signal SIGABRT I must be missing something here and its probably simple, just cant figure it out. Anyone have any Idea? Allan
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
07/25/13 03:41 PM (10 years ago)
Try going through my how-to document on debugging and see if that gives any more information. https://www.buzztouch.com/files/howtos/exception%20debugging%20how-to.pdf
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
07/25/13 04:42 PM (10 years ago)
Ya, no disrespect, I doubt if it's the snippet keeper. Chris1's tutorial has saved me countless hours of troubleshooting, and is well worth the time. Those times that I do get a 'mystery sigabrt', I've 'usually' (but not always) found I was releasing some variable before I should have. Good Luck, let us know how you progress! Cheers! -- Smug
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/25/13 07:46 PM (10 years ago)
Thanks Chris and Smug I did what you said but i cant make heads or tails of it? They are highlighted in green with a little message thats says Thread 1: breakpoint 1.1 my 1st error is in the BT_ControllerManager.m file: if([theClassName length] > 0){ Class theClass = NSClassFromString(theClassName); if(theClass != nil){ if([theClass respondsToSelector:@selector(alloc)]){ error>>> theViewController = [[theClass performSelector:@selector(alloc)] error>>>initWithScreenData:theScreen]; return theViewController; my 2nd error is in the same file: //////////////////////////////////////////////////////////////////////// //if we are here, we are loading a new screen object UIViewController *theNextViewController = [self initViewControllerForScreen:theScreenData]; 3rd error is in WB_screen_menuImage.m: //load next screen if it's not nil if(screenObjectToLoad != nil){ [BT_viewControllerManager handleTapToLoadScreen:[self screenData] theMenuItemData:thisMenuItem theScreenData:screenObjectToLoad]; }else{ //show message error>> [BT_debugger showIt:self theMessage:[NSString error>>> stringWithFormat:@"%@",NSLocalizedString(@"menuTapError",@"The application doesn't know how to handle this click?")]];
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
07/25/13 07:50 PM (10 years ago)
Not sure why you're getting the error there, but you're problem is definitely in the WB_screen_menuImage plugin where you're trying to load the screen. What does your JSON look like in the JSON Snippet Keeper?
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/25/13 07:54 PM (10 years ago)
{"itemId":"1AA7AA9B5F8A25EFB9693C8", "itemType":"paymentCalculator"}
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/25/13 08:01 PM (10 years ago)
what if I switched to using the standard menu?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
07/25/13 11:35 PM (10 years ago)
Is 'paymentCalculator' an itemType? Is that your 'unique plugin name' ? Cheers! -- Smug
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/26/13 06:02 AM (10 years ago)
It's the name of the class. paymentCalculator.h paymentCalculator.m PaymentCalculator.xib
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/26/13 06:11 AM (10 years ago)
I only created a new class and used the snippet keeper to get the menu to point to it. Should I have created a unique plugin for the new class files?
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
07/26/13 06:20 AM (10 years ago)
No need to do that. Double check the json for your menu item to make sure the child item is pointing to that itemId
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/26/13 07:25 AM (10 years ago)
Ok I'll do that. Thanks
 
allandriggers
Apple Fan
Profile
Posts: 188
Reg: Dec 13, 2012
Knoxville, TN
11,680
like
07/26/13 04:57 PM (10 years ago)
Yeah the itemId in the BT_config.txt file matches the itemId in the snippet keeper: {"itemId":"C1B4C63415EC3E3EF864CCA", "itemType":"BT_menuItem", "loadScreenWithItemId":"1AA7AA9B5F8A25EFB9693C8","titleText":"Payment Calculator"} Here is a question...where should I have new class files? Right now I them in the BT_Layout folder with the other view controllers. Would this have anything to do with my problem?
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
07/26/13 05:00 PM (10 years ago)
Shouldn't matter, but standard is to put them in BT_Plugins folder
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.