Webclient becomes unresponsive on iPad

Forum to discuss the Web client version of Servoy.

Webclient becomes unresponsive on iPad

Postby wvitpr » Tue Jul 17, 2012 11:53 am

Hello,
After opening any PDF my web solution it just becomes unresponsive on a iPad, not a button will work, it will also do the same thing with other browsers but not as repeatable the only fix is to close the client and re-open which is far from ideal.

Oh, I didnt mention that the first time you open the pdf it works fine, and possibly the second is ok, but 3rd "no good" you need to restart client. Its really frustrating !

code
Code: Select all
function get(rec) {
   
   var fileName = rec.file_name.substr(1)
   
   if(application.getApplicationType() == APPLICATION_TYPES.WEB_CLIENT){
      
         var attachmentFile = plugins.file.convertToJSFile(plugins.file.getDefaultUploadLocation() + rec.file_name);
      //var attachmentFile = plugins.file.convertToRemoteJSFile(rec.file_name)
       
       if (attachmentFile.exists()){
           var fbytes = plugins.file.readFile(attachmentFile);
           plugins.file.writeFile("stream.pdf", fbytes, 'application/pdf');
        }
   }
   else{
      var filePrefix = fileName.substring(1, fileName.lastIndexOf("."))
      var fileSuffix = fileName.substring(fileName.lastIndexOf("."))
      var tFile = plugins.file.createTempFile(filePrefix,fileSuffix)
      plugins.file.streamFilesFromServer(tFile, rec.file_name, get_callback);
   }
}


Servoy version = 5.14
Regards,
Phillip Routley

Worldview IT
Sydney, Australia
User avatar
wvitpr
 
Posts: 219
Joined: Tue Apr 24, 2007 1:38 am

Return to Servoy Web Client

Who is online

Users browsing this forum: No registered users and 5 guests

cron