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

Free text box

Hi guys,

Is it possible to create a free type box and then do a calculation with that field?

What I am thinking is creating a box which will be called discount which is a free type field.  I then have a price column in the data base.  I would like to create a new expression which will be the discount minus the price.. So 10 in discount box would be subtracted from the price field in my new expression.

I am thinking out loud so hopefully this makes sense!?

8 Replies
Anonymous
Not applicable
Author

Hi!

I don't know if I understood it right, but what you're looking for is something like this?

Regards,

Gabriel

jer_2011
Creator II
Creator II

hola,

espero te sirva estos pasos

ejemplo_13102014.png

expresión de ejemplo:

=sum(campo3) - ((sum(campo3) /100) * Vejemplo )

saludos espero te sirva

maxgro
MVP
MVP

create an input box object and then use the variable of that input box in your expression

Anonymous
Not applicable
Author

Thanks for your help so far guys.  Could i take this one step further and add a free type column to my table?

Capture.JPG.jpg

At the moment the discount column is being populated by a table in the database.  Could I create a column within the table layout and free type the discount into it?

If this isn't possible i will just go with a free type text box which you have mentioned

Anonymous
Not applicable
Author

Hi!

I don't think that is possible to create a input data column on your grid.

Regards,

Gabriel

Peter_Cammaert
Partner - Champion III
Partner - Champion III

Sure you can, but you'll have to create this extra column in your load script.

In your script, somewhere at the beginning, define an inputfield like this:

INPUTFIELD Discount;

When loading your data, a little further on in your script, add an extra field with the same name as the inputfield definition. You can load a global default value in this field (using a variable set in an input box) or you can load a value from an existing table using applymap.

When you show this field in a UI object (a Table Box for example), it will be changeable. See the INPUTFIELD help in QV Desktop.

matthewjbryant
Creator II
Creator II

Sorry to reignite this thread, but this is the correct answer. Thanks! I've read the help and in says you can edit this field in "list box cells, table box cells and in table chart expression", but I can't seem to edit it in a table box.

Should this be simple and I'm being an idiot?

Edit: I was being an idiot. Reading on further "A table chart expression cell must contain a Special Input Field Aggregation Functions to be open for input"

Peter_Cammaert
Partner - Champion III
Partner - Champion III

Better start a new discussion. You'll get a better focus.

Peter