How popup screen description on html?

Location:

After document. Write(), the application is stopped.

Question:

How popup screen description on html?

You know that the following code is incorrect or other issues?

Purpose:

Display content on the screen.

Minmum coding: (three methods are good to try, but fail)

Method1

function help() {}
var myWindow = window.open (", 'Help', 'width = 600, height = 200');

...........stop here..........................
myWindow.document.write(")

To start

");
myWindow.focus ();

Methode2
popup var = window.open (", 'Help', 'width = 600, height = 200');

...........stop here..........................
var doc = popup.document;

doc. Write(")

To start

");
}
Method 3
function help (id) {}

var content = document.getElementById (id) .innerHTML;

var generator = window.open (", 'name', 'height = 600, width = 200');

...........stop here..........................
Generator.document.Write (')Popup');

Generator.document.Write (')');

Generator.document.Write (')

This page

');

Generator.document.writeln (content);

Generator.document.Write (')');

Generator.document.Close ();

}

If you know how to solve the problem, please let us know your suggestion or solution.

Fight with the Playbook.

Never (never never) use document.write. It can cause much more harm and confusion than good.

If you want to display a dialog box that is customized with the text inside, the simplest is to use jQuery Mobile:

http://jquerymobile.com/Demos/1.2.0-Beta.1/docs/pages/page-dialogs.html

Otherwise, you can create your own by using a

element with some custom CSS, like this

HTML:

this is my description

CSS:

.dialog {
   max-width: 30em;
   border: solid 0.25em black;
   background-color: #ddd;
   padding: 1em;
   display: inline;
   position: relative;
   left: 10em;
   top: 3em;
}

Tags: BlackBerry Developers

Similar Questions

  • How popup screen when you run another application

    I want to design an application running in background when an event is active as you receive a mail, the application will appear a screen and show some info. How to implement, which can help me, thanks

    Using messageAdded method, try something like this...

    Application.getApplication().invokeLater(new Runnable()
    {
       public void run()
       {       UiEngine ui = Ui.getUiEngine();       Dialog dialogScreen = new Dialog(Dialog.D_YES_NO, "Your Message Text here...",                Dialog.NO,Bitmap.getPredefinedBitmap(Bitmap.INFORMATION),Manager.VERTICAL_SCROLL);       ui.pushGlobalScreen(dialogScreen,1,UiEngine.GLOBAL_MODAL);   }
    }
    
  • How to close a popup screen pushed as a global screen

    I want to close a popup screen but my application is in background so

    UiApplication.getUiApplication () .popScreen (getScreen ());

    or

    UiApplication.getUiApplication () .getActiveScreen () m:System.NET.Sockets.Socket.close ();

    does not work is not something

    same Ui.getUiEngine () .getActiveScreen () m:System.NET.Sockets.Socket.close () does not work...

    in the popup screen, I have a custoListView (written own filed) there is an item when you click on an event

    listner function is called by there, I have to close popup screen... my class is like that

    SerializableAttribute public class SelectSms extends PopupScreen {}

    private vector _data;

    public boolean onClose() {}
    try {}
    Close();
    Returns true;
    } catch (Exception e) {}
    Returns false;
    }
    }

    public SelectSms() {}
    Super (new VerticalFieldManager(), Field.FIELD_VCENTER);
    _data = null;
    _data = MessageStore.getMessage ();
    last post [] message = Message [_data.size (new)];
    MSGC [] CustomListField = null;
    MSGC = new CustomListField [_data.size ()];
    for (int i = 0; i)<>
    message [i] = (Message) _data.elementAt (i);
    MSGC [i] = new CustomListField (message [i] .getMSG_BODY (), message [i] .getMSG_NO (), and [i] .getMSG_STUS ());
    last post mesg = message [i];
    MSGC [i] .setChangeListener (new FieldChangeListener() {}
    ' Public Sub fieldChanged (field field, int context) {}
    onClose();
    }
    });
    Add (MSGC [i]);
    }
    can someone help me how to close the popup screen.
            
    }
    }

    Place the UiApplication.popScreen () call in an executable object and pass this object to UiApplication.invokeLater ().

  • I'm working with Acrobat XI and when I try to add text to the geopdf file I get a popup screen that says it is a secure document and editing is not allowed. How can I fix it?

    I'm working with Acrobat XI and when I try to add text to a geopdf file I get a popup screen that says it is a secure document and editing is not allowed. How can I fix it?

    I thought about it... need to use the defined comment tool, not the set of editing tools.

  • How to recover data from an editable on a Popup screen field

    I have a popup screen that consist of two edit fields that contain the end and address of starting point. It seems that I can't recover the data that are filled in the fields. I would use the address to find the latitude and longitude in an attempt to invoke the map.

    CustomPopup screen = new CustomPopup(myAddress, data.getAddress());
         _controller.getUiApplication().pushModalScreen(screen);
    String newEndPoint = screen.getEndPoint();
    String newStartingPoint = screen.getStartingPoint();
    
     public CustomPopup(String sPoint, String ePoint)
        {
           super(new VerticalFieldManager());
    
           XYEdges thickPadding = new XYEdges(1,1,1,1);
    
           LabelField endDirection = new LabelField("End Point:");
             add(endDirection);
    
           EditField endPoint = new EditField("",ePoint.toString());
           Border eBorder = BorderFactory.createRoundedBorder(thickPadding, Border.STYLE_SOLID);
           endPoint.setBorder(eBorder);
           add(endPoint);
           add(new EditField(Field.NON_FOCUSABLE));
    
           LabelField startDirection = new LabelField("Start Point:");
             add(startDirection);
    
           EditField startingPoint = new EditField("",sPoint.toString());
           Border sBorder = BorderFactory.createRoundedBorder(thickPadding, Border.STYLE_SOLID);
           startingPoint.setBorder(sBorder);
           add(startingPoint);
           add(new EditField(Field.NON_FOCUSABLE));
    
           okButton = new ButtonField("OK", ButtonField.CONSUME_CLICK | Field.FIELD_HCENTER);
             okButton.setChangeListener(this);
             add(okButton);
    
        }
         public String getEndPoint()
         {
              if (endPoint == null) {
                  Dialog.alert("You must enter an Address!");
            }
            else
            {
                  return endPoint.getText();
            }
               return null;
         }
    
          public String getStartingPoint()
           {
               if (startingPoint != null) {
                   return startingPoint.getText();
    
              }
               return null;
           }
    
           public void fieldChanged(Field field, int context) {
               if (field == okButton) {
                   close();
              }
           }
    

    Hello

    Add the statement as startingPoint.setText (startingPoint.getText ()) and endPoint.setText (endPoint.getText ()) after creating the instance of starting point and the end point.  I think that this will solve your problem.

    -Roshn

    Press the button so resolute Bravo

  • How to make a Popup screen

    I really need help. I can't find anything specifically about this in the forum. I am very new and everything on the forum talking about things that I don't even understand yet; As the resolution of problems.

    I want just a genius to help me do that. I want to click a button and have a smaller popup screen with more buttons of your choice. That's all. Please help someone.

    The tutorials already on the site (as pdf files) are not helping. She only gives a big piece of code without explanation. I really need to understand on this.

    Hi coilfyzx,

    To create your own popupscreen, you must extend the PopupScreen class to your class. And you must provide a handler delegate to this extended class to manage presentations.

    public class popupScreen extends PopupScreen implements FieldChangeListener {
          private ButtonField mOKButton,mCancelButton;
          popupScreen(){
    
              super(new VerticalFieldManager(NO_VERTICAL_SCROLL | USE_ALL_HEIGHT), PopupScreen.DEFAULT_CLOSE);
    //here verticalfieldmanager is the delegate manager
    
           HorizontalFieldManager hfm = new HorizontalFieldManager(FIELD_HCENTER);
    
            mOKButton = new ButtonField("OK", ButtonField.CONSUME_CLICK);
            mOKButton.setChangeListener(this);//this is to listen for button click event
            hfm.add(mOKButton);
            mCancelButton = new ButtonField("Cancel", ButtonField.CONSUME_CLICK);
            mCancelButton.setChangeListener(this);
            hfm.add(mCancelButton);
    
    // now you can add your buttons here.
    
          }
    /*FieldChangeListener is for button click event in the popupscreen. For this you should implement the method fieldChanged because FieldChangeListener is an interface */
    
    public void fieldChanged(Field field, int context) {
            if (mOKButton == field) {
                //do whatever you want
                close();
            }
            else if (mCancelButton == field) {
                close();
            }
    }
    //this is for back button on device, when click pop this popupscreen
    protected boolean keyChar(char key, int status, int time) {
            if (Keypad.KEY_ESCAPE == key) {
                this.close();
                return true;
            } else
                return super.keyChar(key, status, time);
        } 
    

    Sorry I forgot to add hfm their.

    push this screen like below

    popupScreen _popupScreen = new popupScreen();
    UiApplication.getUiApplication () .pushModalScreen (_popupScreen);

    Thank you & best regards

    pp

  • How do I close the popup screen

    Hey, I opened a popup screen on the click of a menu item

    now, if the user presses the ESC key

    the pop-up screen should close

    I tried in a certain way, but does not work what to do

     protected boolean keyChar(char c, int status, int time)
            {
                 boolean retVal = false;
    
                if (c == Characters.ESCAPE)
                {
                    close();
                    UiApplication.getUiApplication().invokeLater(new Runnable()
                    {
                        public void run()
                        {
                            UiApplication.getUiApplication().popScreen(filter);
                            UiApplication.getUiApplication().popScreen(UiApplication.getUiApplication().getActiveScreen());//(filter);
                        }
                    });
                    retVal = super.keyChar(c,status,time);
    
                }
                return retVal;
            }
    

    kindly help what to do.

    the popup screen is blocked unless I click on a button on the pop-up screen for certain work

    What to do?

    Your pop-up screen should respond the the ESC key by calling the close() method.

    Override keyChar() in the pop-up screen, search for the ESC key and call close().

  • Creating Popup screen without borders

    Hello everyone,

    I'm developing an application in which I use the pop-up screen.

    but the popup screen comes with white border by default.

    How do I remove the border pop-up screen white default.

    If possible can someone explain to me with the code snippet?

    Thanks in advance

    Hi Amit,

    I think this thread will be useful for you

    http://supportforums.BlackBerry.com/T5/Java-development/PopupScreen-with-transparent-background-and-...

  • Close popup screen programmatically

    I have a popup screen that I displayed to inform the user that they are wating on entry. When I try to close it in my earpiece method it gives the error:

    IllegalStateException - UiEngineImpl.assertHaveEventLock)

    I push the pop-up screen on the stack using a runnable.invokeAndWait and push as a ModalScreen because otherwise it will not show.

    What is the error of assertHaveEventLock for, and why the window display not using invokeLater and pushScreen?

    The IllegalStateException is thrown because the thread that calls the close method (the listener) is not the thread main event.  Calling the method close must occur in a block, as described on the next page.

    How - to upgrade a screen on the main event Thread
    Article number: DB-00136

    http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800505/800256/...

  • How to install the plugin html on OS 10.11.6

    How to install the plugin html on OS 10.11.6

    For html5, you mean? Your browser must be able to show html5 without plugins.

    If something does not work for you, please explain what it is.

  • List items are overlapped on popup screen

    Hi all

    I'm developing an application in which i use a popup screen and I have an ist of all data on the device (memory a sd card in the device). I show these data in a list and with a few images and checkboxes. My problem is that when I scroll or scroll through list items upward, are overlapped and yet when I scrolling to a particular element, only this element comes to its normal state.

    And this behavior is only broadcast on the devoce but when I run the same code on Simulator it works very well without any problems!

    Why this is happening? Any idea?

    Help, please!

    Thank you..

    Thnx for your help...

    My problem is solved...

    I was doing loads of operations under oaint method...

    Thank you very much...

  • Conditional call forwarding and popup screen.

    Hi all

    I push a pop-up screen to cover a call out with my own information. However on my device and several others, a pesky "conditional call forwarding" popup is displayed by the phone which briefly takes precedence over my popup screen. Is this anyway to prevent this.

    I push the screen by using the following code.

    UiApplication.getUiApplication().pushGlobalScreen(activeOutDialScreen, 0,UiEngine.GLOBAL_SHOW_LOWER) ;
    

    I tried setting the summary field on a few different things, but nothing can stop the pop-up conditional reference poster.

    Any help or just confirming, that it is not possible would be greatly appreciated.

    Kind regards

    Alan

    None

  • How can we enable the html mode of the e-mail to the 9800 blackberry Simulator

    How can we enable the html mode of the e-mail to the 9800 blackberry Simulator?

    When I sent messages html Simulator, it only shows text.

    the Simulator does not support html emails

  • Popup screen problems

    I've tried using the search tool and google my whole day, but I can't seem to find the answer to these two problems.

    1. I'm positioning my pop-up screen in the middle of the screen. But as you can see in the image below it is nowhere near the Center.

    2. I'm trying to focus my two buttons in the middle of the popup screen with a verticalfieldmanager, but somehow it is fondant a position according to the width, I don't know what.

    Here is the code:

    private final static int _Width = 200;private final static int _Height = 200;private final static int _X = (Display.getWidth() - _Width) >> 1;private final static int _Y = (Display.getHeight() - _Height) >> 1;public class NetworkSettingScreen extends PopupScreen{
    
    public NetworkSettingScreen(){   super( new VerticalFieldManager());   LabelField lf = new LabelField("Network Settings", DrawStyle.HCENTER);    SeparatorField sf = new SeparatorField();         CheckboxField cbf1 = new CheckboxField(" WiFi", true);    CheckboxField cbf2 = new CheckboxField(" GPRS/Edge/3G", true);
    
      VerticalFieldManager vfm = new VerticalFieldManager(HorizontalFieldManager.FIELD_HCENTER);    ButtonField bf1 = new ButtonField("Save", DrawStyle.HCENTER); ButtonField bf2 = new ButtonField("Cancel", DrawStyle.HCENTER);   vfm.add(bf1); vfm.add(bf2);
    
      //add UI components to Pop-up screen  add(lf);  add(sf);  add(cbf1);    add(cbf2);    add(vfm);}
    
    public void sublayout(int width, int height){   super.sublayout(width, height);   setExtent(_Width, _Height);           setPosition(_X, _Y);}}//end of class
    

    http://i55.Photobucket.com/albums/G152/chengbang69/screenshot.jpg

    any help would be appreciated

    Hey chengbang69,

    I modified your code to obtain the expected results,

    final class NetworkSettingScreen extends PopupScreen
    {
        private final static int _Width = 200;
        private final static int _Height = 200;
        private final static int _X = (Display.getWidth() - _Width) >> 1;
        private final static int _Y = (Display.getHeight() - _Height) >> 1;
    
    public NetworkSettingScreen()
    {
        super( new VerticalFieldManager());
        LabelField lf = new LabelField("Network Settings", LabelField.FIELD_HCENTER);
        SeparatorField sf = new SeparatorField();
        CheckboxField cbf1 = new CheckboxField(" WiFi", true);
        CheckboxField cbf2 = new CheckboxField(" GPRS/Edge/3G", true);
    
        VerticalFieldManager vfm = new VerticalFieldManager(VerticalFieldManager.FIELD_HCENTER);
        ButtonField bf1 = new ButtonField("Save", ButtonField.FIELD_HCENTER);
        ButtonField bf2 = new ButtonField("Cancel", ButtonField.FIELD_HCENTER);
        vfm.add(bf1);
        vfm.add(bf2);
    
        //add UI components to Pop-up screen
        add(lf);
        add(sf);
        add(cbf1);
        add(cbf2);
        add(vfm);
    }
    public int getPreferredWidth() {
        return _Width;
    }
    public int getPreferredHeight() {
        return _Height;
    }
    
    public void sublayout(int width, int height)
    {
        super.sublayout(getPreferredWidth(), Integer.MAX_VALUE);
        setExtent(getPreferredWidth(), getPreferredHeight());
        setPosition(_X, _Y);
    }
    }//end of class
    

    The reason why you need to replace getPreferredHeight() and getPreferredWidth() is due to all subcalls and sublayouts which actually occur when you call super.sublayout. It will then use the 'default' screen page or getPreferredWidth/height.

    Just a friendly recommendation, adjusting the size of a screen to a static value is effective only if you also check the size of the font, currently if the user has a font above average size, a part of the text will not be seen, so, technically, the most effective way is to have the JAVA virtual machine to manage the resizing/flaking itself This can be done by simply using the same code that I posted above, however remove the substitution on sublayout, the width will be slightly larger that you set but at least you won't encounter unknowns.

    Hope this helps,

    Concerning

    André

  • How to compose messages in HTML format in Windows Live Mail?

    I'm still trying to get used to Windows Live Mail, after having upgraded from Windows XP to Windows 7, 64-bniy Home Premium edition on my new PC.

    I would like to know how to compose messages in HTML format. Googlimg the question, it seems that I have to go to tools > Options, but when I clcik on the tools of the Home tab, I see no button 'Options '.

    Where should I look, please?

    When you click "Send Message" (or

    ), in the middle of the Ribbon 'Message', you should see an icon to switch to plain text (in HTML) and in HTML format in the case of plain.

    If you want to permanently,

    , in the tab 'Read', "Read all messages in plain text" and then click on the 'Send' tab, click the format desired under "email Format".

Maybe you are looking for