danititiriga
New member
- Local time
- Today, 05:34
- Joined
- May 20, 2020
- Messages
- 9
Hello.
I am trying to make a report (from a movie list) in which, according to the length (in minutes) of the movie, Access displays a text message in my report.
I tried using an iif function but to no avail. I then decided to turn to a switch function, but I kept on getting the following error message: "The expression you've entered contains invalid syntax. You may have entered an operand without an operator." And when I clicked enter and went into report view anyway, in that field was displayed the following text: "#Type!".
This is the function that I have entered in the ControlSource field: "= «Expr» Switch([durata]=120;"Durata e de doua ore";[durata]=90;"Obisnuit'";[durata]>120;"Doua serii";[durata]<120;"Doua serii") ". The [durata] field is the length of the movie in minutes. The first value displays a message that says that the movie is 2 hours long. The next one says that it's of normal duration and the last two say that it's a series of movies.
Can anyone tell me what is wrong with the syntax in this function, please?
I can't find any solutions anywhere.
I am trying to make a report (from a movie list) in which, according to the length (in minutes) of the movie, Access displays a text message in my report.
I tried using an iif function but to no avail. I then decided to turn to a switch function, but I kept on getting the following error message: "The expression you've entered contains invalid syntax. You may have entered an operand without an operator." And when I clicked enter and went into report view anyway, in that field was displayed the following text: "#Type!".
This is the function that I have entered in the ControlSource field: "= «Expr» Switch([durata]=120;"Durata e de doua ore";[durata]=90;"Obisnuit'";[durata]>120;"Doua serii";[durata]<120;"Doua serii") ". The [durata] field is the length of the movie in minutes. The first value displays a message that says that the movie is 2 hours long. The next one says that it's of normal duration and the last two say that it's a series of movies.
Can anyone tell me what is wrong with the syntax in this function, please?
I can't find any solutions anywhere.