Text field scrolling fixed height that develops when printing?

Hi all

I came across this before, but for the life of me I don't remember: ideas for what is required to set a text box so that the height is fixed and used scroll bars when it overflows the text box text, but on the printing of the document, and then expands so that all the text is visible and will be printed?

If I remember, it may be a little snippet of JavaScript code that is required, working on a print event?

All other items will be part of a fluid design so that nothing breaks, however it is important that seen on the screen, the text boxes have a fixed height. Only necessary to expand on print.

Any suggestions would be much appreciated: I have been on it for hours!

Thanks in advance.

Hello

Take a look at the last page in this example: http://assure.ly/g80MVY

You'll see how in the preprint event we set the minH for the textfield property and assign a h property on postPrint.

Hope that helps,

Niall

Tags: Adobe LiveCycle

Similar Questions

  • Pop the text field scrolling buttons on the stage

    Hello all;

    I am very new to Flash so please bare with me. If anyone can point me to some examples I would really appreciate it. I have 5 buttons on my stage (in fact they are just text that I made in buttons); I would like the user to be able to click on each of them, and it appears a text field scrolling where they can read and scroll the information in the text field and then they can go back and click Next and so on. On the left side of the stage is the buttons and on the side right would be the scrolling text field. Now I realize that I could accomplish this using frameworks separated for each button and just pointing to these images, but I feel that there is an easier way... There must be there is something I'm definitely missing...

    Thank you d ' attribute
    T

    A warning first. I have not tested this code, but it covers most of what is needed to do this with AS3.

    var source: String = "myTxtFile.txt";
    var dataFormat:String = pouvez;

    var loader: URLLoader = new URLLoader();
    loader.dataFormat = dataFormat;

    loader.addEventListener (Event.COMPLETE, completeHandler);

    var request: URLRequest = new URLRequest (source);
    try {}
    Loader.Load (request);
    } catch (error) {}
    trace ("there was an error loading the text file");
    }

    function completeHandler(evt:Event):void {}
    var variables: URLVariables = new URLVariables ((evt.target comme URLLoader) .data);

    for (var i: uint = 1; i<= variables.numvars="" ;="">

    var n: String = "button" + i;
    myTexts [n] variable = [n];

    }
    }

  • Rich text field, scroll problems

    Hello world

    I currently have a problem with the rich text fields.  I have a selected rich when custom text field (onFocus), it colors the blue text when not selected (onUnfocus), the text is white.

    I have Setup several of my RichTextFields in a VerticalFieldManager so they can be scrolled as a list.

    Now scrolling works on the following simulators:

    Bold 9000 4.6.0.266

    Curve 8520 4.6.1.272

    But no scrolling does work on this Simulator:

    Bold 9700 5.0.442

    What Miss me?  I know the o/s changed, but if it should not be backward compatible?

    I use Blackberry JDE component Package 4.2.1

    Any help would be greatly appreciated.

    I found the problem.  The super I was calling was super (text, Field.FOCUSABLE), this caused the 9700 Simulator not to focus the richtextfields.

    The Builder suitable for call is super (Field.FOCUSABLE), and that fixed the issue.

    Now, I have another problem.  Suddenly, I added a few images, the background (they are all less than 300 KB) tested on simulators of 9000 and 8520, it worked.

    When I test it on the 9700, it says net.rim.device.api.system.Application not found

    Hint anyone?

  • editable text field and button is not editable when added to the Manager of the Horizontal

    I find layout, when I added the button and EditField horizontally, Manager, I'm not able to write something in the EditField and not able to click on the button

    public class MyStorySearch extends MainScreen
    {
    
        private VerticalFieldManager mainManager;
        private VerticalFieldManager subManager;
        private Bitmap _backgroundBitmap = Bitmap.getBitmapResource("a.png");
        private int deviceWidth = Display.getWidth();
        private int deviceHeight = Display.getHeight();
        LabelField lbl;
        ButtonField gobtn= new ButtonField("Go");
        HorizontalFieldManager hfm = new HorizontalFieldManager(Manager.FOCUSABLE|Manager.EDITABLE);
        private Field editfild;
        Bitmap bitmapImage = Bitmap.getBitmapResource("storysearch.png");
        BitmapField fieldDemo;
    
        public MyStorySearch()
        {
            super(NO_VERTICAL_SCROLL);
            //this manager is used for the static background image
            mainManager = new VerticalFieldManager(
                              Manager.NO_VERTICAL_SCROLL |
                              Manager.NO_VERTICAL_SCROLLBAR )
            {
                public void paint(Graphics graphics)
                {
                    graphics.clear();
                    graphics.drawBitmap(0, 0, deviceWidth,
                             deviceHeight, _backgroundBitmap, 0, 0);
                    super.paint(graphics);
                }
            };
    
            //this manger is used for adding the componentes
            subManager = new VerticalFieldManager(
                             Manager.VERTICAL_SCROLL |
                             Manager.VERTICAL_SCROLLBAR )
            {
                protected void sublayout(int maxWidth, int maxHeight)
                {
                    int displayWidth = deviceWidth;
                    int displayHeight = deviceHeight;
    
                    super.sublayout( displayWidth, displayHeight);
                    setExtent( displayWidth, displayHeight);
                }
            };
    
            //add your component to this subManager
            lbl = new LabelField("SUNRAYS SEARCH", LabelField.USE_ALL_WIDTH | DrawStyle.HCENTER);
            Font myFont = Font.getDefault().derive(Font.PLAIN, 10, Ui.UNITS_pt);
            lbl.setFont(myFont);
            subManager.add(lbl);
            subManager.add(new SeparatorField());
    
            editfild = new EditField(){
                protected void layout(int width, int height) {
                    setExtent(width*85/100, 30);
    
                };
            };
            editfild.setBorder( BorderFactory.createSimpleBorder( new XYEdges(2, 2, 2, 2),
                    new XYEdges(Color.BLACK, Color.BLACK, Color.BLACK, Color.BLACK), Border.STYLE_SOLID));
            editfild.setBackground(BackgroundFactory.createSolidBackground(Color.WHITE));
    
            hfm.add(editfild);
            hfm.add(gobtn);
    
            subManager.add(hfm);
    
            //add subManager over the mainManager
            mainManager.add(subManager);
    
            //finally add the mainManager over the screen
            this.add(mainManager);
        }
    }
    

    The following code shows an EditField and a button, and I can type in the EditField and click the button.  It is not perfect, but at least it works.

    I don't know what the problem is with your code.  I suggest review you my code, review your code and investigate things that are different.

    Two areas I would focus on your layout and the sublayout.  As stated in a previous post, if you must code a setExtent in a layout, then you should really think about creating your own Manager - I gave you links to do this several times.  And if you plan to use a standard field and to make it work properly, you must use the sublayout.  Here is a link to help you create custom fields:

    http://supportforums.BlackBerry.com/T5/Java-development/create-custom-fields/Ta-p/444962

    Edit:

    Thanks for the update of these discussions.

    And I'm sorry.   I forgot to paste the code...  Here, it is now...

            EditField editfild = new EditField(){
                protected void layout(int width, int height) {
                    super.layout(width*85/100, height);
                };
            };
            editfild.setBorder( BorderFactory.createSimpleBorder( new XYEdges(2, 2, 2, 2),
                    new XYEdges(Color.BLACK, Color.BLACK, Color.BLACK, Color.BLACK), Border.STYLE_SOLID));
            editfild.setBackground(BackgroundFactory.createSolidBackground(Color.WHITE));
            ButtonField gobtn= new ButtonField("Go") {
                protected boolean navigationClick(int status, int time){
                    Status.show("button clicked");
                    return true;
                }
            };
            HorizontalFieldManager hfm = new HorizontalFieldManager();
            hfm.add(editfild);
            hfm.add(gobtn);
            this.add(hfm);
    
  • Problem with anti-aliasing on the text fields scrolls

    I am building an application using FlashBuilder and currently running on the latest version of Mac OS x, and test my application in the anti-discrimination Act.  I see the strangest problem; I have a large window, and I use scrollrect to view different parts of the window. When I set the scrollrect and it works very well, the window scrolls to the top just as you expect. But "BOLD" text on the screen becomes much more ugly after I scroll.  I tried to set CacheAsBitmap on the sprite containing that scrolls, but that has no effect. It affects the text that could be in the middle of the window and just move upward, slightly; all of the characters in the text has ruined the subpixel antialiasing.

    Is it a weakness known use ScrollRect? How can I work around this problem?  I tried to turn on cacheasbitmap for all my sprites, but nothing has changed. I tried to set the AntiAliasType my TextField in ADVANCED, but which has also had no effect.

    It is confusing to me, why the rendering is so bad after a scroll. Even when I go back to its original position (scroll down, then upward), the text is ugly. It's almost as if he shot it twice on the screen, but it's probably just a lower level of text rendering.

    Any guidance would be greatly appreciated.

    I've identified the problem. It is caused by a bug in my code, which is the double drawing of text on the other fields. When you have a large font size which is antialised, when you draw a second copy on the top, the aliasing allie to ruin the sweetness of the police. It is the only clue you double drew an object! Very interesting question in vector graphics, can not say once easily when you drew something twice!

  • I want to display text on screen only, but does not when printed on paper. How do I do that?

    Adobe Reader

    Not possible with Adobe Reader.

  • In WebMail, the text is readable on the screen, but when printing, crazy characters appear.

    Question

    I have another type of problem with Firefox

    Description

    When I use Firefox and Earthlink webmail, I get messages that look ok on the screen but when I print them, crazy characters are displayed on the printed page rather than the text that is on the screen. I tried to empty the memory cache, cookies, and temporary files and files in the temporary folder on my computer of compensation by using the "start > run > %temp% ' method. No fix has helped the problem.

    Troubleshooting information

    IE Tab 1.5.20090925, Java Quick Starter 1.0, Microsoft.NET Framework Assistant 1.1

    Version of Firefox

    3.5.2

    Operating system

    Windows XP

    User Agent

    Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; RV:1.9.1.2) Gecko/20090729 Firefox/3.5.2 (.NET CLR 3.5.30729)

    Plugins installed

    • -IE Tab plugin for Mozilla/Firefox
    • The QuickTime Plugin allows you to display a wide variety of multimedia content in Web pages. For more information, see the Web of QuickTime site.
    • Deploy Script NPRuntime plugin Library for Java (TM)
    • Adobe PDF plugin for Firefox and Netscape "9.3.2.
    • Default plugin
    • Shockwave Flash 10.0 r45
    • 3.0.50106.0
    • Next-generation Java plug-in 1.6.0_20 for Mozilla browsers
    • Java (TM) Platform SE binary
    • Npdsplay dll
    • DRM Netscape Object network
    • DRM Netscape Plugin store

    There is a Bug in Firefox printing which can cause "blurred" impression with some fonts on some printers. Try to use the file > print preview and look at the policies; If it looks good, try to print from the preview window before printing.

  • I created a PDF editable using Adobe Indesign. When I open the PDF file in Adobe Acrobat Pro ms, is there a way to specify a font style? Or is it possible in InDesign to make sure that when someone types in this text field is a certain font?

    I need to make sure that the entered text is a certain font to keep continuity with the rest of the document. Thank you!

    To make form editing mode, select 'Prepare form' in the right pane. You will then get a toolbar at the top which contains various tools that focus on the form. The first thing to do is to add a temporary button. You will use this to determine the name of the font to use with the script but also to place the script that will change the properties of the font of text fields. Thus, create a button anywhere and double-click on it to bring up the field properties dialog in the Actions tab, add a JavaScript action to the mouse event to the top which is:

    // Mouse Up script for temporary button
    app.alert(event.target.textFont);
    

    On the appearance tab, select the font you want to use for the text fields. Once you have done this, close the form editing mode and click the button. It displays a popup that lists the name of the font. This may be different from the name that appears in the drop-down list on the appearance tab, so write down it. For example, when I chose "Minion Pro" in the menu dropdown, popup showed "MinionPro-Regular.

    The next step is to replace this script of mouse upwards by the following text:

    // Mouse Up script for temporary button
    
    // Change the font and font size for all text field in this document
    for (var i = 0; i < numFields; i++) {
    
        var f = getField(getNthFieldName(i));
    
        if (f.type === "text") {
            f.textFont = "MinionPro-Regular";
            f.textSize = 9;
        }
    
    }
    

    Replace "MinionPro-Regular" by the name of the font that you wrote before, and set the font size to whatever you want. Use 0 to specify a font size of 'Auto '.

    This script will change the font of all the text fields to whatever you specify. When you have verified that text fields are implemented as you want, you can go ahead and delete or hide the button. If you think you'll do a lot of forms of work, you can create customized in Acrobat tools to speed up this process, but this should help you get started. InDesign does not allow you to specify a large number of field and action properties, so you must work this way, and using scripts to automate is an accessible way to significantly speed up the process and avoid mistakes.

  • I have created a form in Indesign. Is there a way to create the default text in a text field that displays the interactive pdf "insert text here" in the text field?

    I have created a form for the company, so that I work. It is a form that will be used in several offices and has buttons, drop downs and text fields. One of the text fields has a requirement that when the PDF file is opened, the text field has something written in there already, as an example (and one only) INSERT the TEXT HERE. I created the text field in Indesign and used the text tool to type in the area of the body-copy required. After that I have to export it as an interactive PDF, text in the text field disappeared.

    Drop-down lists give an option for a default choice, but I don't see a way to create default text in the Panel of buttons and forms for text fields. Is there a workaround or a hidden feature?

    Thank you!

    Set it in Acrobat.

  • Text field overprinted when you print - properties look OK - help

    I have a problem with a text field in a form that I created using Acrobat X Pro on a PC running Windows 7 Ultimate.

    Document was created originally in MS Word 2007 and then convert to the form using the form wizard.  I have the selected font like helvetica auto-size, but the problem exists even if I change the font size of 10 or 12.  In the text properties everything looks OK.

    The form looks fine on the screen, but when I go to print the text either does not the length of the field and seems to be all scrunched up with overlapping letters, as if there is no space kerning between letters.

    First screenshot is of the screen display.  It seems.   Second screenshot, this is what is looks like print.   Note, this is not a problem with my HP printer, as happens even when I print to PDF.

    Help!

    Thank you

    Peter

    On Screen View.JPGPrinted Version.JPG

    I downloaded your file and you have more than one field duplicate a heap cells.

    Go back to Acrobat > forms > change

    Click on each field.  to the right in the list of registered names, you will see something like name 0 #, 1 # name and so on

    remove all duplicates except one named #0 name (the name will change automatically to the name only) most of the fields on the page 1 and 2 have been reproduced.

    It shows like shadows, it's fields are not perfectly aligned.

  • Text field that supports rich text using the script edition

    I have a text field with rich text format format. I need to add a new line character, if the length of a sentence longer than 65 characters. When I change the text using javascript formatting breaks and the signature event will fail eventually. Is it possible to change the body of the value of the text field? I realized that the value store in text/html.

    Examples:

    Before change:

    "< txtOtherDocuments > < body xmlns ="http://www.w3.org/1999/xhtml"xfa:APIVersion ="Acroform:2.7.0.0"xfa:spec ="2.1">"

    < style p = "margin-top: 0pt;" margin-bottom: 0pt; do-family: Arial; font-size: 8 pt. "text-decoration: no" > Test data < /p > < / body >

    Field.rawValue using = «...» "fails. Y at - it a different set of commands?

    Help, please.

    Thank you

    If you want to access the data and style in a field richtext, you must use the command Fieldname.value.exData.saveXML ("pretty"). This will give you the xHTML data format. Then you can manipulate the data in the way that you want, and to get it back in the field, use the Fieldname.value.exData.loadXML ("xml to load", parm1, parm2). The parms are Boolean values that control whether to replace or add the XML to the existing xml. See the reference for script/help for a more detailed description.

    Note that it won't be easy if there is a lot of rich text in your field that the text will be spread between tags. You may need to use the rawValue (no formatting to find out where to put the CR then find in the HTML code and it add.)

    Make sense?

    Paul

  • Text field of point (always submits the page when you press enter)

    I do apply in which I could read codes bar by the optical drive, for which I use a field of text element, which shows me the barcode information, and then I click the button Save, which is a successful process...

    But when the property changes of text field for the point (still stands when enter press pages) for automatic recording, the process is not successful.

    -That can be done to the code system reading barcode automatically saves...

    Note: when reading of the bar code, including the son of enter...


    I appreciate your attention.

    Lucien Reynel Salazar Martínez... +

    Make sure that your process page is not conditional on the 'Record' button that is clicked.

  • First text field in the page submit when the Enter key is hit. Don't want to send

    Hello

    I searched and cannot find this answer I had before...

    The text field is not present it always when you press included, just a standard text element.

    because it is the first text field in the page... or maybe it was because it is the text field on the page that requires him to 'Submit' page when you press the Enter"" key.

    I don't want the Enter key to send the page.
    Was - to add a dummy hidden text field before this text field?

    Bill:

    Add another text element to your page and to the text element 'attributes of HTML Form elements' specify

    style = "" display: none ""

    CITY

  • By assigning a value to a text field not working PHP/javascript?

    I have a site to someone else coded, where a text field does a value that is assigned.

    Both
    Form1.textfield3.value = form1.textfield1.value;
    and
    Form1.textfield3.value = "99";

    not work, and the field is left blank.

    This same code works on Internet Explore (Win and OSX), Safari, Chrome and Opera. It does NOT work on Firefox 8 or 9.01 (Win and OSX) or 3.6.25. He used to work on an older Firefox, we had (unknown version).

    JavaScript is enabled; is there anything else we can check?

    If you check the error in Firefox (Ctrl + Shift + j) Console, you will see "form1 is not defined. This is because Firefox converts automatically form1 in reference to < form = "form1" name >. Instead, you must change the code a bit.

    You can fix the above error starting each function where you refer to form1 with this:

    Form1 = return ["form1"] var;

    However, probably just move the error to the next part of the notation (for example, textfield3). The proper way to refer to the value of a form field named is:

    document. Forms ["Form1"]. Items ["textfield3"]. Value

    or if you have set form1,

    Form1.elements ['textfield3'] .value

    If you have a few changes to make. Not sure if there are shortcuts.

    This forum focuses on the care of the end user. You can find more help web development on the mozillaZine Web Development Council. Separate forum, separate registration.

  • Slider custom text field (Cap) does not appear

    All;

    I created a custom text field based on the standard text field, changes work fine (really just a custom height and width and a border).  The problem is the method of painting which seems to remove the cap of the field when it gets the focus.  To be clear the carret never shown at all.

    public class CustomText extends TextField //cutom text field width
    {
        //Custom Height and Width in Pixels
        final static int textwidth=125;
        final static int textheight=25;
    
         CustomText()
         {
         super(); // Call the default constructor    
    
         //Border for text fields
         XYEdges padding = new XYEdges(5, 5, 5, 5); //space between box and border
         Border theborder = BorderFactory.createSimpleBorder(padding, Border.STYLE_SOLID);
    
         //Assign the border to the object
         this.setBorder(theborder);
         }
    
         public void onFocus( int direction )
         {
            super.onFocus( direction ); //invoke parent procedure
            invalidate(); //mark for redraw
         }
    
         public void onUnfocus()
         {
        super.onUnfocus(); //invoke parent procedure
        invalidate(); //mark for redraw
         }
    
         //Override the layout with the custom Width and Height
         protected void layout(int width, int height)
         {
            super.layout(textwidth,textheight);
            setExtent(textwidth,textheight);
    
         }      
    
        //Override the display message such that no message is displayed when the field is full
        protected void displayFieldFullMessage()
        {
        }
    
        //Override the default paint method to call the super class constructor and then assign the border
        protected void paint(Graphics graphics)
        {
           // int prevColor = graphics.getColor(); //Save Previous Color
            graphics.setBackgroundColor(Color.LIGHTGRAY); // Set to Gray
            graphics.clear(); // Clear for redraw
            super.paint(graphics); //Force Redraw of Object
          //  graphics.setColor(prevColor); //restore for cursor paint
    
        }
    
    };
    

    In the paint in the first and last method lines that are commented out were a soloution that I tried after reading on this subject.  Something along the lines of the restoration of the default color, but unfortunately without success.   Any ideas would be more useful

    Thank you!

    Quick thoughts:

    (a) to remove the requirement to substitute paint by setting the background a Color.LIGHTGRAY using the base class

    (b) you put on the field by using this:

    Super.Layout (TextWidth, TextHeight);

    If you then do the following:

    setExtent (textwidth, textheight);

    you are likely to confuse the field.  If you still want to use the entire height and use the full width and then try to deal with it in the Style, that is, replace this:

    Super(); Call the default constructor

    with this

    Super(TextField.USE_ALL_HEIGHT |) TextField.USE_ALL_WIDTH); Call the default constructor

    (c) why you override onFocus and onUnfocus?  I would like to delete these if you do not have anything specific to these methods.

    Make these changes, and you'll have a more simple TextField.  See if these changes will solve the problem of the caret too.

Maybe you are looking for

  • Apple store

    Hello My Apple ID works properly but I can't access the Apple Store and in my system, it is not recognized by iCloud (but I can access iCloud using Safari). Thank you

  • compressor does not reach 28 seconds in treatment

    After sending file fcpx to the compressor, it will fail at 28 seconds in treatment. In the same event fcpx I have 2 projects ongoing 1 to process completion ok but 1 fails after 28 seconds. I hope someone can help. My computer knowledge is limited. W

  • Pavilion p6-2260ea: graphics card help.

    Hello! I stumbled across a big problem I got it;I recently bought a brand new Asus Geforce GTX 750Ti to replace my old Asus Radeon HD 6670.When I replaced the card and turned on the computer the screen blue hp come, made the beep to indicate installa

  • Use the 64-bit installation program dedicated on 64-bit windows editions

    I get the error message when you install specific applications, I checked the game in compatibility mode: Windows XP (Service Pack 2) - I use Windows Vista Home Premium 64-bit Edition. The message is: "exhaust all dedicated 64-bit on windows 64-bit e

  • How to install shortcuts on the desktop

    I would like to create shortcuts on my desktop for frequently used internet sites.  How can I do this?