On the Vertical domain manager

Hi all

I want to add two fields and two buttons to the background image screen.

To do this, I added backgroundimage on-screen using verticalFieldManager.

In this verticalFieldManager, I added these two areas and two buttons.

But I want these two buttons displayed only horizontally.

Hello

Thanks EVERYONE, I solved the problem.

Tags: BlackBerry Developers

Similar Questions

  • problem with the vertical field Manager

    Hello

    My application has a screen. On this, I add a Senior Manager vertical field. I add new labelfields dynamically to this vertical field Manager.  When I give the text in the constuctor of the etiquette field, each of them is the fine display. But when I tried to draw the text to the painting, it does not appear.

    Here is my code...

    vfm = new VerticalFieldManager(VERTICAL_SCROLL | FOCUSABLE);
            for (int i = 0; i < 4; i++) {
                index = i;
                LabelField labelField = new LabelField() {
                    protected void paint(Graphics graphics) {
                        // TODO Auto-generated method stub
    //                  super.paint(graphics);
                        graphics.setColor(Color.BLACK);
                        graphics.drawText(displayString[index], 0, 0);
                    }
                };
                vfm.add(labelField);
            }
            add(vfm);
    

    Please help me find a solution.

    First of all, stop saying that it is VerticalFieldManager who has done something bad for you. It has nothing to do with it.

    You use the index in your LabelField painting method. Use paint value is the current value of the index at the time of the painting. Painting happens way after you have created all your LabelFields, when the index stopped to change and has the last value of the loop variable (in your case, it's 3).

    This, as well as LabelFields width zero (that you seem to have supported) so are the problems of your original code. Store the value of i in your LabelField somehow if you insist on using the table values. If only check out you them once and do not change them, consider creating your LabelFields with the text from this displayString table.

    Even better: as you do not use the LabelField paint, why not create a custom field received a text and paint your smileys and all? Of course, you have to implement available as well, but it's useful even when your smileys will take a different width than the corresponding symbols.

    To summarize: your current approach is bad. Take a step back, work on the design, and then implement.

  • problem with the vertical field Manager / vertical scroll

    Hello

    I've set up a screen which makes use of a vertical field Manager by using the following code:

    class Main_Menu extends MainScreen {
    
        public class FixedWidthButtonField extends ButtonField{
            private int width;
    
            FixedWidthButtonField( String label, int Width){
                super( label, Manager.FIELD_HCENTER);
                width = Width;
            }
    
            public int getPreferredWidth(){
                return width;
            }
        }
    
        public Main_Menu() {
            setTitle(new LabelField ("Main Menu Screen", Field.FIELD_HCENTER));
            setStatus(new LabelField ("Breakout Game ©", Field.FIELD_HCENTER));
            VerticalFieldManager backgroundManager = new VerticalFieldManager(Manager.USE_ALL_WIDTH|Manager.USE_ALL_HEIGHT|Manager.NO_VERTICAL_SCROLL)
            {
                protected void paint(Graphics graphics) {
                    graphics.setBackgroundColor(0x0000A2E8);
                    graphics.clear();
                    super.paint(graphics);
                }
            };
    
            FixedWidthButtonField playButton;
            FixedWidthButtonField instructionsButton;
            FixedWidthButtonField topScoresButton;
            FixedWidthButtonField quitButton;
    
            playButton = new FixedWidthButtonField("Play",(Display.getWidth() / 2) - 80);
            instructionsButton = new FixedWidthButtonField("Instructions",(Display.getWidth() / 2) - 80);
            topScoresButton = new FixedWidthButtonField("Top Scores",(Display.getWidth() / 2) - 80);
            quitButton = new FixedWidthButtonField("Quit",(Display.getWidth() / 2) - 80) {
                protected boolean navigationClick(int status, int time)
                {
                    getScreen().close();
                    return true;
                }
            };      
    
            playButton.setMargin(40,0,0,0);
            backgroundManager.add(playButton);
            instructionsButton.setMargin(10,0,0,0);
            backgroundManager.add(instructionsButton);
            topScoresButton.setMargin(10,0,0,0);
            backgroundManager.add(topScoresButton);
            quitButton.setMargin(10,0,0,0);
            backgroundManager.add(quitButton);
    
            add(backgroundManager);
        }
    }
    

    The problem I have is that the screen scrolled down to see the empty space after the final touches, and I can't seem to overcome this problem and prevent additional scrolling. I just want the ability to scroll the 4 buttons and have a blue background on the entire screen.

    Thank you

    Just quickly, so watch migth have wrong, but if you have a good overview of this very useful article:

    http://supportforums.BlackBerry.com/T5/Java-development/MainScreen-explained/Ta-p/606644

    I think you will find that you need to add the following at the beginning of your screen manufacturer:

    Super (NO_VERTICAL_SCROLL)

  • verticalmanager down in the vertical scrolling Manager

    Hello

    I have created custom components that extend a class that implements verticalfieldmanager

    These classes contain a number of areas for example a label a textfield, another label and image

    I get a list of these objects (vertical field managers that contains several components) and add each of them to another manager of vertical in the main screen

    My problem is when the scrolls to screen through my list of vertical management focus is moved to the first active item in the Manager so when you exceed the first couple and the screen needs to access you will only see the first item in the component. I want to be able to scroll the main Manager until the end of the component, but still leave the focus in the first element. How can I do this?

    Looks like you want to have a field in short but be able to scroll through the other VerticalFieldManager.

    You can override navigationMovement to the screen and setVerticalScroll for certain VFM, but she will break habitual movement of development on the screen (the other side effects are possible). You want to do?

  • How to get the field at any time a vertical field Manager?

    Hi guys. In the application, that I'm working on, I came across a bit of a challenge.

    Basically I have a vertical field Manager ful of custom components.

    Basically this custom components, draws the user name, some other info and pictures of the user related to their account.

    It all works very well, but what I'm trying to do is to get the exact field on the vertical field Manager at any time. You see, while it displays the image of the user, I download from a Web server (and it will display a picture by default while it is downloading). So what I'm trying to do is go to the correct custom component of the vertical field each time Manager, so I can quickly change the image is correct, once I get the correct uploaded image. The manager of vertical field is called via the standard method.

      VerticalFieldManager vfm = new VerticalFieldManager(VERTICAL_SCROLL|VERTICAL_SCROLLBAR) {
    
    protected void sublayout(int w, int h) {
        super.sublayout(480, Math.min(240, 360)); 
    
    }
    
    };
    
    for(int i=0; i< contacts.length; i++)
    {
    //Contacts is an array of my custom component. I am just calling it
    contacts because it basically is a list of contacts.
    vfm.add(contacts[i]);
    }
    
    add(vfm);
    

    Everything works well for me except a way to get the correct field on the vertical field manager. So that I can

    Run it in a contact, and then reset the image.

    Can anyone help with this?

    Thank you

    I suggest that you give to your download manager - a reference to the contact that you update, if networking is done, you can refresh it.

    except if you develop for a device of some I would be careful with the absolute values like 480 btw

  • Problem with the Auto-Snapshot manager after domain change

    Hello

    I have a client with a FailoverCluster Hyper-v and CSV.

    They recently changed their internal domain name, and since then, they have problems connecting to the PS Group in the Auto-snapshot Manager.

    I get an error saying:

    An error occurred processing action: Discovery.
    An exception was thrown by the target of a call.

    I hope someone can point me in the right direction :)

    Anders

    I suspect that your iSCSI initiator has problems connecting to volumes - and your problem is, in fact, isolated ASM / me.  Check the RUNAS account used on the services of the DSO to ensure that they use the appropriate domain credentials.

  • Need help with this Vertical field Manager? It scrolls to the low n!

    I created a vertical field Manager

    public class BGManager extends VerticalFieldManager{
        public BGManager() {
            super(VerticalFieldManager.USE_ALL_WIDTH|USE_ALL_HEIGHT);
        }
        public void paint(Graphics graphics)
        {
            graphics.setBackgroundColor(Color.BLACK);
            graphics.clear();
            super.paint(graphics);
        }
    
    }
    

    I added to my screen, then I added fields in addition to this.

    It works fine, but the Manager starts to scroll down when the focus is on the last field and I'm trying to scroll down.

    He does not stop to the last topic.

    How can I fix?

    Take a look at this thread. It addresses exactly your problem with solution:

    http://supportforums.BlackBerry.com/T5/Java-development/VerticalFieldManager-with-fixed-size-scroll-...

  • How to adjust the height of the domain manager?

    Hello world

    How to adjust the height of the domain manager?

    I want to fill my page with three buttons and a title screen label.

    I have to fill the full screen so that I can put a border for my screen...

    If I can adjust the height of the domain manager then I can put border for it.

    Thank you.

    try something like that.

    verticalManager = new VerticalFieldManager()
            {
    
                protected void sublayout( int maxWidth, int maxHeight )
                {
                    //set width
                    int displayWidth = Display.getWidth();
                    //set height
                    int displayHeight = Display.getHeight();
    
                    super.sublayout( displayWidth, displayHeight);
                    setExtent( displayWidth, displayHeight);
                }
            };
    

    Concerning

    Bika

  • Operations Manager 6.1 5.5 Web client on vSphere link refer to the IP address instead of the FULL domain name

    Hello

    We have a new environment vROps 6.1. Everything works like a charm, except when I get the Web Client vSphere. Hosts and Clusters - monitor - health, I try to click on the "see details in vCenter Operations Manager" and I get sent to the IP address to one of the nodes in the cluster vROps. This translates into a certificate error. We have signed all the certificates for the solution of vROps, but that doesn't help us when the link refers to one IP address. Any way to change the behavior of the link to go instead of the full domain name?

    Thanks in advance for your comments.

    Concerning

    Atle

    Yes, here is a code snippet PowerCLI to do:

    to connect-viserver

    $extMgr = get-view ExtensionManager

    $vRops = $extMgr.ExtensionList |? {$_.key - eq "com.vmware.vcops"}

    $vRops.Server [0]. URL = "https://vrops-fqdn/vcops-ngc.zip".

    $ExtExtendedProductInfo = new-Object VMware.Vim.ExtExtendedProductInfo

    $ExtSolutionManagerInfo = new-Object VMware.Vim.ExtSolutionManagerInfo

    $vRops.ExtendedProductInfo = $ExtExtendedProductInfo

    $vRops.SolutionManagerInfo = $ExtSolutionManagerInfo

    $extMgr.UpdateExtension ($vRops)

    AK

  • How can I remove the tab of the Add-ons Manager that appears every time I open Firefox

    The tab of the Add-ons Manager rises not solicited. He has a blue puzzle piece bit as an icon to the left of the words Add-ons Manager. It's so annoying this tab all the time.

    Make sure that you did not inadvertently Addons Manager as one of your landing pages.

    https://support.Mozilla.org/en-us/KB/how%20To%20set%20The%20home%20page#w_set-more-than-one-website-as-your-home-page

    The vertical bar symbol | separates the URL in the box of the home page to start > home page

  • I keep getting "the trust relationship between this workstation and the primary domain failed" error windows 2008R2

    Hi all

    I appreciate your help. And I hope that this issue has been addressed previously, although I couldn't find any solution there.

    I manage a domain windows 2008 with 3 domain controllers. Recently my workstations continue to fall out of the field. I get "the trust relationship between this workstation and the primary domain failed" to many workstations.

    I know how to fix properly, use netdom.exe. But the mistakes keep coming back. I don't know where to look for the source of this error. A possible problem might be the time in any field is out of sync. But all my workstations synchronize with the domain controller with the primary domain controller role and seems to work correctly.

    Are there other sources, that I need to check? This is getting frustrating.

    Thank you much for the help.

    Sincerely,

    Hello

    Post your question in the TechNet Server Forums, as your question kindly is beyond the scope of these Forums.

    http://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?category=WindowsServer

    See you soon.

  • Start stuck on "Please wait for the Local Session Manager."

    I would say that this problem started a couple of days. Went to start my laptop (Toshiba) and he sat on the "Please wait" message forever.

    Had no problems to start in safe mode. Looked up various ways of addressing the problem.

    Was able to change the resume date and back a few weeks ago. Still no luck. Happened to read something on a printer Epson being perhaps the problem driver (it was installed a day before the date of restoration chosen). Uninstalled the drivers, computer still does not start.

    Tried restarting running. I do not have the CD it came with Vista, but it was an option when you hold F8 during startup (I think?) Couldn't find any problems.

    Ran check on memory. No problem either.

    Changed settings for a verbose startup and ran a Diagnostic startup - all good for this. Then tried selective startup load system services... This is when the error occurs. When starting, it hangs on "Please wait for the Local Session Manager" and does nothing more.

    I looked in the event viewer to see what came that time and a couple mistakes were:

    Event ID 6000: winlogon notification subscriber was unavailable to handle a notification event.

    Event ID 7026: the next (s) start or start failed to load system
    spldr
    Wanarpv6

    It would be very useful for me not having to run my computer in safe mode automatically all the time, although it is useful that I at least have that option. Any help is greatly appreciated.

    Hello

    1. by chance your computer is connected to a domain environment?

    2. as you mentioned in your article that you tried the selective startup, I want to confirm if you have disabled the services left 3rd after hide Microsoft services?

    If you did not disable these services make sure you disable and then check if it works.
    See the article below for more information.
    How to troubleshoot a problem by performing a clean boot in Windows Vista or in Windows 7
    http://support.Microsoft.com/kb/929135
    Note: When the diagnosis is complete, don't forget to reset your computer to normal startup. Follow step 7 in the above article.

    I hope this helps.

    Thank you, and in what concerns:
    Shekhar S - Microsoft technical support.

    Visit our Microsoft answers feedback Forum and let us know what you think.
    If this post can help solve your problem, please click the 'Mark as answer' or 'Useful' at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • How to display the vertical scroll bar in custom painted screen?


    a simple and intelligent search forum and I solved the problem.

    Screen does not scroll without an active field before and after the Manager of the vertical.

    I just addedd a NullField before the Manager and everything works fine!

    Thank you

  • Assign a spacing equal to the fields in the horizontal field Manager

    Hello

    I add a number of vertical field managers to a horizontal field Manager. Each manager of vertical field has a text with an image under. The text varies in width images in each vertical field Manager seem to have a different amount of space between them. Is there a way to remedy this situation? Joined a raw image in the way that message on the screen. How can I get the same amount of space between each area of the rectangle?

    Thank you

    Here's some code that I received from one of the sessions at the last DevCon.  Should be useful.  Might help explain customer managers too.

    /*
     * EqualSpaceToolbar.java
     *
     * Research In Motion Limited proprietary and confidential
     * Copyright Research In Motion Limited, 2009-2009
     */
    
    import net.rim.device.api.ui.*;
    
    public class EqualSpaceToolbar extends Manager {
    
        private static final int SYSTEM_STYLE_SHIFT = 32;
    
        public EqualSpaceToolbar() {
            this( 0 );
        }
    
        public EqualSpaceToolbar( long style ) {
            super( USE_ALL_WIDTH | style );
        }
    
        protected void sublayout( int width, int height ) {
            int numFields = getFieldCount();
            int maxHeight = 0;
    
            // There may be a few remaining pixels after dividing up the space
            // we must split up the space between the first and last buttons
            int fieldWidth = width / numFields;
            int firstFieldExtra = 0;
            int lastFieldExtra = 0;
    
            int unUsedWidth = width - fieldWidth * numFields;
            if( unUsedWidth > 0 ) {
                firstFieldExtra = unUsedWidth / 2;
                lastFieldExtra = unUsedWidth - firstFieldExtra;
            }
    
            int prevRightMargin = 0;
    
            // Layout the child fields, and calculate the max height
            for( int i = 0; i < numFields; i++ ) {
    
                int nextLeftMargin = 0;
                if( i < numFields - 1 ) {
                    Field nextField = getField( i );
                    nextLeftMargin = nextField.getMarginLeft();
                }
    
                Field currentField = getField( i );
                int leftMargin = i == 0 ? currentField.getMarginLeft() : Math.max( prevRightMargin, currentField.getMarginLeft() ) / 2;
                int rightMargin = i < numFields - 1 ? Math.max( nextLeftMargin, currentField.getMarginRight() ) / 2 : currentField.getMarginRight();
                int currentVerticalMargins = currentField.getMarginTop() + currentField.getMarginBottom();
                int currentHorizontalMargins = leftMargin + rightMargin;
    
                int widthForButton = fieldWidth;
                if( i == 0 ) {
                    widthForButton = fieldWidth + firstFieldExtra;
                } else if( i == numFields -1 ) {
                    widthForButton = fieldWidth + lastFieldExtra;
                }
                layoutChild( currentField, widthForButton - currentHorizontalMargins, height - currentVerticalMargins );
                maxHeight = Math.max( maxHeight, currentField.getHeight() + currentVerticalMargins );
    
                prevRightMargin = rightMargin;
                nextLeftMargin = 0;
            }
    
            // Now position the fields, respecting the Vertical style bits
            int usedWidth = 0;
            int y;
            prevRightMargin = 0;
            for( int i = 0; i < numFields; i++ ) {
    
                Field currentField = getField( i );
                int marginTop = currentField.getMarginTop();
                int marginBottom = currentField.getMarginBottom();
                int marginLeft = Math.max( currentField.getMarginLeft(), prevRightMargin );
                int marginRight = currentField.getMarginRight();
    
                switch( (int)( ( currentField.getStyle() & FIELD_VALIGN_MASK ) >> SYSTEM_STYLE_SHIFT ) ) {
                    case (int)( FIELD_BOTTOM >> SYSTEM_STYLE_SHIFT ):
                        y = maxHeight - currentField.getHeight() - currentField.getMarginBottom();
                        break;
                    case (int)( FIELD_VCENTER >> SYSTEM_STYLE_SHIFT ):
                        y = marginTop + ( maxHeight - marginTop - currentField.getHeight() - marginBottom ) >> 1;
                        break;
                    default:
                        y = marginTop;
                }
                setPositionChild( currentField, usedWidth + marginLeft, y );
                usedWidth += currentField.getWidth() + marginLeft;
                prevRightMargin = marginRight;
            }
            setExtent( width, maxHeight );
        }
    
    }
    
  • Network error mystery - Windows cannot access \\server\users when you use the netbios name, but works fine when you use the full domain name.

    Hi all:

    Mystery - I have a Win 7 work company that cannot access a particular action.  I get the following error-"you are not allowed to access \\server\users.  Contact your network administrator to request access.  However, these users can access these files successfully on other computers, and also if I use the fqdn or the IP instead of the "netbios name server", it connects successfully.

    Environment:

    -Workstation and server at the same time in the same AD Windows 2008 r2 domain.

    -All users, admin and non admin, cannot access this share when connecting to this computer only.

    -ACCESS to the other actions on the same server, as well as actions on other servers.

    -The biggest mystery to me - if I type the FQDN, \\server.domain.local\users, it works!  What the?

    I tried:

    -Deletion of the domain and add it again, no improvement.

    -Check Event Viewer, nothing jumps (not red or yellow).

    -Enabled auditing for access to objects on the server, it does not show a failure in the security event log.

    -Turn off the firewall of my computer.

    -UN-share and re - share the directory.

    -Give everyone full control (the fact that it works well with de facto authorities a little full domain name, a candidate little likely, but I have an open mind).

    For anyone wishing to offer their 'help' by asking me to make some sort of workaround as re - install windows or turn off netbios or use only of the full domain name here on out or whatever, please Don ' t bother.  I appreciate your help, but I am quite able to reinstall and I'm not interested unique hacks that affect this otherwise network well managed, I'm looking for a solution that will allow me to save time and is a long-term solution.

    In my view, that a key point here maybe I can connect successfully using \\server.domain.local\users, but not \\server\users.  Someone at - it some thoughts?

    In DNS server of youe, go to the area in question and in the use of select search before Wins wins tab and enter the address of your wins server if you have one. If not, install one.

Maybe you are looking for