-
Stealthy Select…
Hello Friends. I am Prabha Karan from Thanjavur (South India). When I was working yesterday in an access tool, I want to get a value from the user and check the entered value with some conditions. So I used the inputbox to get the value and want to use the select case statement to check the value under the conditions. Finally I wanted to display the entered text. How to display the entered text without storing it in a variable? I will give the code. Kindly, explain why this is not happening in this way? Thanks in Advance.
Select case inputbox (“Enter the value)
Case conditon1
….
…
Case condition2
….
….
Case else
“The value you entered is:” ‘Here I want to enter the input value but without using a variable which is an unnecessary one here logically.
End select
-
Idon't think it is Unecessary, it is certainly normal to set an Input to a Variable for later use, so why not stay with convention?
-
There is nothing unnecessary about using a variable for something as simple as this. Variables are containers for values that are used later on in the code.
The inputbox's value has to be written to a variable. You cannot reference it directly in a Select Case statement.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules