XML and scrolling text

Hi,
My flash movie contains a text field and a scrollbar, when i
simply write the text in the text field and then publish the movie
the scrollbar works fine. However i need to read in the text
through XML but when i do this the scrollbar does not work. Is
there code that i need to implement to make the scrollbar
automatically scroll....
All help is appreciated,
Thanks

Okay found this:
[Dynamic Text Box Name].autoSize = "center";
[Dynamic Text Box Name].wordWrap = true;
however, the height really doesn't adjust when the copy does.
If I start
off with the dynamic text box at 50 pixels high, it remains
that way
when calculated in ActionScript using the [MovieClip]._height
even
though it is much taller than 50 pixels with the copy in
there.
So I'm back to the drawing board. I want to have an XML file
with
Headline, BodyCopy, and disclaimer copy. I want to call the
nodes into
Flash and stylize them.
I DO NOT want to use CSS since I am using funky fonts that
will not be
available on all machines. Want those fonts embedded in Flash
so it
shows the same on any computer.
-Kirk
W. Kirk Lutz wrote:
> I am brand new to XML and pulling in text to Flash from
it. So far so
> good. The text shows. The only thing I'm having trouble
with is the
> height of the text box the imported text sits in. I want
it to
> dynamically expand if the text is long.
>
> How can I go about importing text into a text Dynamic
text box and have
> the box expand if the text is too long for the manual
setting?
>
> -Kirk

