Discussion Forums  >  Images, Documents, File Locations

Replies: 8    Views: 118

WebNevees
Code is Art
Profile
Posts: 206
Reg: Oct 28, 2012
KL
11,660
11/19/12 05:05 AM (13 years ago)

Displaying dynamic data or maybe xml

Hi all you energetic fellow "buzztouch"ers you! I'm having problems displaying data in a dynamic way. Actually I need to refresh some data in a table everyday, kind of like a stock market chart. How should I do this so the latest updated data is always viewable in the app (of course with the timestamp) regardless of being connected to the internet. Whenever the device gets an internet connection, it can just update its table (and a new timestamp is shown). Any ideas? Of course I have been fumbling around with XML but to no avail. I can keep my latest data in an xml file on my server. Just retreiving it with the app and storing the info is where I have problems. Thanks in advance
 
theGreek
Aspiring developer
Profile
Posts: 648
Reg: May 25, 2011
Schaumburg, IL
7,830
like
11/19/12 06:17 AM (13 years ago)
Storing it as a PDF, Word Doc, Excel or PPT is one way. It can be stored on Drop box if that works for you. Once the doc changes it will be refreshed... You can do the same with HTML...
 
munny1
Veteran developer
Profile
Posts: 176
Reg: Jun 20, 2012
Earth
8,010
like
11/19/12 07:04 AM (13 years ago)
It sounds like you want auto refresh: (iOS) https://www.buzztouch.com/files/howtos/AutomaticRefresh.pdf
 
ATRAIN53
Code is Art
Profile
Posts: 1755
Reg: Nov 17, 2011
Chicago
26,450
like
11/19/12 07:52 AM (13 years ago)
Sounds like you really want to Parse an remotely stored XML document and display the results in a tableview. For iOS you'll want to check out the NSXMLParser You could also Parse some JSON data too. Not much help for Android Parsing yet, still researching it myself....
 
WebNevees
Code is Art
Profile
Posts: 206
Reg: Oct 28, 2012
KL
11,660
like
11/21/12 06:05 AM (13 years ago)
Thanks everybody for your help. Actually storing it as such a file is good, only for the iphone (@gbakakos). It can open up the file from inside the app. But in android the user has to at first download manually, and then open in an external app(!). Not Cool! But if I store HTML docs, which are pointing to xml files on the web or dropbox, I can actually create the updated table I need. The problem comes up when the app is offline, so the html shows blank! Can't check the rates. That's why I am storing the xml files inside the document folder as well. But I need to be able to automagically (!) refresh or update them (download the new ones) so the rates are always up to date, and online and offline access is granted. @munny1: Thanks, nice trick. I like it, but I don't think it will specifically address my issue. I need to be able to download files from the web (xml, xsl,...) into the docs folder automatically. But will look into it. @ATRAIN53: Yup... that is ideally what I need to do. I am working on the android version right now. Thanks alot for providing me hints at the ios parser.
 
WebNevees
Code is Art
Profile
Posts: 206
Reg: Oct 28, 2012
KL
11,660
like
11/22/12 05:06 AM (13 years ago)
Thanks everybody for your help. Actually storing it as such a file is good, only for the iphone (@gbakakos). It can open up the file from inside the app. But in android the user has to at first download manually, and then open in an external app(!). Not Cool! But if I store HTML docs, which are pointing to xml files on the web or dropbox, I can actually create the updated table I need. The problem comes up when the app is offline, so the html shows blank! Can't check the rates. That's why I am storing the xml files inside the document folder as well. But I need to be able to automagically (!) refresh or update them (download the new ones) so the rates are always up to date, and online and offline access is granted. @munny1: Thanks, nice trick. I like it, but I don't think it will specifically address my issue. I need to be able to download files from the web (xml, xsl,...) into the docs folder automatically. But will look into it. @ATRAIN53: Yup... that is ideally what I need to do. I am working on the android version right now. Thanks alot for providing me hints at the ios parser.
 
ATRAIN53
Code is Art
Profile
Posts: 1755
Reg: Nov 17, 2011
Chicago
26,450
like
12/01/12 09:13 AM (13 years ago)
@webnevees hows the Android progress going? I just got my custom NSXML parser working for iOS. Still need to fine tune it a bit, but i think this might be one I submit for a plug-in. Going to have the BT crew look at it next week. I want to work on the cell layout customization more this weekend if i can find time. It's going to work with a remote URL and populate a tableview and then push a detail view controller to show more info when you select an item. What are you using for Android?
 
WebNevees
Code is Art
Profile
Posts: 206
Reg: Oct 28, 2012
KL
11,660
like
12/03/12 04:48 AM (13 years ago)
Well I've got the parsing done not with the actual android parsing methods, but inside a webview with xslt stylesheets and javascript. I wrote the js code myself for the specific purpose I needed and thus I can now dynamically change my display and update from the xml file stored locally. I did try to use the SAXparser for android though, and it was coming out pretty good. Thanks for the followup. maybe we can get it together later on...
 
ATRAIN53
Code is Art
Profile
Posts: 1755
Reg: Nov 17, 2011
Chicago
26,450
like
12/03/12 08:51 AM (13 years ago)
Thanks - I'm looking at some SAX Parser tutorials now, thanks for the tip there. Seems like it's the parser of choice for Android! I'm working on adding image elements to my table views for the iOS parser. Once done there I'm going to submit to to the BT Market. Maybe we can add/integrate some Android in the future. keep in touch, I'm following you so we can connect down the road...
 

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.