cancel
Showing results for 
Search instead for 
Did you mean: 

Reporte con parámetros opcionales

0 Kudos

Saludos cordiales tengo un reporte de cuentas por cobrar en Crystal el cual tiene un parametro que filtra por el nombre del cliente para ello uso una lista desplegable

Lo que deseo es que si no selecciono nada o ingreso la palabra "mostrar todo" muestre las cuentas por cobrar de todos los clientes y si selecciono un cliente muestre las cuentas por cobrar solo del cliente seleccionado.Como pueden observar mi parámetro se llama Nombre clientes y esta es la formula para que se ejecute el parámetro:

{? Nombre clientes} = GroupName ({Edo_Cuentas_Clientes.Nombre}) con esto filtra por un solo cliente, ¿Cual seria la formula para mostrar todos los clientes sino elijo a ningun cliente de la lista? Espero su grandiosa ayuda realmente necesito una solución gracias(Uso crystal 9.2) ...

Accepted Solutions (1)

Accepted Solutions (1)

ido_millet
Active Contributor
0 Kudos

If you want to use 'Show All' to indicate no filter:

{?Clients name} = "Show ALL" OR {Client.Name} = {?Clients name} ;

If you want to use no value to indicate no filter (and your Crystal version supports the HasValue() function):

IF HasValue({?Clients name}) Then {Client.Name} = {?Clients name} ELSE TRUE ;
0 Kudos

Hi thanks for answer if I use this formula: {? Clients name} = "Show ALL" OR {Client.Name} = {? Name of clients}; It does not show any result if you do not Add any client or select the word "Show ALL", and crystal does not have hasvalue, any other possible solution please

Answers (4)

Answers (4)

0 Kudos

Please help me, how would the formula be, I use this to filter {? Clients name} = GroupName ({Edo_Cuentas_Clientes.Nombre}), how I modify it to bring all the content, ¿can you make an example conditional formula, which brings everything if nothing is selected or has the word everything, and filter if there are some selected customers? please

0 Kudos

Thank you for translating.

You would not use any filtering, would be the same as All.

0 Kudos

Ok sir,i will try.What I want is that if I do not select anything or enter the word "show all" it will show the accounts receivable of all clients and if I select a client it will show the accounts receivable only of the selected client. As you can see, my parameter is called Client name and this is the formula for the parameter to be executed:

{? Clients name} = GroupName ({Edo_Cuentas_Clientes.Nombre}) with this filter by a single client, what would be the formula to show all clients if I did not choose any client from the list? I hope your great help I really need a solution thanks (I use crystal 9.2)

0 Kudos

English please....