Browserfield problem

Hello

I'm developing an application (for version 5.0) for a page Web in a browserfield I self-paced successfully but it takes the Web page fit to the screen it seems as compressed. I need to view this Web page with the actual width and height of the webpage... Currently I am add browserfield vertical Manager and give vertical scrolling for the Manager... Now, I want to display the web page as its width and its original height...

You get my point? If not please free to ask...

Can someone explain to me how to display the webpage in real width and height in the browerfield

The following code snippet shows how to set the width of the window you want and the value of the initial scale...

config = new BrowserFieldConfig();
config.setProperty (BrowserFieldConfig.VIEWPORT_WIDTH, whole (new)
(Display.getWidth ()));
config.setProperty (BrowserFieldConfig.INITIAL_SCALE, new Float (1.0));

config.setProperty (BrowserFieldConfig.USER_SCALABLE, Boolean.FALSE);

browserField = new BrowserField (config);

The USER_SCALABLE prevents the user to change the zoom.  You can or don't want according to your code.

VIEWPORT_WIDTH sets the width you want to see.  In our application, limit us the width of the screen and do not allow for scaling.

Tags: BlackBerry Developers

Similar Questions

  • OS5 + BrowserField: Problem closing the browser automatically on redirects

    I'm trying to create a field of browser, search for redirects and close the page, so go back to the last page. Look on the ground of the browser after you have requested a page and receive calls such as documentLoad(), I'm trying to close the screen here. But I get an IllegalStateException: called close() when not displayed.

    I have found nowhere else to listen for events from redirection. Is there a better place to find events in browserField.addListener (...)? One of the methods BrowserFieldListener.downloadProgress () event is not called.

    Have you wrapped closed with a call to invokeLater call?  See the link below for an example.

    Update a screen on the main event Thread

    http://supportforums.BlackBerry.com/T5/Java-development/update-a-screen-on-the-main-event-thread/TA-...

  • Browser BlackBerry facebook SDK login error

    I recently spent to use the SDK Blackberry facebook pot to using the source code of projects (excerpt from the tag that the pot was built in)

    .

    Since this switch, I've known browserfield problems:

    On a device, the load chart persists until I have regularized.

    On a simulator, I see:

    "Error calling content for.

    https://www.Facebook.com/dialog/OAuth?scope=user_about_me, user_activities, user_birthday, user_educati...

    Null error message. »

    where APPLICATION_ID is my correct application ID.

    The URL above will open fine in my PC and even on the browser Blackberry browser when stuck and I debugged for some time by the source of the facebook sdk and found that the earphone returngs browserfield "error: [URL]" when he tries to load the content.

    Has anyone seen similar behavior with the source SDK Blackberry code before?

    Unfortunately time did not allow me to analyse the sample with our tools or to implement the Blackberry eclipse for the trial or the other plugin.

    I went back to using the pot and put in place 2 draw up profiles for 5.0 + (including pot) and pre5.0 (does not include jar).

    Thank you

  • BrowserField encoding problem

    Hello! Please, help me! I spent almost all day, but have had no success. My BrouserField is showing '? ' characters instead of the non-English characters.
    I need to get the Ribbon XML, analyze and display in the BrowserFiled.
    I use these classes:

    (1) WaitScreen - PopupScreen from the example of knowledge base

    public class WaitScreen extends PopupScreen {
    
        private LabelField _ourLabelField = null;
    
        private WaitScreen(String text) {
            super(new HorizontalFieldManager());
            VerticalFieldManager _vfm = new VerticalFieldManager();
            _ourLabelField = new LabelField(text, Field.FIELD_HCENTER);
            _vfm.add(_ourLabelField);
            this.add(_vfm);
            this.setBackground(BackgroundFactory.createSolidTransparentBackground(Color.BLACK, 225));
        }
    
        public static void showScreenAndWait(final Runnable runThis, String text) {
            final WaitScreen thisScreen = new WaitScreen(text);
            Thread threadToRun = new Thread() {
                public void run() {
                    // First, Waintdisplay this screen
                    UiApplication.getUiApplication().invokeLater(new Runnable() {
                        public void run() {
                            UiApplication.getUiApplication().pushScreen(thisScreen);
                        }
                    });
                    // Now run the code that must be executed in the Background
                    try {
                        runThis.run();
                    } catch (Throwable t) {
                        t.printStackTrace();
                        throw new RuntimeException("Exception detected while waiting: " + t.toString());
                    }
                    // Now dismiss this screen
                    UiApplication.getUiApplication().invokeLater(new Runnable() {
                        public void run() {
                            UiApplication.getUiApplication().popScreen(thisScreen);
                        }
                    });
                }
            };
            threadToRun.start();
        }
    }
    

    (2) RSSHandler - class auxiliary for analysis

    public class RSSHandler extends DefaultHandler {
        boolean isItem = false;
    
        boolean isTitle = false;
        boolean isLink = false;
        boolean isDescription = false;
        boolean isPubDate = false;
        boolean isGuid = false;
    
        public String[] title = new String[] {};
        public String[] link = new String[] {};
        public String[] description = new String[] {};
        public String[] pubDate = new String[] {};
        public String[] guid = new String[] {};
        String value = "";
    
        public void startElement(String uri, String localName, String name,
                Attributes attributes) throws SAXException {
            if (!isItem) {
                if (name.equalsIgnoreCase("item"))
                    isItem = true;
            } else {
                if (name.equalsIgnoreCase("title"))
                    isTitle = true;
                if (name.equalsIgnoreCase("link"))
                    isLink = true;
                if (name.equalsIgnoreCase("description"))
                    isDescription = true;
                if (name.equalsIgnoreCase("pubDate"))
                    isPubDate = true;
                if (name.equalsIgnoreCase("guid"))
                    isGuid = true;
            }
        }
    
        public void characters(char[] ch, int start, int length)
                throws SAXException {
            if (isTitle || isLink || isDescription || isPubDate || isGuid)
                value = value.concat(new String(ch, start, length));
        }
    
        public void endElement(String uri, String localName, String name)
                throws SAXException {
            if (isItem && name.equalsIgnoreCase("item"))
                isItem = false;
            if (isTitle && name.equalsIgnoreCase("title")) {
                isTitle = false;
                Arrays.add(title, value);
                value = "";
            }
            if (isLink && name.equalsIgnoreCase("link")) {
                isLink = false;
                Arrays.add(link, value);
                value = "";
            }
            if (isDescription && name.equalsIgnoreCase("description")) {
                isDescription = false;
                Arrays.add(description, value);
                value = "";
            }
            if (isPubDate && name.equalsIgnoreCase("pubDate")) {
                isPubDate = false;
                Arrays.add(pubDate, value);
                value = "";
            }
            if (isGuid && name.equalsIgnoreCase("guid")) {
                isGuid = false;
                Arrays.add(guid, value);
                value = "";
            }
        }
    }
    

    (3) CaptionScreen (screen with BrowserField I need to show the result of the XML parsing)

    public class CaptionScreen extends MyMainScreen
    {
        private BrowserField _browserField;
    
        public CaptionScreen(Application app, String section)
        {
             //....
             GetArticles getArticles = new GetArticles("http://" + _urlWithArticles, _browserField);
             WaitScreen.showScreenAndWait(getArticles, "LOADING");
        }
    
        static class GetArticles implements Runnable {
            String _url = null;
            BrowserField _resultBrowser;
    
            public GetArticles(String urlToGet, BrowserField resultBrowser) {
                this._url = urlToGet;
                this._resultBrowser = resultBrowser;
            }
    
            public void run() {
                // Try to download new articles and parse the answer
                HttpConnection httpConn = null;
                InputStream is = null;
                RSSHandler rssHandler = new RSSHandler();
    
                try {
                    httpConn = GetConnection(_url);
    
                    is = httpConn.openInputStream();
                    try {
                        SAXParser parser = SAXParserFactory.newInstance().newSAXParser();
                        parser.parse(is, rssHandler);
                    }
                    catch (ParserConfigurationException e) {
                        e.printStackTrace();
                    }
                    catch (SAXException e) {
                        e.printStackTrace();
                    }
                    catch (IOException e) {
                        e.printStackTrace();
                    }
                } catch (IOException ioe) {
                } catch (Exception e) {
                } finally {
                    try {
                        if ( httpConn != null ) {
                            httpConn.close();
                        }
                    } catch (Exception e) {
                    }
                    httpConn = null;
                }
    
                final String htmlArticles = generateHtml(rssHandler);
                UiApplication.getUiApplication().invokeLater(new Runnable() {
                    public void run() {
                        _resultBrowser.displayContent(htmlArticles, "");
                    }
                });
            }        
    
            // Method for html generation to showing in BrowserField
            private String generateHtml(RSSHandler rssHandler) {
                String result = "";
                if(rssHandler == null) {
                    return result;
                }
                result += "News";
    
                for(int i = 0; i < rssHandler.title.length; i++) {
                    result += rssHandler.title[i] + "
    " + "LINK
    " + rssHandler.description[i] + " "; } result += ""; return result; } private HttpConnection GetConnection(String _url) throws IOException { if (DeviceInfo.isSimulator()) { _url = _url + ";deviceSide=true"; } MyConnFact _myConnFact = new MyConnFact(); HttpConnection _httpConn = null; ConnectionDescriptor _connDesc = _myConnFact.getConnection(_url); if (_connDesc != null) { _httpConn = (HttpConnection)_connDesc.getConnection(); } return _httpConn; } } }

    It works very well (showing WaitScreeen, data download), but all characters not English shows as '?'
    I found a few discussions with the same problem (especially this one)

    http://supportforums.BlackBerry.com/T5/Java-development/how-to-show-other-languages-in-BrowserField/...

    and this one

    http://supportforums.BlackBerry.com/T5/Java-development/BrowserField-can-not-display-UTF-8-character...

    but I don't understand, how and where do I I implemented HttpConnection in my code.
    Please, give me advice or tell, how I change my code to solve this problem?

  • Problem with the link invoke BrowserField real browser

    I use Custom BrowserField view code html, but when to take the cursor over a link and press on, the menu open the link will display. After clicking, nothing happens.

    I know that to invoke the current browser. Need to uselike

    public Object eventOccurred (Event event) {}

    int eventId = event.getUID ();

    switch (eventId) {}

    case Event.EVENT_URL_REQUESTED: {}
                    
    Private visit = Browser.getDefaultSession ();
    visit.displayPage ("url");
    break;
                    
    }


    The problem is how to o the url link on Custom BrowserField be opened by

    visit.displayPage ();

    He found myself

          case Event.EVENT_URL_REQUESTED: {
    
                    BrowserSession visit = Browser.getDefaultSession();
                    UrlRequestedEvent urlRequestedEvent = (UrlRequestedEvent) event;
                    url = urlRequestedEvent.getURL();
                    visit.displayPage(url);
    
                    break;
    
                }
    
  • Problems with HTTP and BrowserField response Code

    Hello everyone!

    I have a problem.

    I need to know the CODE of RESP HTTP after each query browserField. I studied the API and have not found a way directly (or even indirectly) to get the code from a RESP.

    Even if the page I'm asking returns me a 401, it calls the method documentLoaded of the listener instead of documentError for an example. Also, I implemented a BrowserFieldErrorHandler to see if any of it's method is called when an error occurs, but no! He'll never call them and he will call directly on documentLoaded... And, this method receives an instance document (dom) and the browserField.

    Then... the question... HOW the HTTP RESP. TO GET the code on a request of browserField

    All ideas

    Thanks a bunch already!

    Cheers... FCavalcant

    Well, I got it...

    I read http://supportforums.blackberry.com/t5/Java-Development/How-to-enable-HTTP-Authentication-in-your-Br...

    and it provide me with an indirect way of crazy for the code of httpResponse = /.

    Thank you all!

    FCavalcanti

  • BrowserField + OS 6.0 + loading problem

    Hi all

    I have BrowserField in my application which is part of the screen as other areas as areas of labels.

    Now when the screen is displayed the other fields are displayed first after 1/2 seconds than browserfield loaded then this gives the effect of glitter.

    I want to avoid it... any suggestions for this?

    Note: this problem does not occur on OS 5.0, only happens with OS 6.0

    Kind regards

    Himanshu

    Looks to as problem... tested on device 9800 torch Simulator & it works fine

    Thank you

  • Problem in loading huge data in BrowserField

    Hi, I use the following code to load the content html in BrowserField, it works fine but when html contains the untrapped exception throw huge table data Application when I'm scrolling down

    HorizontalFieldManager hfm = new HorizontalFieldManager(Manager.HORIZONTAL_SCROLL | Manager.VERTICAL_SCROLL);
    
            BrowserField bf = new BrowserField();
            bf.displayContent(mmd.getBody(), "");
            bf.setMargin(new XYEdges(10, 0, 0, 0));
            hfm.add(bf);
            add(hfm);
    

    Help, please

    In fact the problem is not in the BrowserField, inside, I was doing the analysis, now, I separated the code got solved the problem.

  • Problem with Spotlight fields with the higher priority than browserfield

    It comes to JRE6.

    Some Web sites make a redirect of content or another ajax request when the document is loaded.  When the screen contains a browserfield and a focusable field with a higher priority, an illegal state Exception is thrown by the browser because it is not to the point when the content refreshes the field.  (As in defining BrowserField.setFocus () before calling BrowserField.refresh ()).

    Example: http://supportforums.blackberry.com/t5/Java-Development/BrowserField-Sample-Code-Create-your-first-B...

    Using the code of the BrowserField2 example, simply by adding a ButtonField in the survey except title when navigating to twitter.com.  Other sites work fine, but when the content/javascript is in a certain way on Twitter, she seems to have some problems.

    package mypackage;
    
    import net.rim.device.api.ui.component.ButtonField;
    import net.rim.device.api.ui.container.*;
    import net.rim.device.api.browser.field2.*;
    import net.rim.device.api.ui.*;
    
    class MyBrowserField2Sample extends UiApplication
    {
        private MainScreen _screen;
        private BrowserField _bf2;
        private ButtonField btnField;
    
        MyBrowserField2Sample()
        {   
    
            btnField = new ButtonField();
            btnField.setLabel("A BUTTON");
    
            _bf2 = new BrowserField();
    
            _screen = new MainScreen();
            _screen.setTitle(btnField);
            _screen.add(_bf2);
            pushScreen(_screen);
    
            _bf2.requestContent("http://www.twitter.com");
        }
    
        public static void main(String[] args)
        {
            MyBrowserField2Sample app = new MyBrowserField2Sample();
            app.enterEventDispatcher();
        }
    }
    

    The code above throws an illegal state exception at startup.  If you delete the setTitle (or any field focusable) that has a higher priority than the browserfield, so it works well.

    How can I force the focus on the browserfield when she needs?

    I Googled, found issues similar and all say "force focus on the browserfield", but even if you force the focus, the same illegal state occurs due to the updating of the content.

    Thanks in advance,

    Nate

    After reviewing the matter further, the problem may be to the field focusable, but it doesn't have to be on top.  Basically, any field focusable on the same screen as the browserfield throws the exception.

    While going to twitter.com in blackberry browser works very well (sends you to the mobile site), this behavior causes problems with the browserfield.

    The workaround, is just to force the link to open the mobile site directly.

  • Problem by opening a pdf url in a BrowserField of an application.

    Feature: 9530 (Simulator)

    Device and App OS: 5.0

    BES version: 4.1.7.18

    Device Manager: 5.0.1.20

    Desktop Manager: 5.0.1

    I need to open files PDF url my request. Initially, I discovered that a normal MDS Simulator will not open a PDF in a BlackBerry Simulator

    http://supportforums.BlackBerry.com/T5/Web-development/viewing-PDF-through-Simulator/m-p/25503#M81

    and I need a BES for this, so I installed BES and after a lot of turning around, I managed to do the work. From now on, I can open the url of the pdf and all the other URLS in the native browser of my Blackberry Simulator. But when I try to open the pdf from an application url by using a browserField it does not.

    I tried to use the simple browserField sample provided with the API

    http://www.BlackBerry.com/developers/docs/5.0.0api/NET/rim/device/API/browser/Field2/BrowserField.ht...

    I tried to use a KB browserField sample (in desperation really, I dunno what it does)

    http://supportforums.BlackBerry.com/T5/Java-development/BrowserField-sample-code-using-the-BrowserFi...

    Even tried using the code example given in the book of Apress Advanced BlackBerry development by Chris King . Here is the code for anyone who is interested to have a look

    import java.io.IOException;
    import java.util.*;
    
    import javax.microedition.io.*;
    
    import net.rim.device.api.browser.field.*;
    import net.rim.device.api.io.http.HttpHeaders;
    import net.rim.device.api.system.Application;
    import net.rim.device.api.ui.*;
    import net.rim.device.api.ui.component.LabelField;
    import net.rim.device.api.ui.container.*;
    
    public class BrowserScreen extends MainScreen implements Runnable,
            RenderingApplication
    {
        private RenderingSession renderSession;
        private LabelField status;
        private StatusUpdater updater;
        private String url;
    
        public BrowserScreen()
        {
            renderSession = RenderingSession.getNewInstance();
            status = new LabelField("Loading...");
            add(status);
            updater = new StatusUpdater(status);
            url = "http://www.google.com";
            (new Thread(this)).start();
        }
    
        private class BrowserFieldContainer extends VerticalFieldManager
        {
            public BrowserFieldContainer()
            {
                super(Manager.VERTICAL_SCROLL | Manager.VERTICAL_SCROLLBAR
                        | Manager.FIELD_HCENTER);
            }
    
            public void sublayout(int maxWidth, int maxHeight)
            {
                int width = BrowserScreen.this.getWidth();
                int height = BrowserScreen.this.getHeight();
                super.sublayout((int) (width * .9), height / 2);
            }
        }
    
        public void run()
        {
            HttpConnection conn = null;
            try
            {
                conn = (HttpConnection) Connector.open(url);
                updater.sendDelayedMessage("Connection opened");
                BrowserContent browserContent = renderSession.getBrowserContent(
                        conn, this, null);
                if (browserContent != null)
                {
                    Field field = browserContent.getDisplayableContent();
                    if (field != null)
                    {
                        synchronized (Application.getEventLock())
                        {
                            deleteAll();
                            add(status);
                            add(new LabelField("Your search starts here."));
                            BrowserFieldContainer container =
                                new BrowserFieldContainer();
                            container.add(field);
                            add(container);
                            add(new LabelField("Don't forget to tip the service!"));
                        }
                    }
                    browserContent.finishLoading();
                }
            }
            catch (Exception e)
            {
                updater.sendDelayedMessage(e.getMessage());
            }
            finally
            {
                try
                {
                    if (conn != null)
                    {
                        conn.close();
                    }
                }
                catch (Exception e)
                {
                }
            }
        }
    
        public Object eventOccurred(Event event)
        {
            if (event.getUID() == Event.EVENT_URL_REQUESTED)
            {
                UrlRequestedEvent urlRequestedEvent = (UrlRequestedEvent) event;
                url = urlRequestedEvent.getURL();
                (new Thread(this)).start();
            }
            updater.sendDelayedMessage("Handle event " + event.getUID() + " for "
                    + event.getSourceURL());
            return null;
        }
    
        public int getAvailableHeight(BrowserContent browserContent)
        {
            return getHeight() / 2;
        }
    
        public int getAvailableWidth(BrowserContent browserContent)
        {
            return (int) (getWidth() * .9);
        }
    
        public String getHTTPCookie(String url)
        {
            return null;
        }
    
        public int getHistoryPosition(BrowserContent browserContent)
        {
            return 0;
        }
    
    protected HttpConnection getResourceConnection(String url,
            HttpHeaders requestHeaders)
    {
        HttpConnection connection = null;
        try
        {
            connection = (HttpConnection) Connector.open(url);
            if (requestHeaders != null)
            {
                Hashtable headers = requestHeaders.toHashtable();
                if (headers != null)
                {
                    Enumeration names = headers.keys();
                    while (names.hasMoreElements())
                    {
                        String name = (String) names.nextElement();
                        String value = (String) headers.get(name);
                        connection.setRequestProperty(name, value);
                    }
                }
            }
        }
        catch (IOException ioe)
        {
            updater.sendDelayedMessage(ioe.getMessage());
        }
        return connection;
    }
    
        public HttpConnection getResource(final RequestedResource resource,
                final BrowserContent referrer)
        {
            if (resource == null || resource.isCacheOnly())
            {
                return null;
            }
    
            String url = resource.getUrl();
    
            if (url == null)
            {
                return null;
            }
    
            if (referrer == null)
            {
                return getResourceConnection(resource.getUrl(), resource
                        .getRequestHeaders());
            }
            else
            {
                (new Thread()
                {
                    public void run()
                    {
                        HttpConnection connection = getResourceConnection(resource
                                .getUrl(), resource.getRequestHeaders());
                        resource.setHttpConnection(connection);
                        referrer.resourceReady(resource);
                    }
                }).start();
            }
            return null;
        }
    
        public void invokeRunnable(Runnable runnable)
        {
            (new Thread(runnable)).start();
        }
    
    }
    

    I can open google.com and other pages in my application using the above given alternatives, but cannot open a PDF url. And the pdf file opened fine in the browser BlackBerry local. I'm getting a little desperately need help now. All that I can appreciate.

    Much obliged.

    The field of browser does not support the rendering of PDF files.  There is no API in the set of BlackBerry APIs that allow you to programmatically display one PDF other then opening the BlackBerry browser the URL of your PDF file, which must point to a web server.

  • BrowserField rendering problems

    Hello

    I am writing an application that uses the BrowserField for OS 4.6. I use the code provided in the example called BrowserFieldDemo to try to open the following link:

    https://Graph.Facebook.com/OAuth/Authorize?client_id=250246779365&redirect_uri=http://www.omnicoretech.com/fb/footprints/oauth_redirect.php&display=wap

    The code retrieves and displays the page. However, some of the characters are rendered as boxes and not the actual characters

    The following is a snippet of code that sets the options for my browserfield

     _renderingSession.getRenderingOptions().setProperty(RenderingOptions.CORE_OPTIONS_GUID, RenderingOptions.JAVASCRIPT_ENABLED, true);
            _renderingSession.getRenderingOptions().setProperty(RenderingOptions.CORE_OPTIONS_GUID, RenderingOptions.ENABLE_CSS, true);
            _renderingSession.getRenderingOptions().setProperty(RenderingOptions.CORE_OPTIONS_GUID, RenderingOptions.OVERWRITE_CHARSET_MODE, true);
            _renderingSession.getRenderingOptions().setProperty(RenderingOptions.CORE_OPTIONS_GUID, RenderingOptions.WAP_MODE, true);
    

    When I call connection getType() method, the return type is

    Connection type: application/xhtml + xml; Charset = UTF-8

    No idea why I see blocks instead of some words?

    Well, I made my change Spanish to English with this code:

  • Reg BrowserField Navigation problem

    Hi all

    I'm opening url using the browser field. now, if I clicked on a hyperlink or menu options, I need to get the url and the url I need to navigate a few other custom screen-based. How to implement these thing. If anyone knows then please answer me...

    Thank you and best regards,

    S.Seshu

    indexOf (...)! = - 1

  • Why BrowserField demo does not use BrowserField?

    I had some problems getting the BrowserField object to display all images on a page. When you search the formus, it was suggested to use the BrowserFieldDemo included in JDE for example. I tried and it works, but the back button does not work and you can not click on one of the links. Then I discovered that it does not actually use a BrowserField object as in

    net.rim.device.api.browser.field2.BrowserField
    

    Does anyone know how to make the browserField to work... WITH a functional back button and no image broken?

    I'd appreciate all point in the right direction.

    In fact, I realized that BrowserField demo uses OS 4.0 components while the BrowserField object is only OS 5.

  • BlackBerry - problem downloading file

    I want to be able to download files via the java app BB

    first attempt:

    I create browserfield to call 'upload.php' and send the file dirrectly from this page, but got the following error message

    [24941.271] VM: + GC (f) w = 11
    [24942.203] VM:-GCt = 119, b = 1, r = 0, g = f, w = 11, m = 0
    [24942.264] VM:QUOT t = 8
    [24942.264] VM: + CR
    [24942.287] VM:-CR t = 3
    [24943.78] type of bridge: 5 PID: 149 Exception loading URL: net.rim.device.internal.bridge.BridgeDatagramTooLa

    RGEException [24943.78]: size of datagram Bridge: 8295740 exceeds the maximum: 1048576
    [24943.78] AM: output net_rim_bb_browser_olympia_proxy (397)
    [24943.78] net_rim_bb_browser_olympia_proxy cleaning (397) process that is started
    [24943.78] type of bridge: 5 PID: 149 cleaning process Java run
    [24943.787] VM:EVTOv = 7680, w = 201
    [24943.787] type of bridge: 5 PID: 149 disconnection
    [24943.787] type of bridge: 5 PID: 149 uninit
    [24943.797] type of bridge: 7 PID: 149 cleaning process Java run
    [24943.805] type of bridge: 7 PID: 149 disconnection
    [24943.812] type of bridge: 7 PID: 149 uninit
    [24943.812] type of bridge: 5 PID: 149 uninit

     

    second attempt:

    Oh... I thought I can solved this problem by creating a loading screen to read data from the file and send it to 'upload.php' as a type string or one he calls binary data may be...

    I followed the instructions in the following thread

    http://supportforums.BlackBerry.com/T5/Java-development/problem-how-to-upload-file-to-server/m-p/186... and... many other thread

    Pro:

    1. I can send text file on the server with the size< 100kb,="" it="" can="" be="" bigger="">

    disadvantages:

    1. only works with "interface = wifi", other type as Boolean deviceside does not work

    2. when I tried to download an image type ' image/jpeg', the compiler returns the following error

    [9852.57] GS (createSurface): promote temporarily the size of the window
    [9852.585] VM:EVTOv = 1, l = 31
    [9852.585] CMM: CreateFileApp (970) No sig 0 x 424252
    [9852.601] VM:EVTOv = 1, l = 31
    [9852.617] VM:EVTOv = 1, l = 31
    [9852.617] BRM:IDL +.
    [9852.625] BRMR +.
    [9852.625] BRM:NMC:393216
    [9852.625] BRM:JFR:92175860
    [9852.671] VM:EVTOv = 1, l = 31
    [9852.687] VM:EVTOv = 1, l = 31
    [9852.703] VM:EVTOv = 1, l = 31
    [9852.75] VM:EVTOv = 1, l = 31
    [9852.75] BRMR -.
    [9852.75] BRM:NMC:393216
    [9852.75] BRM:JFR:92175860
    [9852.75] BRM:IDL -.
    [9852.812] VM:EVTOv = 1, l = 31
    [9853.0] - 1
    [9854.257] VM:RTMSh = 134, o = 0x34101C00, p = net_rim_bb_trust_application_manager
    [9854.257] VMPRMv = 1
    [9854.265] AM: output net_rim_bb_trust_application_manager (388)
    [9854.304] VM:EVTOv = 7680, w = 194
    [9854.312] net_rim_bb_trust_application_manager cleaning (388) process that is started
    [9854.312] net_rim_bb_trust_application_manager cleaning (388) process
    [9864.101] server response: IMG-20130324 - 00241.jpg
    0
    error

    [9866.492] JVM: bklt @9866492: timer
    [9866.492] JVM: bklt [1] @9866492: usrIdle 14, usrTime 30, usrAct 1
    [9866.492] JVM: bklt [1] @9866492: chkIdle currTime 29, 31
    [9866.492] JVM: bklt @9866492: setTimer 16

    then I want to have a dead-end in my way... but what facebook, twitter etc. Use to upload the local file on their server ?

    additions to Split into pieces

  • BlackBerry BrowserField: The Application crashes while downloading.

    Hi, I use browserfield2 in my application to load Web pages, now the problem is the application is always unexpected crashes while downloading, no problem to download the file with size < 500kb="" but="" if="" the="" file="" has=""> = 1 mb size it will crash, the strange thing is I can get download process finished with the construction in the Blackberry browser, hmm... any guy of solution? Thanks in advance

    Here is the code

    public BrowserDemoScreen()

    {
    setTitle ("BrowserFieldScreen");
    BrowserFieldConfig config = new BrowserFieldConfig();
    config.setProperty (BrowserFieldConfig.USER_AGENT, ' MyApplication 1.0 "');
    BrowserField _bf2 = new BrowserField (config);
            
    _bf2 = new BrowserField();
    _bf2.requestContent ("http://mydomain/upload.php");
    Add (_bf2);
    }

    HTML form





    php code

    <>
    $uploaddir = '. / uploads /';
    $filename = $_FILES ['uploadfile'] ['name'];
    $filesize = $_FILES ['uploadfile'] ['size'];
    $filetemp = $_FILES ['uploadfile'] ['tmp_name'];
    $file = $uploaddir. baseName($_files['uploadfile']['name']);

    echo $filename. »
    ";
    echo $filesize. »
    ";
    echo $filetemp;

    If (move_uploaded_file ($filetemp, $file))
    {
    echo "success."
    }
    on the other
    {
    echo "error";
    }
    ?>

    as you can see that I did not use any javascript on this page, it's pure php, which makes the BrowserField crash?

    The solution is:

    public class resignation against UiApplication

    {

    public Resignation()

    {

    If (filesize > = 1 MB)

    Dialog.Alert ("use your personal desktop computer to download selected file!");

    on the other

    Dialog.Alert ("good boy, now, you understand that we have maximum file download size limit");

    Close();

    }

    }

Maybe you are looking for

  • Photos closes unexpectedly

    Opens the photos and then crashes, report below the quantity.  I have fixed the photo library, started without danger, downloaded the new OS X.  Configure another account of Photo that doesn't crash.  Thanks in advance for any advice.  Jim Process: P

  • WMP 11 crashes when you add media to the library from an external HARD drive

    WMP 11 problem! I have win XP and current run WMP 11, I try to add data to my library on an external HARD drive, the player begins to add and then crashes... I tried rebulding, clear memory cache and re - install the software... I also tried the HARD

  • Internal Assistant photo printing error

    I felt a huge dam when trying to print pictures. When you use the wizard to attempt to print one or more photos, I get to the section where I can choose the print size, and I am stopped by an internal error. I use a Dell AIO 922 Printer and I tried t

  • the phone activation Windows 7 doesn't have, said "there seems to be a technical problem, please try again later."

    I have a Windows 7 Home premium 64 bit license that I installed and tried to activate it on my PC. He asked me to validate through automated phone system, as usual, but after entering the nine sets of codes, it says "Please wait while we retrieve you

  • USB device not found

    from a windows 7 update may 10, ive been unable to use a linsys usb adapter model wusb100 on my computer. When I go into Device Manager "unknown device" appears under Universal Serial Bus controllers. Ive uninstalled and reinstalled the drivers for t