Search: | |||||

| ||||

Home » Forum » MS Office | RSS Feeds |

I am new to Excel VBA can someone please help.

I am trying to write a VBA Excel function that will cause Excel to

say "Fail" if the value entered in a cell is out of the required range.

If as a result of a calculation a cell's value changes. How can I get

Excel to act on that change.

Example:

Enter a value in Cell say B35 that is too high or too low

If B35 < 2.5 or > 3.5 Then say "Fail".

if(or(b35<2.5,b35>3.5), b35, "Fail")

air code... but i think it'll work

This can be easily accomplished using Excel's built in Data Validation feature.

You don't need VBA at all

Didn't find what you were looking for?
Find more on Action taken by Excel when a condition causes a cell's value
Or get search suggestion and latest updates.

Related Topics:

- Copying current cell's value to another cell
- Fill VBA form with Cell values of an Excel sheet
- Copy Value produced by formula in cell C3 to cell D3
- Update a cell based on a DDE updated cell value
- HOW TO FIND LAST CELL VALUE IN PARTICULAR COLUMN AND ROW IN EXCEL
- HOW TO FIND LAST CELL VALUE IN PARTICULAR COLUMN AND ROW IN EXCEL
- Taking Values from Storeprocedure into DataSet
- Updating a cell value when other cell value change....
- clearing cells value without deleting the formula I've made in cell from excel formula , HOW?
- if condition with negative value
- Copying Tables from Word and Pasting them to Cells in Excel
- Moving data in the last cell of row to another column cell
- Excel Merge Cells
- VBA Array - return value to a cell
- to see if text in a cell in a column is contained in any cell
- Using excel VBA to change a cell color
- How to animate cells in Excel
- how are cell coordinates referenced on a clicked cell
- VBA code to add values in two cells which have formulas
- Excel VBA Check When Cell Has Changed
- Get a cell value
- A very basic excel question about protecting cells
- How can I find the previous value of a cell after it has been chang
- how to split values from a cell
- how to color numeric character in excel cell ?