Mostrar el label solo si tiene contenido

Hola comunidad,

Necesito que las etiquetas que no tienen contenido no sean mostradas en las vistas.

Cuando comencรฉ ha hacer la app, utilicรฉ la opciรณn de โ€œshow ifโ€ para condicionar los formularios, logrando que me muestre determinadas columnas a rellenar segรบn la opciรณn ingresada en otra columna.

El problema es que no siempre esas columnas se rellenan con algo, pero cuando ingreso a la vista detallada me muestra la etiqueta de todos modos.

Estuve averiguando y al parecer debo usar la expresiรณn CONTEXT(), pero no descubro como hacerlo funcionar.

Espero puedan ayudarme, mucas gracias.

Hello community,

I need that the tags that have no content are not displayed in the views.

When I started making the app, I used the โ€œshow ifโ€ option to condition the forms, making it show me certain columns to fill in according to the option entered in another column.

The problem is that those columns are not always filled with something, but when I enter the detailed view it shows me the label anyway.

Iโ€™ve been researching and apparently I should use the CONTEXT () expression, but I canโ€™t figure out how to make it work.

I hope you can help me, thank you very much.

Solved Solved
0 5 475
  • UX
1 ACCEPTED SOLUTION

Looks like you need to spend some time learning how to construct Yes/No expressions.

AND(
  OR(
    ISNOTBLANK([_THIS]),
    ("Form" = CONTEXT("ViewType))
  ),
  ...
)

Your additional requirements would replace ....

View solution in original post

5 REPLIES 5

Steve
Platinum 4
Platinum 4

Try this as your Show? expression:

OR(
  ISNOTBLANK([_THIS]),
  ("Form" = CONTEXT("ViewType))
)

Gracias @Steve por tu pronta respuesta,

Lamentablemente no me funcionรณ. Voy a detallar mejor.

Tengo una Tabla โ€œProductosโ€, con su respectivo Formulario โ€œProductos_Formโ€ y el Detalle โ€œProductos_Detailโ€.

El Formulario tiene campos condicionados, por lo que al ir completรกndolo, este se ajusta a esas condiciones. Hasta allรญ todo bien. El problema surge cuando alguno de esos campos no tienen informaciรณn, porque no existe o porque no es necesario colocarla.

Es necesario que en el Formulario siempre aparezcan todas las opciones a completar, pero cuando estas no tengan informaciรณn, necesito que no me muestre la etiqueta en el Detalle

Formulario: Imagen1
3X_3_c_3ca50f5afcb9978885c466b6e276d369be3f1a4f.png

Detalle: Imagen2
3X_e_b_eb067e2765211fe66f328a9fadea6d542e105356.png

Para este caso, necesito que no me muestre la etiqueta de โ€œRpmโ€,โ€œAmpโ€,โ€œKwโ€,โ€œHpโ€ y โ€œHzโ€ en el Detalle, pero cuando presione el botรณn de โ€œEditarโ€ y me envรญe al Formulario si me los muestre, ya que puedo requerir agregarlos posteriormente.

Espero haber aclarado mejor mi duda.

Saludos y muchas gracias.

Thank you @Steve for your prompt reply,

Unfortunately it didnโ€™t work for me. I will detail better.

I have a Table โ€œProductosโ€, with its respective Form โ€œProductos_Formโ€ and the Detail โ€œProductos_Detailโ€.

The Form has conditional fields, so when completing it, it adjusts to those conditions. So far so good. The problem arises when some of those fields do not have information, because it does not exist or because it is not necessary to place it.

It is necessary that in the Form all the options to be completed always appear, but when they do not have information, I need it not to show me the label in the Detail

Form: Imagen1

Detail: Imagen2

For this case, I need it not to show me the label of โ€œRpmโ€, โ€œAmpโ€, โ€œKwโ€, โ€œHpโ€ and โ€œHzโ€ in the Detail, but when I press the โ€œEditโ€ button and send me to Form show them to me as I may need to add them later.

I hope I have clarified my question better.

Greetings and thank you very much.

Adjunto imรกgenes de los Show If de algunas columnas.

(Imagen 1) Show_If columna โ€œKwโ€
3X_0_b_0b95a7612910681ce20cab307e61a8cd656c3437.png

(Imagen 2) Show_If columna โ€œRpmโ€
3X_b_5_b541cf25cd1b000fc912394bb668f8b6f72962e2.png

Saludos

Attached images of the Show If of some columns.

(Imagen 1) Show_If column โ€œKwโ€
(Imagen 2) Show_If column โ€œRpmโ€

Greetings

Looks like you need to spend some time learning how to construct Yes/No expressions.

AND(
  OR(
    ISNOTBLANK([_THIS]),
    ("Form" = CONTEXT("ViewType))
  ),
  ...
)

Your additional requirements would replace ....

Muchas gracias,

Si, necesitaba entender mejor la funciรณn CONTEXT para comprender la fรณrmula completa.

Saludos

Thanks a lot,

Yes, I needed to understand the CONTEXT function better to understand the complete formula.

Greetings

Top Labels in this Space