Discussion Forums  >  Uncategorized

Replies: 14    Views: 211

stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
01/08/12 10:54 AM (14 years ago)

pdf blank at first try

I have a menu of buttons where when you touch a button a pdf file loads. There are 12 buttons and every now and then, when I touch one of two specific buttons (and it seems so far that's it's always the same two), the screen opens to a blank screen. When I go back to the button screen and retouch the same button again, the screen opens to the correct pdf document. This is intermittent and it's driving me nuts. Any ideas?
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/08/12 12:12 PM (14 years ago)
Hi Stevek, Is the PDF file a local file or do you call it from a URL? If from a URL, it seems there could be confusion within the app regarding caching or something. Mark
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 12:30 PM (14 years ago)
Mark, PDF is local. I've copied and pasted below relevant entries in debug screen. Not very familiar with objective c (which is why I love buzztouch) but about 15 rows down there is a reference to blank.png and right after thata not downloading entry Yet a few lines after it says the pdf, june 2012 does exist. Hope this helps 2012-01-08 14:20:20.002 skyeventfinder[6978:17303] BT_screen_menuButtons: menuItemTap 2012-01-08 14:20:20.203 skyeventfinder[6978:17303] BT_application: getScreenDataByItemId 00ACADBC8F74D0C68B3D41A 2012-01-08 14:20:20.203 skyeventfinder[6978:17303] BT_application: screenType is BT_screen_webView for screen with nickname: JUNE and itemId: 00ACADBC8F74D0C68B3D41A 2012-01-08 14:20:20.203 skyeventfinder[6978:17303] BT_viewControllerManager: handleTapToLoadScreen 2012-01-08 14:20:20.203 skyeventfinder[6978:17303] BT_viewControllerManager: the parent screen nickname: 2012 itemId: 77E33EEE89E7E70F9381696 itemType: BT_screen_menuButtons 2012-01-08 14:20:20.204 skyeventfinder[6978:17303] BT_viewControllerManager: the menu/button tapped is itemId: 1E49599E046862CFEED1CED 2012-01-08 14:20:20.204 skyeventfinder[6978:17303] BT_viewControllerManager: the screen to load is nickname: JUNE itemId: 00ACADBC8F74D0C68B3D41A itemType: BT_screen_webView 2012-01-08 14:20:20.204 skyeventfinder[6978:17303] BT_viewControllerManager: initViewControllerForScreen nickname: JUNE itemId: 00ACADBC8F74D0C68B3D41A type: BT_screen_webView 2012-01-08 14:20:20.204 skyeventfinder[6978:17303] BT_screen_webView: INIT 2012-01-08 14:20:20.204 skyeventfinder[6978:17303] BT_rotatingNavController: pushViewController for screen: 00ACADBC8F74D0C68B3D41A 2012-01-08 14:20:20.205 skyeventfinder[6978:17303] BT_screen_webView: viewDidLoad 2012-01-08 14:20:20.205 skyeventfinder[6978:17303] BT_viewUtilities: getWebNavBarForScreen with nickname: JUNE and itemId: 00ACADBC8F74D0C68B3D41A and type: BT_screen_webView 2012-01-08 14:20:20.207 skyeventfinder[6978:17303] BT_screen_webView: viewWillAppear 2012-01-08 14:20:20.208 skyeventfinder[6978:17303] BT_viewUtilities: configureBackgroundAndNavBar for screen with nickname: JUNE and itemId: 00ACADBC8F74D0C68B3D41A and type: BT_screen_webView 2012-01-08 14:20:20.209 skyeventfinder[6978:17303] BT_fileManager: File does exist in Xcode bundle: blank.png 2012-01-08 14:20:20.209 skyeventfinder[6978:17303] BT_background_view: Image for background view exists in Xcode bundle - not downloading. 2012-01-08 14:20:20.209 skyeventfinder[6978:17303] BT_background_view: setImage 2012-01-08 14:20:20.210 skyeventfinder[6978:17303] BT_screen_webView: initLoad 2012-01-08 14:20:20.210 skyeventfinder[6978:17303] BT_fileManager: File does exist in Xcode bundle: june 2012.pdf 2012-01-08 14:20:20.210 skyeventfinder[6978:17303] BT_screen_webView: Loading file from Xcode bundle: june 2012.pdf 2012-01-08 14:20:20.214 skyeventfinder[6978:17303] BT_screen_webView: shouldStartLoadWithRequest: URL: file:///Users/skronwith/Library/Application%20Support/iPhone%20Simulator/5.0/Applications/C4BC53EE-96DF-4AD2-844E-6CF9D31C3340/skyeventfinder.app/june%202012.pdf 2012-01-08 14:20:20.214 skyeventfinder[6978:17303] BT_screen_webView: shouldStartLoadWithRequest: SCHEME: file 2012-01-08 14:20:20.214 skyeventfinder[6978:17303] BT_screen_webView: webViewDidStartLoad 2012-01-08 14:20:20.214 skyeventfinder[6978:17303] BT_screen_webView: showProgress 2012-01-08 14:20:20.214 skyeventfinder[6978:17303] BT_viewUtilities: getProgressView 2012-01-08 14:20:20.232 skyeventfinder[6978:17303] BT_screen_webView: webViewDidFinishLoad 2012-01-08 14:20:20.232 skyeventfinder[6978:17303] BT_screen_webView: hideProgress Jan 8 14:20:20 stevesmaincomputer-2.local skyeventfinder[6978] <Error>: CGAffineTransformInvert: singular matrix.
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/08/12 12:51 PM (14 years ago)
Hi Stevek, The line about not downloading simply means that the file has been found locally, so it does not need to be downloaded from a URL. That's purely informational...not an error or anything. One thing that I do see is that you have a space in your PDF file name. I would get rid of that by adding an underscore or something, and I'll bet you'll be fine after that! There should be no spaces or special characters in any files you add to BT_Images or BT_Docs (or anywhere else, for that matter!). Remember to re-add your file to your Xcode project after you rename it. Mark
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 02:05 PM (14 years ago)
Mark, Unfortunately that didn't fix it. Still, some buttons lead to a blank PDF and then when repressed lead to the correct one. And sometimes this happens, and most of the time not. It's crazy how you can press a button a number of times and it works correctly and then all of a sudden it leads to a blank pdf screen, only to work once again when repressed!
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 02:06 PM (14 years ago)
I added an underscore _ by the way.
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 02:38 PM (14 years ago)
One thing I've just discovered it this helps. When it appears that a blank pdf appears, it seems to be just a blank first page. If I scroll down, the other pages are there. ????
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 02:40 PM (14 years ago)
And if I double click on the blank page, the page appears, enlarged as it should be, then if I double click again, it returns to blank!
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/08/12 05:47 PM (14 years ago)
Well, it seems that the document is being loaded at least. Is there any console output you can provide during these situations. This could be a simulator issue. Have you tried testing on a real device? Or, closing the simulator, and starting again? Mark
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 06:03 PM (14 years ago)
Haven't tried on a real device since I haven't signed up yet as a developer. Have closed and started again often. Here is the latest output from the debugger when it happened:Notice error in last line. for screen with nickname: JANUARY and itemId: D44E84E72F4C3E969EF49DD and type: BT_screen_webView 2012-01-08 19:57:14.038 skyeventfinder[8563:17303] BT_fileManager: File does exist in Xcode bundle: blank.png 2012-01-08 19:57:14.038 skyeventfinder[8563:17303] BT_background_view: Image for background view exists in Xcode bundle - not downloading. 2012-01-08 19:57:14.038 skyeventfinder[8563:17303] BT_background_view: setImage 2012-01-08 19:57:14.038 skyeventfinder[8563:17303] BT_screen_webView: initLoad 2012-01-08 19:57:14.039 skyeventfinder[8563:17303] BT_fileManager: File does exist in Xcode bundle: January_2012.pdf 2012-01-08 19:57:14.040 skyeventfinder[8563:17303] BT_screen_webView: Loading file from Xcode bundle: January_2012.pdf 2012-01-08 19:57:14.042 skyeventfinder[8563:17303] BT_screen_webView: shouldStartLoadWithRequest: URL: file:///Users/skronwith/Library/Application%20Support/iPhone%20Simulator/5.0/Applications/C4BC53EE-96DF-4AD2-844E-6CF9D31C3340/skyeventfinder.app/January_2012.pdf 2012-01-08 19:57:14.043 skyeventfinder[8563:17303] BT_screen_webView: shouldStartLoadWithRequest: SCHEME: file 2012-01-08 19:57:14.043 skyeventfinder[8563:17303] BT_screen_webView: webViewDidStartLoad 2012-01-08 19:57:14.043 skyeventfinder[8563:17303] BT_screen_webView: showProgress 2012-01-08 19:57:14.043 skyeventfinder[8563:17303] BT_viewUtilities: getProgressView 2012-01-08 19:57:14.064 skyeventfinder[8563:17303] BT_screen_webView: webViewDidFinishLoad 2012-01-08 19:57:14.064 skyeventfinder[8563:17303] BT_screen_webView: hideProgress Jan 8 19:57:14 stevesmaincomputer-2.local skyeventfinder[8563] <Error>: CGAffineTransformInvert: singular matrix.
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/08/12 06:37 PM (14 years ago)
Hi Stevek, I did a quick Google search of that error, and it might be some sort of coding issue. It's odd though, since I have several apps that load PDFs, and am not having this issue. I am concerned about blank.png, and the possible effects that might be having on it. In the Advanced Properties for the PDF screen in your Control Panel, do you have anything specified for background image or background color? If so, can you remove that and see what happens? Is blank.png used anywhere else in your application? Mark
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 06:53 PM (14 years ago)
There was a background color use in themes, took it out, no dice. Blank png is is the .m files Bt_background_view.m BT_screen_images.m BT_screen_quiz.m and BT_screen_splash.m Think they are probably there in all apps.
 
stevek
Aspiring developer
Profile
Posts: 808
Reg: Dec 24, 2011
great neck
8,080
like
01/08/12 06:55 PM (14 years ago)
I guess I should say the PDF files were made from Word docx files in word 11 for mac by save as pdf
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/08/12 07:03 PM (14 years ago)
Very strange! Perhaps try another Word to PDF creator? Anything is possible when it comes to Microsoft Office. Mark
 
WolfTimJ
buzztouch Evangelist
Profile
Posts: 810
Reg: Feb 20, 2011
Rockwall, TX
17,400
like
01/08/12 07:49 PM (14 years ago)
I've got Acrobat Pro. If you want I can look at the PDF and see if something is amiss. Send it to me at [email protected] -Tim Wolf
 

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.