Android open file dialog problem

Develop and Deploy Mobile Apps for iPhone, iPad, Windows Phone, webOS, BlackBerry, and Android devices ...
Post Reply
wahono77
Posts: 90
Joined: Sat Apr 13, 2013 6:04 am

Android open file dialog problem

Post by wahono77 »

UI.ComboInput (uploader), in Windows I get full path (folder and filename), but in Android I got filename only. What's wrong there?

Thanks

support
Posts: 356
Joined: Sat Apr 27, 2013 9:22 am

Re: Android open file dialog problem

Post by support »

Did you mean getValue function ?
That depends on the browser.
You can test the following code in Firefox/IE/Chrome/Opera, results are different
   
Class('App', 'xui.Com',{
    Instance:{
        iniComponents : function(){
            // [[Code created by CrossUI RAD Tools
            var host=this, children=[], append=function(child){children.push(child.get(0))};
            
            append(
                (new xui.UI.ComboInput)
                .setHost(host,"ctl_comboinput2")
                .setLeft(250)
                .setTop(80)
                .setType("file")
            );
            
            append(
                (new xui.UI.SButton)
                .setHost(host,"ctl_sbutton5")
                .setLeft(280)
                .setTop(130)
                .setCaption("ctl_sbutton5")
                .onClick("_ctl_sbutton5_onclick")
            );
            
            return children;
            // ]]Code created by CrossUI RAD Tools
        },
        _ctl_sbutton5_onclick : function (profile, e, src, value){
            var ns = this, uictrl = profile.boxing();
            xui.message( ns.ctl_comboinput2.getUIValue())
        }
    }
});
Class('App', 'xui.Com',{
    Instance:{
        iniComponents : function(){
            // [[Code created by CrossUI RAD Tools
            var host=this, children=[], append=function(child){children.push(child.get(0))};
            
            append(
                (new xui.UI.ComboInput)
                .setHost(host,"ctl_comboinput2")
                .setLeft(250)
                .setTop(80)
                .setType("file")
            );
            
            append(
                (new xui.UI.SButton)
                .setHost(host,"ctl_sbutton5")
                .setLeft(280)
                .setTop(130)
                .setCaption("ctl_sbutton5")
                .onClick("_ctl_sbutton5_onclick")
            );
            
            return children;
            // ]]Code created by CrossUI RAD Tools
        },
        _ctl_sbutton5_onclick : function (profile, e, src, value){
            var ns = this, uictrl = profile.boxing();
            xui.message( ns.ctl_comboinput2.getUIValue())
        }
    }
});
   

wahono77
Posts: 90
Joined: Sat Apr 13, 2013 6:04 am

Re: Android open file dialog problem

Post by wahono77 »

Yes, that is what I mean. But in Android I got filename only? path folder didn't included.
Than if I set image.src from sdcard or other places, the image didn't displayed.

Any suggestion?

Thanks

Post Reply