2 Replies Latest reply on Mar 17, 2014 2:20 AM by Bart Fukkink

    Accessing Files on Windows Mobile

    Bart Fukkink



      For a while now, we have a system in our application that can clean up images that are send to and from our RhoMobile application. With this process, we ensure that we reduce the used amount of data on devices to a minimum.


      With the update to RhoMobile Suite 4.0 tho, this system stoppen worden on Windows Mobile devices. When the following code executes, the application just crashes without a log note or an error message. Can anyone tell me what is happening here?


      Device: Motorola MC65 with Windows Mobile 6.5.3.




      # Make a shortcut for the path
      file_data_path = self.join( Rho::Application.userFolder, "workorder_file_data" )
      # Check if its a directory
      if File.directory? file_data_path
        # Go trough all entries
        Dir.new( file_data_path ).each do |entry|
          # Try and delete the files
            File.delete( File.join( file_data_path, entry ) ) unless entry == "." || entry == ".."
            # Do nothing, we`ll try again next time
          end # End begin
        end # End each
      end # End if