Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I simply want to change the background button image, if a use hovers over it. This is something I've done with Javacript in the past. Is this possible in QlikView? I'm very new to QlikView.
I've googled, you tubed and looked on the community for this but can't find anything useful.
Thanks in advance!
Greg
I know I have a lot to learn, but I have even more to learn than I expected!
Are you able to explain to me how I can see the code you used to create that example, now that I have it downloaded?
It was nearly perfect! One potential issue of, if the document is clicked, the hover color will eventually freeze, but this is exactly what I was looking for, if I can see how it was done. Thanks for expediting the process!
You have to be familiar with Javascript and jquery library
// You can load a CSS if you want
Qva.LoadCSS("/QvAjaxZfc/QvsViewClient.aspx?public=only&type=document&name=Extensions/Hover/Hover.css");
Qva.AddDocumentExtension('Hover', function () { // Attach the extension to your document
var oldcss = "";
this.Document.SetOnUpdateComplete(function () { // Attach a handler to QV, 'when you finish, please call me'
$('table.TextObject').hover( // Please google for jquery hover function
function (){
oldcss = $(this).css("background-color"); // saves last background color
$(this).css("background-color","blue"); // sets new background color
},
function (){
$(this).css("background-color", oldcss); // restores background color
});
});
});
//
Thanks! I don't think I worded that last question very well. I am actually trying to figure out where the QAR file stored the .js file and how to tie it into the qvw file.
I'm slowly picking that up. The qar file is an extension that is applied by doing to Document properties and moving the Hover Extension over to the Active Extensions side.
I used the LoadFirebug extension to look at the HTML to see that the source script was QvAjax.js
I can walk through the jsavascript some, but it has been a few years, as I've mainly worked with SQL for the last several years. I have a lot of studying to do. Thanks again for your assistance!
Document Extensions resides in C:\Users\[youruser]\AppData\Local\QlikTech\QlikView\Extensions\Document
Document Extensions are applied to a document (qvw) using Document Properties / Extensions Tabs
There´s another type of extension (Object Extensions, under C:\Users\[youruser\AppData\Local\QlikTech\QlikView\Extensions\Objects) that implements visualizations that QV can´t do "out of the box"
Please check your folder C:\Program Files\QlikView\Examples\Extensions there´s some samples of Object Extensions too
You can add my skype: cleveranjos, we can chat to help you better
Thank you. If I ever get a skype account, I will definitely add you. This has been tremendously helpful and a lot of things fall into place. I still have so much to learn to be able to appropriately apply this, but this is all a great start!
You could invest some time reading this link http://www.qlikfix.com/2012/07/03/qlikview-extension-tutorials-documentation-and-examples/
and its tutoriais.
It would be very enlightening
When unzipping "Hover.qar", I noticed you don't include "Hover.css". Will the extension still work?
I´m using Jquery to overwrite the CSS
$(this).css("background-color","blue");
Hi,
can u give the same code for Qliksense to do the on click function on a element button to change the background color of it.