Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I dont know if anyone can help me with a problem I have .
On a sheet I have 4 filter panes and 3 tables. 2 of the tables are on one alternate state and the third on a separate one. The reason for this is when I search, in most cases it will be a serial number, it only returns one row. On that row there is a registration number that can have several serial numbers assigned to it but only the filtered one will be displayed. I want to display all the serials assigned to that registration number. The main problem is that the registration number will be unknown at the time of searching otherwise I could just filter by that. Normally only the serial number is known. I want to use the registration number to act as the filter in the third table. What I need to have is the variable from one state to set the value for a different alternate state. i am not 100% sure this is possible.
The variables are vReg_Pack wit ha definition of =REG_PK. This works fine.
and
vRegistration_Pack with a definition of =$({Reg Pack}REG_PK) but I think this is probably the wrong definition
what I need is for vReg_Pack to equal vRegistration_Pack or the other way round
Any help will be greatly appreciated
i think they will have to do it manually. They can search for the serial number then take the reg number and enter that into the filter pane. Its not that much of an issue. I was just trying to make things easier for them.
Thanks for the help
You can try with something like
=Only({Reg Pack}REG_PK)
No that didn't work. Tried using in the expression and the variable separately but both returned the error of "Error in expression'}' expected". Tried copying as well as typing it out.
Yes, sorry, as there is a space in the name of your alternate state you have to use brackets or double quotes:
=Only({[Reg Pack]}REG_PK)
Thanks. that probably explains a lot of the issues i have seen.
i think they will have to do it manually. They can search for the serial number then take the reg number and enter that into the filter pane. Its not that much of an issue. I was just trying to make things easier for them.
Thanks for the help
i have revisited this issue and I have got an expression that works but very strangely only once. The expression is =if({inherited} vReg_Pack = {[Reg Pack]}REG_PK,{[Reg Pack]}REG_PK). What it does is takes the variable vReg_Pack from the alternate state "inherited". It then compares that value to the values in the REG_PK column in the other alternate state " Reg Pack "and if it matches it then displays it in the table in the alternate state 2Reg Pack". When I enter the expression and click apply it applies the expression and filters the table correctly. The problem is when I change the serial number the table stays the same even though the variable vReg_Pack changes. Even stranger if I go back into the expression and edit it and then apply it again it will work. Is there a command I am missing that sort of retriggers the expression or something
Thanks for any ideas
Try like this, I've noticed in the past that sometimes QS is not updating variables but using the variable expansion syntax works better:
=if($(={inherited} vReg_Pack) = $(={[Reg Pack]}REG_PK),$(={[Reg Pack]}REG_PK))
or if the variables are strings
=if('$(={inherited} vReg_Pack)' = '$(={[Reg Pack]}REG_PK)','$(={[Reg Pack]}REG_PK)')
i tried that but got the message below
I counted the brackets and they match
the string one didn't return an error but it also didn't return any data