Hello,
I'm working on an Excel file to display the network class, subnet mask, etc. based on entered IP addresses.
An IF statement is giving me trouble and I'm pretty sure it's a simple rule or format I'm unfamiliar with.
With an IP of 192.168.1.1 in Cell A3, I used =FIND(".",A3,1) in Cell A1 to identify the location of the first decimal point and =MID(A3,1,A1-1) in Cell D1 to display the first octet, 192.
My issue is that when referencing Cell D1 to determine the address class, the IF statement is not displaying the correct result.
<tbody>
</tbody>
For troubleshooting I tried the following...
1. Cell D2 =IF(D1=192,"Y","N")
2. Cell D3 =D1 [192 is aligned left in the cell]
3. Cell D4 192 [192 is aligned right in the cell]
When the IF statement in cell D2 references
· D1 N is displayed
· D3 N is displayed
· D4 Y is displayed
Can anyone tell me why the IF statement is working only with Cell D4?
I'm working on an Excel file to display the network class, subnet mask, etc. based on entered IP addresses.
An IF statement is giving me trouble and I'm pretty sure it's a simple rule or format I'm unfamiliar with.
With an IP of 192.168.1.1 in Cell A3, I used =FIND(".",A3,1) in Cell A1 to identify the location of the first decimal point and =MID(A3,1,A1-1) in Cell D1 to display the first octet, 192.
My issue is that when referencing Cell D1 to determine the address class, the IF statement is not displaying the correct result.
A | B | C | D | E | F | G | |
1 | 4 | 8 | 10 | 192 | 168 | 1 | 1 |
2 | IP Address | Class | N | ||||
3 | 192 | ||||||
4 | 192 |
<tbody>
</tbody>
For troubleshooting I tried the following...
1. Cell D2 =IF(D1=192,"Y","N")
2. Cell D3 =D1 [192 is aligned left in the cell]
3. Cell D4 192 [192 is aligned right in the cell]
When the IF statement in cell D2 references
· D1 N is displayed
· D3 N is displayed
· D4 Y is displayed
Can anyone tell me why the IF statement is working only with Cell D4?