Step 8: Run the code above from the run button as shown and we will see the following result as we run the above code. Step 2: A code window will appear on the right-hand side of the screen. Step 1: Now once we are in VB Editor go ahead and insert a new module from the insert section. And we will see what will be the result displayed by the code. I mean to say that this time our expression for X will be AD. Now let us interchange the values for X from example 1. Both of the values of the condition were returned as false so our final output is also returned as false. Why we get the value as false because A is not greater than B and C is not greater than D. Step 8: Run the code from the run button provided in the screenshot below and then we see the following result when we run the above code. Step 7: Now we will display the value of X stored in it. Step 6: Define X’s Values as conditions for A B C and D. Step 5: Assign Random Values to A B C and D.ĭim A As Integer Dim B As Integer Dim C As Integer Dim D As Integer Dim X As String Step 4: Define a variable X to store the value of OR Function, define it as a string.ĭim A As Integer Dim B As Integer Dim C As Integer Dim D As Integer Dim X As String End Sub Step 3: Define the four variables A B C and D as integers.ĭim A As Integer Dim B As Integer Dim C As Integer Dim D As Integer End Sub
0 Comments
Leave a Reply. |