Selected Answer
Hi Rusli,
Please paste the following code in a module, create a button (Form Control) through the developer tab and assign the macro to the button. It will call the price in C7 if there is apple in B7 otherwise zero. Because you want to type the price in some cases, you'll have to press the button to refresh the data as per need.
Sub Price()
If Worksheets("Sheet1").Range("B7").Value <> "Apple" Then
'Or this:
'If Worksheets("Sheet1").Range("B7").Value = "" Then
Worksheets("Sheet1").Range("C7").Value = ""
End If
Worksheets("Sheet1").Range("C7").Formula = "=vlookup(B7,I7:J9,2,False)"
End Sub
Thank you!