Changing default colors of QlikView

    Hi all,

     

    If you ever had the feeling that the default colors of QlikView are a bit harsh and you want them changed into something a little more subtle or more in line with the style that you use in your dashboard and the default color schemes in qlikview don't do the trick?Knipsel.PNG

    There is a way. Even on a QlikView server and this is how:

    - set your color scheme to [Custom]

    - press Ctrl+m

    - add the below code

    Sub SetColorPrefs()
    Dim UserPrefs
    set UserPrefs = _
    ActiveDocument.GetApplication.GetUserPreferences
    ' Set the "Selected" Color
    UserPrefs.CustomSelBgColor(1).PrimaryCol.Col = _
    RGB (0,0,255) ' Blue
    UserPrefs.CustomSelFgColor(1).PrimaryCol.Col = _
    RGB (255,255,0) ' Yellow
    ' Set the "Possible" Color
    UserPrefs.CustomSelBgColor(2).PrimaryCol.Col = _
    RGB (255,255,0) ' Yellow
    UserPrefs.CustomSelFgColor(2).PrimaryCol.Col = _
    RGB (0,0,0) ' Black
    ' Set the Excluded Color
    UserPrefs.CustomSelBgColor(5).PrimaryCol.Col = _
    RGB (200,200,200) ' Light gray
    UserPrefs.CustomSelFgColor(5).PrimaryCol.Col = _
    RGB (0,0,0) ' Black
    ' Set the Locked Color
    UserPrefs.CustomSelBgColor(0).PrimaryCol.Col = _
    RGB (255,0,0) ' Red
    UserPrefs.CustomSelFgColor(0).PrimaryCol.Col = _
    RGB (0,0,0) ' Black
    ActiveDocument.GetApplication.SetUserPreferences _
    UserPrefs
    end sub
    
    
    

    - press check it should say : *** Ready ***

    - press Test

    Knipsel.PNG

    - and press OK

    You will see that the selection colors changed into blue instead of the QlikView green, and possible selections changed into yellow, and you can change this into any RGB color! And please do change it from something different then blue and yellow.

     

    To have this working on a server you need to follow a few different steps, these are as follows:

    - Locate your Settings.ini file in C:\Users\username\AppData\Roaming\QlikTech\QlikView.

    - Open the file in Notepad and locate the CustSel entries. Select them all and copy.

    - On the QlikView Server, stop the QlikView Server Service.

    - Locate the Settings.ini file in C:\ProgramData\QlikTech\QlikViewServer.

    - Paste the CustSel values from the user Settings.ini file at the bottom of the [Settings 7] section. Save the file and start the QlikView Server.

    - Open the document in the browser and see if the new color scheme has been applied. (they must have the [custom] color selected)

     

    Thanks to the QlikView for Developers Cookbook by Stephen Redmond I discovered this.

     

    Another standard color within QlikView is for example the help text.

    Knipsel.PNG

     

    It has a very distinct blue color, and you can change this too!

     

    what you first need to do is create a project folder, make a new folder where your QlikView app is located and rename it accordingly with -prj added behind it so if your app is called test.qvw your folder is going to be named test-prj. Now just save your app and in the project folder and the folder will look something like this:

     

    Knipsel.PNG

     

    Open DocProperties.xml with Notepadd++ or something similar and search for <DefaultHelpPopupProperties>

    And just change the RGB colors to your liking, you can even remove the question mark icon by clearing, likte this:

    <Icon></Icon>


    By opening any of the other XXNN.XML files you can change all the properties of the object. even the ones that you can only change very finicky like fonts.


    one of the things that I do is open all the XML's and search all and replace all like this:

    <FontName>.*</FontName>       --> <FontName>Calibri Light</FontName> (this changes any font in calibri light)

    <Font></Font>                             --> <Font><FontName>Calibri Light</FontName><PointSize1000>10000</PointSize1000></Font> (if no font or or size is described (x-as y-as) it is changed like this)


    Thanks for reading!


    Jasper