# Funciones básicas

## Contenido

[choose](/24/velneo-vdevelop/proyectos-objetos-y-editores/editores/asistente-de-formulas/funciones-estandar/funciones-basicas.md#choose)

## Básicas

Conjunto de [Funciones de fórmula ](/24/velneo-vdevelop/proyectos-objetos-y-editores/editores/asistente-de-formulas.md)básicas para la construcción de fórmulas.

### choose

Devuelve un valor u otro en función de una condición.

#### Sintaxis

choose(condición, datoSi, datoNo)

#### Parámetros

**condición**

Condición a evaluar por la función.

**datoSi**

Valor retornado si la condición se cumple.

**datoNo**

Valor retornado si la condición no se cumple.

#### Ejemplos

`choose( "Velneo" = "Velneo", "Correcto", "Incorrecto")` = Correcto

Esta función siempre evalúa los tres parámetros (condición, datoSi y datoNo) y devuelve el resultado que corresponda.

Mostramos un mensaje comparando el año de la fecha actual con el 2017, si es igual mostramos el mensaje 'Año 2017' y en caso contrario mostramos el mensaje 'Año distinto del 2017.

El mensaje de tipo 'Información' se mostrará durante 10 segundos con el texto 'Año en curso' en la caja de diálogo.

```
Mensaje ( choose(year(currentDate())= 2017, "Año 2017", "Año distinto del 2017"), Información, 10, "Año en curso" )
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.velneo.com/24/velneo-vdevelop/proyectos-objetos-y-editores/editores/asistente-de-formulas/funciones-estandar/funciones-basicas.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
