Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Gopi_E
Creator II
Creator II

How to bold a particular word in a total sentence in Qlikview

Hi Qlikers,

I hope every one Good !

I have one question which i am trying to , I had below data having feedback comments.

so here i am selecting feedback based on Word  which i enter in input field by using variable, So now i need to whatever word i searching in input field that word itself need to be Bold as below output table.

For Example i am searching World here, so i need to bold that after enter the word in input field.

Example Data:

SNoFeedback
1There's a world of good you could perform.
2All the money in the world couldn't have saved her.
3Betsy and I claimed world class ability while Quinn just rolled his eyes.
4You can know everything in the world and still make bad decisions.

 

Expected Output:

SNoFeedback
1There's a world of good you could perform.
2All the money in the world couldn't have saved her.
3Betsy and I claimed world class ability while Quinn just rolled his eyes.
4You can know everything in the world and still make bad decisions.

 

If you have any suggestions please let me know,

Thanks in advance!! 

Labels (1)
4 Replies
Taoufiq_Zarra

@Gopi_E  if I understood correctly the need

You can't have different font size , different color or text style in a single text object or list ...

Regards,
Taoufiq ZARRA

"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "

(you can mark up to 3 "solutions") 😉
Gopi_E
Creator II
Creator II
Author

Hi Taoufiq,

Thank you, 

Is there any different approach to do this like by using VB-Script like that ?

Taoufiq_Zarra

@Gopi_E  you can for example Split Column in 3 like :

Capture.PNG

and use Only(left(Feedback,Index(Feedback,MyVar)-1)) for the 1st Column and the same right in the 3rd

MyVar is the input text ....

Regards,
Taoufiq ZARRA

"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "

(you can mark up to 3 "solutions") 😉
Kushal_Chawda

@Gopi_E  You cannot highlight specific word  in entire string due to limitations. Either you will be able to highlight entire string where match is found or you can create the flag to identify the match.

Let's look at the below example. You can use below calculated dimension . Where vWord is your input variable

=if(index(lower(trim(Feedback)),' '&lower(Trim('$(vWord)'))&' ') or // in between string words separated by spaces
index(lower(trim(Feedback)),lower(Trim('$(vWord)'))&' ') or // First word with space suffixed
index(lower(trim(Feedback)),' '&lower(Trim('$(vWord)')))  //last word with space prefixed
, 'Found','Not Found')

With this you can have Flag which you can select it to look at where exactly the word match is found

Screenshot 2020-09-14 151301.pngScreenshot 2020-09-14 152305.png

You can also use the similar expression either in text color or background color expression of your feedback dimension to highlight where match is found

=if(index(lower(trim(Feedback)),' '&lower(Trim('$(vWord)'))&' ') or // in between string words separated by spaces
index(lower(trim(Feedback)),lower(Trim('$(vWord)'))&' ') or // First word with space suffixed
index(lower(trim(Feedback)),' '&lower(Trim('$(vWord)')))  //last word with space prefixed
, lightgreen())

Screenshot 2020-09-14 154744.png

 

Similarly you can also put the same expression in text format of the feedback dimension

 

=if(index(lower(trim(Feedback)),' '&lower(Trim('$(vWord)'))&' ') or // in between string words separated by spaces
index(lower(trim(Feedback)),lower(Trim('$(vWord)'))&' ') or // First word with space suffixed
index(lower(trim(Feedback)),' '&lower(Trim('$(vWord)')))  //last word with space prefixed
, '<b>')

Screenshot 2020-09-14 154919.png