hey. I was wondering what the easiest way is to load text external from say a txt. file ? and just sorta a bit extra what is the easiest way to put text onto an app like give infomation and such like. sorry if this does not exactly make sense im quite new to all this. Thanks
Try This Code: var data = new Data(); data.loadFromFile("text.txt"); var text = data.asString(); It works for me...
sorry for being sorta noobish but is there something else i am missing and need to add to get it to show up on my ipods screen?
Code: var data = new Data(); data.loadFromFile( "text.txt"); var text = data.asString(); var popup = new UIAlertSheet( "Text:", [ text ] , 1 ); popup.popupAlertAnimated( true ); PD: ricardofelix95 try to help instead of criticize...
this should help. var daata = new Data(); daata.loadFromFile(Bundle.pathForResource("test.txt")); log("Data= " + daata.asString()); var atextbox = new UITextView( [ 20 , 52 , window.bounds[2]-40 , 150 ] ); atextbox.text = daata.asString(); atextbox.editable = false; mainView.addSubview( atextbox );