Issue with Lesson 2 Icons

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Locked
fredotechGA2742
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 24
Joined: Mon Jan 16, 2012 10:39 am
Location: Maryland USA
Contact:

Issue with Lesson 2 Icons

Post by fredotechGA2742 » Fri Aug 23, 2013 11:58 pm

When I test the Lesson 2 code with the icons added by mobgui the icons do not appear in iOS emulator when i try to test it. all teh code works just the icons are not there.

fredotechGA2742
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 24
Joined: Mon Jan 16, 2012 10:39 am
Location: Maryland USA
Contact:

Re: Issue with Lesson 2 Icons

Post by fredotechGA2742 » Sun Aug 25, 2013 9:36 pm

I downloaded the LC Lesson 2 file and updated the icons and tried it in the simulator and it seems to work. I will go with that version for now but Im curious what the root cause is.

cavenewt
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 66
Joined: Fri Mar 15, 2013 3:54 pm
Location: Jackson Hole, Wyoming, USA

Re: Issue with Lesson 2 Icons

Post by cavenewt » Mon Aug 26, 2013 12:05 am

I finally got a nice clean stack through the end of lesson 2 where everything works great, except the icons in the Simulator. I downloaded and used the icons provided on the lesson resource page. They look great in LC's Run mode, but in the simulator they are just gray boxes. I guess I will deconstruct the provided stack for the finished lesson 2*, but I was wondering if anyone has figured this out yet? Having had trouble with it on my first attempt, I followed Elanor's instructions very carefully using both the video and the PDF.

*Later: so, when I open up the provided stack from the resource page (it came with lesson 3 but is the finished stack as of the end of lesson 2), I found I had to reload the button icons in mobGUI, as they were looking for the C drive on Eleanor's computer. Even after that, and specifying the right things in File/Standalone Application Settings, and then launching the Simulator, not only are the icons just white squares, but the buttons are not even clickable.

I must have overlooked something obvious in making Elanor's stack work on my Mac.

elanorb
Livecode Staff Member
Livecode Staff Member
Posts: 516
Joined: Fri Feb 24, 2006 9:45 am

Re: Issue with Lesson 2 Icons

Post by elanorb » Mon Aug 26, 2013 10:33 am

Hi all

Sorry, I must have neglected to mention this. Because the icons are addressed by filename you need to include them in the Copy Files pane of the Standalone Application Settings, so they are included in the app bundle.

You also need to ensure that the pathnames are relative to where the icons will be in the app bundle so for example if you copy in an icons folder the paths in MobGUI should be

icons/contacts.png

I hope that helps.

Kind regards

Elanor
Elanor Buchanan
Software Developer
LiveCode

cavenewt
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 66
Joined: Fri Mar 15, 2013 3:54 pm
Location: Jackson Hole, Wyoming, USA

Re: Issue with Lesson 2 Icons

Post by cavenewt » Mon Aug 26, 2013 7:00 pm

elanorb wrote:Because the icons are addressed by filename you need to include them in the Copy Files pane of the Standalone Application Settings, so they are included in the app bundle.

You also need to ensure that the pathnames are relative to where the icons will be in the app bundle so for example if you copy in an icons folder the paths in MobGUI should be icons/contacts.png
Thank you Elanor, after I did both suggestions it fixed my icons in the Simulator!

For icons, would it alternatively work to use LC File/Import as control? Or is that for a different purpose?

I see there is also an icons section in the main iOS Standalone Application Settings. When would that be used rather than the Copy Files window of Standalone Application Settings?

Thank you

Locked

Return to “Summer School 2013”