Similar Messages

  • Flex xml and field text

    hello,
    somebody has it a piece of code allowing me in a canvas to
    read a file XML and automatically to add as much field text than of
    information contained in my file xml
    thank you in advance

    Try changing the xml structure by using CDATA instead of having the russian part as an attribute and see if that makes any difference.
    What I meant is use something like this:
    <?xml version="1.0" encoding="utf-8" ?>
       <Autoparts>
        <autopart>
           <description><![CDATA[Барабан]]></description>
      </autopart>
    </Autoparts>
    instead of the current xml.

  • Adding xml to scrolling text window

    The problem is, I used this tutorial to make my scroll
    window. It seems to coding method isn't the best way to do it, as
    it makes it a pain in the *** to update. The guy didn't even put it
    in as an actionscript text, I would have to open up the text layer
    every time.
    I'm trying to modify it, but I'm really new at flash and
    kinda stuck..
    heres the tutorial (you can view the working example here):
    http://www.stilva.com/smooth-scrollbar/
    I think its more of a layering issue thats causing me
    problems...
    anyways, i want to load my text externally into the text
    thats inside the mc txthold which is inside the container. How
    would I approach this? Please use the link to view the sample and
    see the source info.

    what the ***, i never get a reply. I must have helped like 5
    people on this forum...

  • Space Bar and Scrolling + text wrap

    I'm not sure why, but my space bar won't scroll down. I think I can't properly s elect the window for whatever (I don't get the blue glowy outline around it).
    About the same time, my text stopped wrapping properly so my words spilt in the  middle when I reach the edge of a text box instead of bouncing down to the new l ine.
    Thanks for the help!

    Resolved in http://discussions.apple.com/thread.jspa?threadID=1772686&tstart=0

  • Custom XML IP PHONE text on "Your current options" and softphone button on

    Custom XML IP PHONE text on "Your current options" and softphone button on call manager 7.0 call manager 7.0 ?

    Hello, Please try this link
    http://www.cisco.com/en/US/docs/voice_ip_comm/cuipph/7906g_7911g/5_0/sip/english/administration/guide/11ag50si.pdf

  • HT201109 Final Cut Pro 10.1 crashes with Motion 5.1 custom Scrolling text and Graphics titles

    Dec 29, 2013 1:33 PM 
    found out why Final Cut 10.1 won't load my custom titles without crashing. When scrolling text in Motion 5.1 if you ad a graphic to scroll with the text Final Cut 10.1 will crash. If I remove the graphic in Motion and then load it into Final Cut 10.1 it will work.
    So Graphics and scrolling do not work. The graphics are .jpg, .png, .tiff, .psd. I don't know how to fix it. Hopefully someone out there does.
    Dave
    Final Cut Pro X, OS X Mavericks (10.9.1), 2.8 GHz Intel Core i7 & 16 GB Ram 
    Final Cut Pro Quit Unexpectedly
    Process:         Final Cut Pro [4123]
    Path:            /Applications/Final Cut Pro.app/Contents/MacOS/Final Cut Pro
    Identifier:      com.apple.FinalCut
    Version:         10.1 (238755)
    Build Info:      ProEditor-23875005025000000~5
    App Item ID:     424389933
    App External ID: 223682791
    Code Type:       X86-64 (Native)
    Parent Process:  launchd [175]
    Responsible:     Final Cut Pro [4123]
    User ID:         501
    Date/Time:       2013-12-28 12:37:04.233 -0500
    OS Version:      Mac OS X 10.9.1 (13B42)
    Report Version:  11
    Anonymous UUID:  E080EF73-4EC7-F729-7343-2C37817936C6

    Thanks Tom for the advice. I have four external hard disks, all of them formatted with Mac OS Extended Journaled. On all devices (2TB) I have more than half free space. They are connected either with Thunderbolt or USB3 cables. Different manufactures:  LaCie, Toshiba, WD and Samsung. I face the same crash problem if I connect a UBS drive 16GB or a any other device to the USB ports including the Sony Video camera connected with a USB1 cable. Same problem on ALL my computers! To work properly, I have to disconnect all USB devices and work only with internal hard disks. I also tried to format the MacbookPro (erasing the partitions with a new installation) but I have the same problem. I really lost hope...

  • How do I use serial port read and show text, but not have it scroll off screen?

    I am new-ish/returning amateur user of Labview and I am trying to edit the example VI "Advanced serial write and read VI" that is part of dev suite 2012.  I need to use the string box to show ALL text received from serial port, always appending and only rolls off screen when more real data arrives at serial port. 
    What is actually happening is as more bytes (or no bytes AT ALL!) arrive during read time, current text rolls off the string box.  Even when 0 bytes are received, screen is blanked out.  I am not very familiar with functions locations and even worse at understanding obscure references to functions, so please keep replies very basic so I can follow.
    Just to be clear, I need the string window to behave like hyperterm does-always shows data and it is not pushed out of window arbitrarily.
    Thanks,
    Steve  
    Solved!
    Go to Solution.

    OK- lets start back at the beginning.  I have a few questions...
    WHy does incoming txt get placed at top of txt box and then scroll up?  why would it make more sense to input at the bottom and scroll toward the top.  I have created this huge txt box that appears to be impossible to use.
    I have attached example of txt boxes I have tried, and pic of VI I have edited.  Bad marks for uglyness....
    Attachments:
    Capture_VI.JPG ‏117 KB
    Capture_VI2.JPG ‏133 KB

  • Wpf/webbrowser:-how to get height,width,scroll height and scroll width of render html/xhtml/xml pages.

    hi I am using to web browser control to get  height,width,scroll height and scroll width in wpf c#.
    Could You please tell me how to achive this information if .pages contain this css on body.
     style="-webkit-column-width:800px;  margin-right:800px; -moz-column-width: 800px; column-width: 800px; -webkit-column-gap: 0px; -moz-column-gap: 0px; column-gap: 0px; -webkit-column-rule: 0px solid #000;-moz-column-rule: 0px solid #000;column-rule:
    0px solid #000; height:800px; overflow:visible !important; ; margin:0px; -moz-margin:0px;-webkit-margin:0px;display:block;"
    I have to get height,width,scroll height and scroll width  on on complete event.
    this is MainWindow.xaml page
    <Window x:Class="WPFWebBrowserInvokeScript.MainWindow"
            xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
            xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
            Title="MainWindow" Height="820" Width="820" Loaded="Window_Loaded">
        <Grid>
            <WebBrowser HorizontalAlignment="Left"
       Height="800"
       Margin="10,10,0,0"
       VerticalAlignment="Top"
       Width="800"
       Name="MainBrowser"/>
            <!--<Grid x:Name="grid1"></Grid>-->
        </Grid>
    </Window>
    this  MainWindow.xaml.cs
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Windows;
    using System.Windows.Controls;
    using System.Windows.Data;
    using System.Windows.Documents;
    using System.Windows.Input;
    using System.Windows.Media;
    using System.Windows.Media.Imaging;
    using System.Windows.Navigation;
    using System.Windows.Shapes;
    using System.IO;
    namespace WPFWebBrowserInvokeScript
        /// <summary>
        /// Interaction logic for MainWindow.xaml
        /// </summary>
        public partial class MainWindow : Window
            public MainWindow()
                InitializeComponent();
            private void Window_Loaded(object sender, RoutedEventArgs e)
                string strHtml = "";
                using (StreamReader sr = new StreamReader("D:/epubunzip/ePub2_Sample03a_USgovernment_SE_Gr9-12_EN_U1/OPS/9780547451381_c01.html"))
                    strHtml = sr.ReadToEnd();
                    strHtml = strHtml.Replace("<body>", "<body  style=\"-webkit-column-width:800px; overflow:visible !important;  -moz-column-width: 800px; column-width: 800px; -webkit-column-gap:
    0px; -moz-column-gap: 0px; column-gap: 0px; -webkit-column-rule: 0px solid #000;-moz-column-rule: 0px solid #000;column-rule: 0px solid #000; height:800px; ; margin:0px; -moz-margin:0px;-webkit-margin:0px;display:block;\">");
                    string str = "<script> function execScript(){return document.body.scrollWidth;}</script></head>";
                    strHtml = strHtml.Replace("</head>", str);
                    byte[] bytes = Encoding.UTF8.GetBytes(strHtml);
                    MemoryStream ms = new MemoryStream();
                    ms.Write(bytes, 0, bytes.Length);
                    ms.Position = 0;
                    MainBrowser.NavigateToStream(ms);
                    //MainBrowser.NavigateToString(strHtml);
                    MainBrowser.LoadCompleted += new LoadCompletedEventHandler(MainBrowser_LoadCompleted);
            void MainBrowser_LoadCompleted(object sender, NavigationEventArgs e)
    //here I am trying to get  height,width,scroll height and scroll width
    //It's gtting wrong info
              WebBrowser webBrowser = (WebBrowser)sender;
                //mshtml.htmld webDocument = (mshtml.HTMLDDElement)webBrowser.Document;
                //mshtml.HTMLBody webBody = (mshtml.HTMLBody)webDocument;
                //    var dd = webDocument.InvokeScript("execScript");
                //    //  string script = "document.body.style.overflow ='hidden'";         
                //    // var dd = webDocument.InvokeScript("execScript", new Object[] { script, "JavaScript" });
                //    var elems = webBrowser.Document.GetElementsByTagName("body");
                //    System.Windows.Forms.HtmlElement webBody = (System.Windows.Forms.HtmlElement)webDocument.Body;
           

    >>if i am rendering html from MemoryStreamor string in webbrowser control in wpf It's not applying this css
    Yes it does. If you for example add background-color: yellow; to the stlyle you will see that the page turn yellow:
    strHtml = strHtml.Replace("<body>", "<body style=\"-webkit-column-width:800px; background-color: yellow; overflow:visible !important; -moz-column-width: 800px; column-width: 800px; -webkit-column-gap: 0px; -moz-column-gap: 0px; column-gap: 0px; -webkit-column-rule: 0px solid #000;-moz-column-rule: 0px solid #000;column-rule: 0px solid #000; height:800px; ; margin:0px; -moz-margin:0px;-webkit-margin:0px;display:block;\">");
    If the styles doen't get applied as expected it is a browser issue. The WebBrowser control emulates Internet Explorer in IE7 rendering mode by default.  You will have to change some registry settings to change this behaviour. Please refer to the following
    links for more information:
    http://weblog.west-wind.com/posts/2011/May/21/Web-Browser-Control-Specifying-the-IE-Version
    https://social.msdn.microsoft.com/Forums/vstudio/en-US/cf66e0cd-ab6f-45b8-b230-1d78f26670d2/opening-links-from-wpf-webbrowser-control-in-default-browser-instead-of-ie?forum=wpf
    -moz-column-width only works in FireFox for example.
    You may also navigate to an actual page and inject some javascript function that for example adds the styles to the body element dynamically or set the style properties of the body element directly:
    private void Window_Loaded(object sender, RoutedEventArgs e)
    MainBrowser.Navigate(@"E:/Epubs/ePub2_Sample05_Biology_SampleChapter_EN/OPS/ch01.xhtml");
    MainBrowser.LoadCompleted += new LoadCompletedEventHandler(webb_DocumentCompleted);
    private void webb_DocumentCompleted(object sender, NavigationEventArgs e)
    WebBrowser webBrowser = (WebBrowser)sender;
    dynamic doc = webBrowser.Document;
    //int _scrollWidth = (int)webBrowser.InvokeScript("execScript");
    //mshtml.HTMLDocument webDocument = (mshtml.HTMLDocument)webBrowser.Document;
    mshtml.HTMLScriptElement script = (mshtml.HTMLScriptElement)doc.createElement("script");
    script.setAttribute("type", "text/javascript");
    script.innerHTML = "function doSomething(){ /* do something here... */ }";
    //add script to the head
    dynamic head = doc.getElementsByTagName("head")[0];
    head.appendChild(script);
    mshtml.HTMLBody body = (mshtml.HTMLBody)doc.getElementsByTagName("body")[0];
    body.style.background = "yellow";
    //set any body.style property here...
    webBrowser.InvokeScript("doSomething");
    That's about it as far as WPF is concerned.
    Please remember to mark helpful posts as answer and/or helpful.

  • XSLT and generated text using InDesign with xml

    I have recently switched from Framemaker to InDesign and am still getting to grips with the differences so apologies if this is a very basic query.
    Framemaker was used to format sgml tagged text. You could specify that a particular tag generated a prefix or suffix. You could also specify that the tag should generate the prefix or suffix only under certain circumstances (context rules). The prefixes and suffixes I need to apply are things like open and closing brackets, commas, full stops, and sometimes a bit of text.
    I am told that this can be done with XSLT. There are whole libraries of books on XSLT out there and not knowing anything about the subject I really don't know where to start. Does anyone out there who uses InDesign with xml and XSLT have any tips about where to find useful information on the subject?
    Thanks in advance for any help on the subject.
    Steven

    Yeah, we use to have such feature wayback then. Indesign package into GoLive.  Kindly look through the idea section and vote massively for this idea.

  • Scrolling Text and Images in Flash CS3

    I am pretty new to Flash and I have spent all day trying to
    look up tutorials on making it possible to scroll text and images
    in Flash but none of them are working for me. I know you save the
    content into a movie clip but that's as far as i have gotten. would
    anyone be able to walk me through this PLEASE???
    Thanks,
    Peter

    You could use a Swing HTMLPANE or draw it all onto a
    BufferedImage and display that (code posted under 2D graphics thread).
    MArk

  • When I scrolled text became very small and I do not know how to get it back to normal

    I don't know what happened. I was moving my mouse over the screen and the text kept shrinking, until it's so small you can barely read it. I don't know how to get it back to normal size.

    Holding the Ctrl key while scrolling increases or decreases the zoom level. You can reset the zoom by pressing Ctrl+0 (zero). [[how-do-i-use-zoom|More on Zooming here.]]

  • Can't select text and scroll when using Word

    Recently I have been unable to select text and scroll down the page using two fingers, while in a word document.This is only happening in Word, so far no other programs. Does anyone have an idea of how to turn on or off this feature?

    I cant scroll below or above viewable section of text in any of my Macbooks, iMac, Mac Mini. Never have been able to, never could, except by pressing the arrow keys whilst selecting, to move up or down.
    Its stupid
    I dont have flash installed (never will do since my first virus of video ad sound running in background from Cnet was downloaded and kept returning until i deinstalled flash).
    I believe that this is a universal issue because none of my Macs can scroll out of screen when selecting text, which as a webmaster and developer, is a pain in the butt
    My issue is not in word documents, its in everything

  • Fade scrolling text in and out at the bottom and the top

    Hello,
    I'm new to Final Cut Pro X previously I have used Final Cut Express. Making the scrolling text fade out at the top of the page as it scrolls is easy in Final Cut Express. I've spent over 1 hr & cannot find how to make the scrolling text fade out in Final Cut Pro X, has anyone any ideas?.
    Thanks JohnH

    JohnHutchinson wrote:
    … However the scrolling text is across the whole screen width. When I add the Mask the text is cropped on both sides & I cannot expand it back to the width …
    you can drag the Mask-Handles to the very end of the screen:
    and I forgot to mention:
    You can set the Feather value BEYOND the sliders max. '100'
    here, in my example, 180 .......
    type the value, or 'drag'n slide' by clicking with the mouse onto the value … - as in most FCPX and Motion5 values.

  • Compare Bluray and Dvd Chapters and Scrolling still text

    Question 1:
    Using PremierePro CS5 to set some Encore-Markers and DynamicLink to Encore to create menu:
    Using the same project, the behaviour is quite different:
    for Dvd : Encore-markers behave like Chapters, so I can use the player remote control to go to next chapter (even it is not defined in the menu)
                   that is very handly function.
    for Bluray : Encore-markes behave like Titles and not Chapters, so I cannot use the player remote control to jump to next Encore-markers
    I just looking for references to understand and do the correct ajustments.
    Thanks
    tt
    Question 2:
    Using PremierePro CS5 to add a still picture and scroll it up in slow motion:
    Using the same project, I understand that Bluray is far better than DVD:
    for Bluray : the scrolling of the still picture is smooth (it's very pleasant with texts too)
    for Dvd : the scrolling is jumpy (texts are dizzy and not readable)
    Is there any fix for that (.....something like PremierePro option to smooth it out a little (result little burry) or ... something like ...deinterlacing ?)
    Thanks
    tt

    POINT 1:
    I will skip DynamicLink for circumventing some issues for sure, but it is so handy and makes me lazy to do things fast.
    So far I am using DynamicLink for updating still images in menu with Photoshop and it's working fine.
    Also I have tried sucessfully modifying some assets using AfterEffect. Yes, there are ressources demanding since I have a skinny 12 Gigs RAM.
    POINT 2:
    I have to be more specific in comparing Encore-Bluray and Encore-Dvd (I am not comparing HD with SD).
    I just want to see the big picture comparison (equivalent between Encore-Bluray and Encore-Dvd) instead of "TRY-AND-SEE"
    Let me explain:
    1. Encore-Marker set in PremierePro-CS5 is consider as Chapter in Encore-Dvd)
    2. The final DVD created: I can use the remote control to jump to next Chapter even the Chapter is not referenced anywhere in Encore-Dvd
    3. Encore-Marker set in PremierePro-CS5 is consider as Title in Encore-Bluray) (the same Encore-Marker)
    4. The final Bluray created: I cannot use the remote to jump because there is only one Chapters but many Titles.
    When I am on the last step, of Encore-CS5-Build-Dvd or Encore-CS5-Build-Bluray, i expect to get the same result when playing the Bluray of Dvd
    with the Player (Home DVD Player or Home Bluray Player and absolutely no PC )
    WHAT ELSE IS DIFFERENT BETWEEN THOSE TWO FORMATS? for the same project in ENCORE-CS5
    (I need that information to explain to the end users)
    for now, I just try-and-see and take notes.
    tt

  • How send e-mail with XML + PDF and body text

    Hi everyone,
    I have a new requirement but I´m with doubts, how to send an e-mail with two attachements (XML and PDF) and body text using -
    MIME: multipart/mixed;boundary
    I already have code to send XML + body text as you can see below:
    Element contentType = docout.createElement("Content_Type");
      root.appendChild(contentType);
      Text contentTypeText = docout.createTextNode("multipart/mixed;boundary=--AaZz");
      absTraceLog.addDebugMessage("Content_Type e-mail --- "+contentTypeText.toString());
      contentType.appendChild(contentTypeText)
    String text = "----AaZz\r\nContent-Type: text/plain; charset=UTF-8\r\n" +
            "Content-Disposition: inline\r\n\r\n" + nfeText +
            "\r\n----AaZz\r\nContent-Disposition: attachment; filename="+ prefixo +" "+ chaveNFe +".xml" +"\r\n\r\n" + xmlString + "\r\n";
    Element content = docout.createElement("Content");
    root.appendChild(content);
    contentText = docout.createTextNode(text);
    Content.appendChild(contentText);
    The code above work good, but I can´t duplicate any field from XiMail 3.0 - because it´s 0:1.
    So how to do that ?
    Thanks.
    Regards,
    BR.
    Viana.

    Eng,
    That´s works good with mailPackage:
                content= "--" + "--Zz" + CRLF
                        + "Content-Type: text/html; charset=UTF-8" + CRLF
                        + "Content-Disposition: inline" + CRLF + CRLF
                        + textBodyMail + CRLF
                        + "--" + "--Zz" + CRLF
                        + "Content-Type: application/xml; name=" + attachmentName + CRLF
                        + "Content-Disposition: attachment; filename=" + attachmentName + CRLF
                        + "Content-Transfer-Encoding: base64" + CRLF + CRLF
                        + encoder.encode(inputString.getBytes("UTF-8")) + CRLF
                        + "--" + "--Zz" + CRLF
                        + "Content-Type: application/pdf; name=" + pdfName + CRLF
                        + "Content-Disposition: attachment; filename=" + pdfName + CRLF
                        + "Content-Transfer-Encoding: base64" + CRLF + CRLF
                        + encoder.encodeBuffer(new BASE64Decoder().decodeBuffer(pdfAttachment));
    Regards,
    BR.
    Ricardo Viana.

