Visokio website     Downloads     Video tutorials     KnowledgeBase  
Format in dynamic content - Visokio Forums
Format in dynamic content
  • jforero     jforero February 15, 2011 10:55AM
    Currently, If you included a formula in a Content View is not available to use a styled text (Display value as).
    Do you have any plan to include this in the 2.6 version?
  • 8 Comments
  •     steve February 15, 2011 11:06AM
    Sorry, can you elaborate? You can select formulas and apply styles to them. You can also apply style rules to formula results.
  • jforero     jforero February 15, 2011 11:37AM
    Yes, sorry, please find attached the specific message that I am receiving when I used this formula, because when I used "Plain Text" works perfect the formula:

    Error:
    Fields are not accessible in embedded formulas
    Formula:
    DECLARE(value, TEXTVALUE((SUBSET_SUM([Value},...)
  • jforero     jforero February 15, 2011 4:54PM
    Steve, I found out that my issue is related with the output of this formula, which is "Text".
    Basically, I am calculating an operation which as a result I get a decimal number that I wanted to show as a percentage in a content view, therefore I am using TEXTVALUE to format the output that i wanted for this formula, please find an example of this view:
    Attachments
    PercentageOmniscope.png 137K
  •     steve February 16, 2011 3:20AM
    Can you post a complete formula, or even an IOK file?
  • jforero     jforero February 16, 2011 3:05PM
    Please found out the formula that I am using:
    TEXTVALUE((SUBSET_SUM([Value], SUBSET3([Metric],[Month],[Year],"Monthly Unique Visitors",SUBSET_SINGLETON([Month]),SUBSET_SINGLETON([Year])) ))/(SUBSET_SUM([PreviousMonth], SUBSET3([Metric],[Month],[Year],"Monthly Unique Visitors",SUBSET_SINGLETON([Month]),SUBSET_SINGLETON([Year])) ))-1, "#.#%")
  •     steve February 17, 2011 2:10AM
    Javier, you shouldn't be getting "Fields are not accessible in embedded formulas" for this formula. Are you?

    If you want to use the "Styled text" option, but also customise the style of the text, we are adding this ability and will let you know in the next few days.

    To work around it, you can insert styled text without the % formatting, then click the <> button and edit the underlying formula to add TEXTVALUE in the right place.

    Styled text is simply a more complex formula that writes HTML based upon your conditions; currently, using the <> mode is the only way to customise it.
  • jforero     jforero February 17, 2011 11:15AM
    Thanks is working now, I just wanted to mentioned that I had to change the code because I already got a variable called "Value" inside my data, therefore I had to change the declare variable with another label. You should be consider the possibility that the variable "value" could be include already in a dataset from an user.
    As an example, please find the new formula which is working perfectly:

    DECLARE(v,((SUBSET_SUM([Value], SUBSET4([Metric],[Month],[Year],[MetaBrand],"Product Detail Views",SUBSET_SINGLETON([Month]),SUBSET_SINGLETON([Year]),SUBSET_SINGLETON([MetaBrand])) ))/(SUBSET_SUM([PreviousMonth], SUBSET4([Metric],[Month],[Year],[MetaBrand],"Product Detail Views",SUBSET_SINGLETON([Month]),SUBSET_SINGLETON([Year]),SUBSET_SINGLETON([MetaBrand])) ))-1)," 0, " font-weight: bold; color: #9999; ", IF ( v < 0, " font-weight: bold; color: #ff0000; ", "")) +"\">"+TEXTVALUE(v, "#.#%")+"")
  •     steve February 17, 2011 11:18AM
    Javier, thanks for pointing this out - we'll fix.

Welcome!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Apply for Membership