Save only edited drawings

I have a field of type Drawing with an image in its Init Value, on which the unlock pattern of a cell phone must be drawn. I want to prevent the image from being displayed when no pattern was drawn, but I see that even if it is not edited, the default image is saved.
Can I prevent the image from being saved if nothing was drawn?

Solved Solved
0 2 162
1 ACCEPTED SOLUTION

If you are using a form for capturing the drawing, you could have an event action on form save something with an expression like below for the column [Dibujar Patron]

Action type" โ€œSet the values of some columns in this rowโ€

Column to set [Dibujar Patron] , Action Prominance: โ€œDo not displayโ€

Action Expression:

IF(โ€œhttps://upload.wikimedia.org/wikipedia/commons/9/9a/Sample_Floorplan.jpgโ€= [Dibujar Patron] , " ", [Dibujar Patron])

Here โ€œhttps://upload.wikimedia.org/wikipedia/commons/9/9a/Sample_Floorplan.jpgโ€ is a sample initial value of the drawing column [Dibujar Patron]
Please replace with the initial value you have.

Also, I could not write the Patron word properly as a letter equivalent of โ€œoโ€ I could not reproduce. Please replace suitably.

Below is an example where drawing is captured when altered or else it remains blank

View solution in original post

2 REPLIES 2

If you are using a form for capturing the drawing, you could have an event action on form save something with an expression like below for the column [Dibujar Patron]

Action type" โ€œSet the values of some columns in this rowโ€

Column to set [Dibujar Patron] , Action Prominance: โ€œDo not displayโ€

Action Expression:

IF(โ€œhttps://upload.wikimedia.org/wikipedia/commons/9/9a/Sample_Floorplan.jpgโ€= [Dibujar Patron] , " ", [Dibujar Patron])

Here โ€œhttps://upload.wikimedia.org/wikipedia/commons/9/9a/Sample_Floorplan.jpgโ€ is a sample initial value of the drawing column [Dibujar Patron]
Please replace with the initial value you have.

Also, I could not write the Patron word properly as a letter equivalent of โ€œoโ€ I could not reproduce. Please replace suitably.

Below is an example where drawing is captured when altered or else it remains blank

Excellent!
I had not seen that what it saved was the original path when it was not modified, I assumed that it saved copies of the image.
I just put in Show if:
IF(
CONTEXT(ViewType)=โ€œDetailโ€,
[Mostrar patron],
TRUE
)

I had to create a virtual yes / no column called [Mostrar patrรณn], containing the expression:

NOT([Dibujar Patrรณn]=[Sucursal Id].[Fondo Patrรณn]),

Since this did not work, although I do not understand why

     IF(
          CONTEXT(ViewType)="Detail",
          NOT([Dibujar Patrรณn]=[Sucursal Id].[Fondo Patrรณn]),
          TRUE
          )

Many Thanks!!

Top Labels in this Space