Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
evan_kurowski
Specialist
Specialist

Color variables suddenly change necessity of having $() wrapping, when generated via QMC task

Hello All,

This thread covers some of the most subtle, but also one of the most consistently nagging adverse effects on Qlik development.

I've tried to develop a habit of always including the '=' equal sign before all expressions, and wrapping variables with the $().

Oftentimes however I am lured into a sense of syntax complacency, when omitting the equal sign or not wrapping the variable will still allow correct expression interpretation. Then eventually at some later juncture, this syntax is disrupted and the expressions revert to requiring leading '=' and the $() variable wrapping before functionality resumes.   

The good news is that playing it safe and always using the "long form" of expression syntax doesn't seem to revert.

 

So in this particular case, I have an application that is using color variables.The variable assignment was an RGB syntax without the leading equal sign, Lets call this variable MyColorVar

RGB(100,100,100)

 

This variable was then used throughout the QlikView application in color expressions, with the following exact syntax:
=MyColorVar

*Note: the expression has the leading equal sign, but not the $() wrapper

   

Usage of this expression worked fine in:

  • the desktop designer
  • the desktop webview
  • moving the app into a mounted user-doc directory and viewing on AccessPoint

  

However, the color expressions suddenly all stopped interpreting after a QMC task generated distribution copy.

I took a before and after copy of the application, and did full project exports, doing text comparison of the project files, and differences were detected in 4 files:

  • DocInternals - had 2 differences
    • It detected the desktop version of QV11.2 SR 12 vs. the earlier QV Server version   desktop: <SavedByVersion>11.20.12904.0409</SavedByVersion> QMC: <SavedByVersion>11.20.12852.0409</SavedByVersion>

    • Strangely the QMC version added an extra <String> field tag on one of the previously numeric fields.
  • DocProperties: <IgnoreInfoLost> switched from false to true
  • QlikViewProject: The timestamp in Last project change is different
  • LoadScript: the distribution copy load script is emptied

Every other project file is identical, all the color expression syntax, the variable values, the DocBinary.dat.  
But when I open the before and after copies of the .QVW, the colors of the objects are different.
  It appears the color expressions in the QMC generated distribution .QVW are failing, and objects with color expressions are reverting to the 'Fixed' colors assigned.

I can "repair" the application, by going back and wrapping all the variables with the $() wrapper, then the QMC version that is churned out is ok, but the idea the necessity of the $() wrapper can be "toggled" circumstantially I'm sure should be well understood.

Any ideas?

0 Replies