Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
henrikalmen
Specialist
Specialist

Blank space format problem

I have a strange problem. If for example I want to format a number value like num(4711, '# ##0') the output becomes 4711 ##0. But if I open up an object properties window, go to number tab and mark integer and then I copy the format pattern displayed (# ##0) I can paste this format pattern into my formula and the result is 4 711 as expected. My manually typed blank space seems different than the blank space that I've copied! (Copying the blank space is enough, I can type the #-symbols and the zero manually.)

It's kind of absurd and I'm attaching a qvw with a simple text box illustrating this, and a small load script that illustrates that it happens there as well.

I don't understand why this is happening, do you?

1 Solution

Accepted Solutions
robert_mika
Master III
Master III

This is not a space

This is no-break space

ANSI code 160

View solution in original post

9 Replies
pokassov
Specialist
Specialist

Hi!

I've used function ord() for both "blank spaces".

It looks like there are different kinds of blank.

16.png

robert_mika
Master III
Master III

This is not a space

This is no-break space

ANSI code 160

henrikalmen
Specialist
Specialist
Author

Oh! But do you mean that it should be a no-break space instead of the ordinary space that I have written? Or do you mean that my spacebar for some reason produces no-break space?

PrashantSangle

Hi,

in Load script change set ThousandSep=' ';

It will work

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
henrikalmen
Specialist
Specialist
Author

My last question was unnecessary, I can of course see for myself that my spacebar works as intended but I did not know that I should be using a non breaking space in thsi situation. Thank you for your fast replies!

robert_mika
Master III
Master III

The first.

Your spacebar produce 32 not 160.

Fallow max advice.

henrikalmen
Specialist
Specialist
Author

Aha, that's where the non breaking space was defined. Thank you! Is there a reason..? Is it better to use non breaking space than ordinary space?

robert_mika
Master III
Master III

This should shed some light:

stackoverflow.com/questions/1357078/whats-the-difference-between-nbsp-and

henrikalmen
Specialist
Specialist
Author

Ah yes of course, it will actually work as a non breaking space when used. Should have guessed that myself, but thank you! 🙂