I've already asked about the column value display, for which in a dialog list selection, there will be 3 columns and when the user select one, the alias in the view selection would be reflected in the dialog list field. But my problem now is that the value stores in the back end, so user cannot see it visually while editing the form. Is there anyway possible that the value would display instantly after selection? I've tried making a "Computed for display" field, but that makes it pretty much redundant.
Here's my column value code:
SiteNum + " " + Site + " " + State + " | " + SiteNum
And my dialog list formula:
@Unique(@DbColumn("" : "NoCache"; @DbName; "SiteLookupView"; 4))
Thanks!
If you need both, the "visible" value and the "alias" then I usually do it like that:
Field, Multivalue, Name "SelectionList", Hidden from User, Formula:
@Unique(@DbColumn("" : "NoCache"; @DbName; "SiteLookupView"; 4))
Field: DialogList, Name "Selection" (or whatever fits best), "Use Formula", and as Formula simply:
SelectionList
Field: Text, Name: SelectionReadable, Computed (if needed in a view) or Computed for Display (if needed only in Read- Mode), Formula:
@Replace( Selection; @Word( SelectionList ; "|" ; 2 ) ; @Word( SelectionList ; "|" ; 1 )
Now you can e.g. hide "Selection" when in Read- Mode and "SelectionReadable" when in Edit- Mode and if SelectionReadable is not Computed For Display then you can even use it in Views.
Is this redundant? Yes it is, but that's the way you do it in Notes...