Setting different text colors within 1 formula field

Post Author: hassan.annous
CA Forum: Formula
Suppose I am interested in coloring each part of a text returned by a formula field with a different color.
For example I have the following string:
Local StringVar Diagnosis := "I am trying to color my text.";
And I would like to color "I am" in red, "trying to color" in blue, and "my text" in green.
Is that possible (using Crystal Syntax)?

Post Author: tyanksar
CA Forum: Formula
Yes, but suppose I have field that outputs this text: "I have 1000 Cars"
The "1000" is dynamic (embeded field), which means it could go to 1000000 (increasing the number of digits) and then shif the word "Cars" to the right. What I need is to color this "1000" .
I do not want to seperate the "1000" to another text box. this will not shift the "Cars" to the right when the digit increases. Also it is not convenient to expand the text box as well, it will look like this: "I have 1000          Cars".
Any solutions?

Similar Messages

  • Can quotation marks be displayed within a formula field?

    I am wondering if anyone has a method they may know of to allow the display of quotes within a formula field.
    Example: I have an if then statment I would like to display "The term "Owner" means...." with the quotes around the word "Owner" appearing in the report.
    This sentence is in the middle of a pargraph which doesn't lend itself to leaving the quotes in a text box on either side of the field.
    Thank you.

    Try:
    "The term 'Owner' means...."
    or
    'The term "Owner" means....'
    Edited by: Sanjay Kodidine on Dec 2, 2009 10:49 AM

  • Can I set the text color in a Label?

    Hi everyone ~
    Can I set the font color in PP? I only found that there is a "setBackground".. but I want to set the color within a Label.
    Thanks!
    Gary

    Fixed it!
    There was a global style for s|Label and since the Spark button uses one of these for the text, that was it.

  • Set different fonts etc  within title?

    How do i set different fonts/sizes etc within the one title in 'basic text'?
    I, for example, I wish to create lower thirds and want to add another layer of text with different attributes, how do i add 'text 2' or 3 or even 4?
    And, if I'm in the 'lower third' preset, how do i add alignment options, if i need more?
    cheers

    Best you can do using 'Basic text' or 'Lower 3rd', is to create a new text clip for each change you want to make and stack them on top of each other. You can use the 'Basic Motion - x/y parameters' in the Motion tab.
    You have better independent sizing options using Boris Title 3D, but you will still be limited in independent alignment options without creating additional layers.
    K

  • Setting the text color

    Hi
    Does anybody know the syntax for changing the text color for workspace customization ?
    like for backgorund color ,we have color = "background-color:IndianRed"
    Ritu

    Hi Ritu,
    If you're trying to change the color inside of the bpmworkspace.css (the default CSS for the Workspace) to Indian Red you could do this:
    .bpmWorkspaceHeaderUser {
         background-color:#cd5c5c;
         width:100%;
         text-align:right;
    . . .If you're trying to change the background or foreground color of a label or field on a BPM Object presentation, you could do this:
    // set the first label on a presentation to Red
    setForegroundColor this
       using componentId = "label0", 
          color = Fuego.Ui.Color.INDIAN_RED.rgb()
    // set the first text field's background color to Red
    setBackgroundColor this
       using componentId = "text0", 
          color = Fuego.Ui.Color.INDIAN_RED.rgb()This logic would be run from inside a BPM Object's method to dynamically change colors on a Presenation. This would set the first label's ("label0") foreground and the first text field's ("text0") background color to Indian Red. You'd normally have the method invoked either as an initialization method for the presentation (click the outer edge of a presentation -> click the "Properties" tab -> change the method invoked when the presentation initializes by changing the "Initialization method" property) or as the method invoked by a field's "On change invoke" property.
    Note that "label0" and "text0" are the names of the label and text fields on a specific BPM Object's presentation and not the name of an attribute inside the BPM Object. To uncover their specific names, open the BPM Object presentation -> click the label or field -> open the "Properties" tab on the right -> look at the value inside the "Name" field.
    You can see the other colors available if from the Project Navigator tab if you expand the "Catalog" -> expand "Fuego" -> expand "Ui". The upper case attributes listed are enumerations. The string's needed for the "setForegroundColor" and "setBackgroundColor" methods are returned using the catalog's Fuego.Ui "rgb()" method.
    Hope this helps,
    Dan

  • How to set selected text color in Spark TextInput

    I'm trying to make Spark TextInputs and MXFTETextInputs look like Halo/MX TextInputs as much as possible, since I have a mix of both Spark and MX TextInputs in my application. I know I can set the
    selection background color to black using focusedTextSelectionColor. How can I set the selected text color to white so it matches the MX white-on-black look?

    This works, if you set the enabled property directly on the s:TextInput:
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx">
        <s:layout>
            <s:VerticalLayout horizontalAlign="center" verticalAlign="middle" />
        </s:layout>
        <s:controlBarContent>
            <s:CheckBox id="ch" label="enabled" selected="true" />
        </s:controlBarContent>
        <fx:Style>
            @namespace s "library://ns.adobe.com/flex/spark";
            @namespace mx "library://ns.adobe.com/flex/mx";
            s|TextInput:disabled {
                color: red;
        </fx:Style>
        <s:Group>
            <s:TextInput id="ti" text="The quick brown fox jumps over the lazy dog" enabled="{ch.selected}" />
        </s:Group>
    </s:Application>
    It can get a bit trickier when you're setting the enabled property on a parent container, since (I believe) that the child control's enabled properties are still set to true and just the container is disabled. One possible workaround would be to bind the child TextInput control's enabled property to the container's enabled property. That way the s:TextInput should still go to it's disabled state and you can customize the disabled state's styles to have darker text, or whatever else you want.
    <s:Group id="gr" enabled="{ch.selected}">
        <s:TextInput id="ti" text="The quick brown fox jumps over the lazy dog" enabled="{gr.enabled}" />
    </s:Group>
    Peter

  • FormatType="number" sets different background color too

    Hi all!
    I have an af:table element and af:column inside that has formatType="number" to get the right-justified text. But beside right aligning the column values the column becomes gray. I don't like having text columns white and number columns gray in the same table. Is this a deliberate feature?
    I would like to set the background color to white, but background-color property for this column is not considered. If I set the background-color property for af_outputText inside this column I also don't get the desired look.
    Thanks!
    Take care!

    Hi Frank!
    I've created ADF read-only table for my view object. If I run the page immediately after this, all columns are white with gray headers which is OK. Then I change only the formatType property for one column:
    <af:column sortProperty="Mass"
                     sortable="false"
                     headerText="#{bindings.MyView.labels.Mass}"
                     formatType="number">
      <af:outputText value="#{row.Mass}">
      <f:convertNumber groupingUsed="false"
                                pattern="#{bindings.MyView.formats.Mass}"/>
      </af:outputText>
    </af:column>This makes the text in this column to be right aligned but also the column becomes gray.
    Hope to hear some more suggestions from you.
    Thanks, bye!

  • Different text color options?

    What is the difference between changing text color through the drop-down color swatch options and the recolor artwork option?

    Under what circumstances?

  • UITableView: set different background colors for header and the table

    I would like to set my background color for my UITableView to white and set my tableViewHeader backgroundColor to grayColor similar to the facebook app. When I bounce scroll my table so that you can see above the header, then currently it is white above the header view. I want that to be brown instead.
    In the facebook app, above the headerview, it is a blue color and below the table is a white color. If i try and set the UITableView backgroundColor to brown, then the top will be brown, but so will the bottom. Additionally, all of the unset cells will have a brown background instead of white.
    Any help with this?

    Fixed..

  • How to set the text color in a Canvas?

    When I use (Graphics) g.setColor(255,255,255), then g.drawString("xxx", 0, 0, ....);
    the simulator works well but it can't work in my mobile phone (Nokia 7650).
    What's wrong?
    Thanks.

    do it like this
    g.setColor(255,255,255);//this will set the color for the canvas
    g.fillRect(0,0,ht,wd);//this will fill the rect(screen) with the above color,actually this will be BG color for ur app..ht,wd are the height and width of ur canvas...
    now specify color for the text
    g.setColor(r,g,b);//this color shud ofcourse be diff frm the color set for BG
    now draw the string
    g.drawString("xxx", 0, 0, ....);

  • Can't set the text color of a Spark Button

    I'm pretty new to Flex and working on a project with a more senior developer - who's out for a few days. I hope this is a simple question!
    I've got a CTA button that I want red with white text. This is how I'm doing it:
    in fx:Style ...
    .startButton {
    fontFamily: "MyriadPro";
        fontSize: 24;
        chromeColor: #e41937;
        color: #ffffff;
        cornerRadius:7;
    the button ...
    <s:Button styleName="startButton" label="Start" click="currentState=PracticeState'" height="40" width="100"  />
    All of the properties from the style apply except for the color property. Any ideas why it wouldn't? There may be a master style that I'm not aware of, but shouldn't addin the style property here override?
    Thanks!

    Fixed it!
    There was a global style for s|Label and since the Spark button uses one of these for the text, that was it.

  • AnyGantt: How to set different bar color depending on data value.

    Need to have different colors for bars in a gantt resource chart.
    The color depends on certain data value not included in the visible part of the chart, so it must be provided 'extra' for the chart in some way without beeing visible.
    Have studied some examples but cannot figure out the mechanism for this, and the procedure to implement it.
    Any ideas?
    Apex 4.2.2
    Regards
    Per.

    Hi Per,
    You mention "+Among the samples I can see that it has been implemented, but not how.+" - in the Information region below the chart that Tony referred to (https://apex.oracle.com/pls/apex/f?p=36648:50) that I've stated the following:
    "The elements of the Timeline region have been customized via the Chart Attributes page, using the following settings: *Custom Colors*: #000000,#00FF00,#0033FF"
    So that's how I applied custom colours to that particular chart. However, that declarative option won't meet your requirements, where the colours you wish to apply are dependent on data not included in the chart series query. You mention "+Now, if I add another column to the statement I get a yellow error message telling that the statement is not valid.+". It is not possible to simply add an additional column to the chart series query. Each supported chart type expects the associated chart series query to use specific syntax - see About Creating SQL Queries for Charts in Chapter 10 of the APEX User's Guide, http://docs.oracle.com/cd/E37097_01/doc/doc.42/e35125/bldapp_chrt.htm#BCEIJJID.
    So to answer your question "+How to add the new value if not providing another column to the graph?+", if you wish to customise your chart to that extent, then you will need to use custom XML. Depending on what exactly you're trying to achieve, this may require the generation of custom data for your chart. If you edit your chart, and take a look at the Custom XML region, you'll notice a substitution string, #DATA#, towards the end of the XML. When a chart is rendered, we use the chart series query to generate the necessary XML to represent the data on the chart, replacing the string #DATA# with the actual XML. The format of the data XML generated for gantt charts uses a bar style called "defaultStyle", and this handles the default appearance of the bars in the timeline region e.g.
    <period resource_id="1" start="2009.03.21 00.00.00" end="2009.09.21 00.00.00" style="defaultStyle"/>You'll see that the 'style="defaultStyle" ' attribute of the data corresponds to a segment of XML outlining what that style is e.g.
    <period_style name="defaultStyle">Now take a look at the Bar Style in Resource Project example in the AnyChart online documentation http://www.anychart.com/products/anygantt/docs/users-guide/bar-style.html#bar-style-application-resource-project. In that particular example, a number of different bar styles are used i.e.
    <periods>
      <period resource_id="server_1" start="2008.07.07" end="2008.07.8" style="Working" />
      <period resource_id="server_1" start="2008.07.8" end="2008.07.12" style="Maintance" />If you need to add a different bar style to particular rows of data on your chart, then you'll need to add new bar style XML for each colour you wish to use in the Custom XML on the Chart Attributes page, and then you'll also need to generate the data XML yourself, applying the necessary bar style to the relevant row of data. I've got an example of how custom data can be generated for a Resource Gantt here e.g. https://apex.oracle.com/pls/apex/f?p=36648:73 but keep in mind that particular example doesn't demo adding different styles to the data...but it can certainly give you an idea of what's entailed in the generation of custom data for your chart.
    I hope this helps.
    Regards,
    Hilary

  • Interactive button which sets different background colors?

    Hi, I was wondering if it is possible to make a button where it is possible to change from color each time you click on it, so I can use it as a label.
    The button is white in the first state, when you click on it it becomes green, when you click again it becomes orange and when clicked again it becomes red.
    Is this possible? Any help is appreciated.

    It´s not very hard to do that kind of button in InDesign by using show/hide fields. If it´s more complicated, if there´s more colors, it may become more time consuming to make.
    Here´s my quick sample, made with InDesign (open with Adobe Reader or Acrobat, as Steve mentioned, other readers won´t work that well):
    https://dl.dropboxusercontent.com/u/17227987/buttons.pdf
    If that´s what you are looking for, feel free to explore original InDesign file:
    https://dl.dropboxusercontent.com/u/17227987/buttons.indd
    Note that there´s actually 4 buttons, one for each color, they are just stacked. Button´s visibility is simply changed by a click, visible button will be hide and next color will be shown etc...
    The question is what else your button is supposed to do. You can attach multiple actions to one buttons so it´s possible to make that button do something else too - when clicked....

  • Subtitling 2 characters with 2 different text colors.

    Hello,
    Is there a simple & efficient way to subtitle 2 characters using 2 different colours? For example, character A would be white text, character B would be yellow text.
    I have FCP7 and LiveType 2.1
    Thanks,
    Marc Griffin

    Make the title the way you like it for one character. Drag it to the browser. Make the title for the second character and drag it to the browser. The browser titles become templates for your subtitles.

  • Setting the colour red for an input field or a text-field in a table

    Hy,
    I am using an input-field or text-field within a table-cell. For some rows in the table the text in the input-field / text-field should be red. How can I do this ?
    Florian Hroch

    Create a new attribute "TextColor" of type "com.sap.ide.webdynpro.uielementdefinitions.TextViewSemanticColor" (local DDIC types), under the table's data source node.
    Bind the "TextView.semanticColor" property of the table cell editor to this attribute.
    If you cannot add new attributes under the data source node (this is the case if there is a structure binding), add a value node "TableProperties" (cardinality 1:1, selection 1:1) under the data source node and add the attribute there.
    Then you can control the color of the TextView in table row at index i by setting the "TextColor" value for node element at index i.
    For an input field, you cannot set the text color, a workaround might be adding an icon in an extra column.
    Armin

Maybe you are looking for

  • Boot Camp and Adobe Professional

    My fiancee recently bought a Dell with Vista and had huge compatibility issues with Adobe Professional to the point where we had to return the computer. She now wants to buy a Mac, but we have about $700 sunk into Microsoft software (Adobe Profession

  • Capturing of credit on CVD in STO between a bonded warehouse and Manuf plnt

    Dear experts We have two plant A and B .Plant A is a bonded warehouse wherin material comes in without paying customs duty or CVd etc but in some cases when material is removed from this warehouse we need to pay import related duties.Another plant B

  • How can i get a brand new case for my iphone

    I NEED TO GET A BRAND NEW CASE FOR MY IPHONE BECAUSE MY IPHONE IS DENTED ON THE BACK AND SCRATCHES ALL OVER THE PHONE, IF SOMEONE CAN HELP ME I WILL APPRICIATED.

  • RMAN backup in no archivelog mode

    what are possible ways to backup the database which is in no archivelog mode using RMAN regards, Sakthivel Edited by: SAKTHIVEL on Jul 22, 2011 1:02 AM

  • Reinstalling acrobat pro after a reformat

        Good evening to all. I have a customer whose computer is being reformatted. The customer does not have an install cd because it was done as an internet upgrade. I found the serial number of the program and tried to reinstall it on the new hard dr