Maybe you are looking for

  • Why does my mid-2010 macbook pro keep restarting? Kernel panic?

    Please help, I work solely on my mid-2010 macbook pro. Lately it has been restarting itself more frequently. I should take it in, but it's hard to be without it for any extended period of time. I was hoping someone could take a look at my crash repor

  • Error while saving the PO, "Update terminated".

    Hi All, A framework PO is created on 23 Nov 09. The valdity period is from 23 Nov 09 to 22 Nov 10.It was never released or processed. The delivery dates for all item is 22 Nov 10. When we make any changes in that PO and save it we get the message, "M

  • Problem mapping response of JDBC receiver adapter

    hi everybody, I have the following problem. I want to retrieve data from Oracle DB. I execute the following sentence: "Select count(*) from X". I'm doing that by means of action=SQL_QUERY. The response is something like that: <?xml version="1.0" enco

  • Table based on one data service but filtered by a second data service

    Hi, I'm fairly new to VC and have got comfortable with a few simple scenarios. However, I'm trying to apply some fundamental logic that must be possible and I'm guessing straight forward. I have a data service that contains document type master data

  • Wrong Apple ID's keep popping up on phone

    At one point in time, my brother, sister, and I all shared one computer. We shared all of our music because of this. We no longer share music libraries. On my iPhone now, their ID's keep popping up asking for their passwords even though I don't have