Excel

  • Buffer
  • Sharebar
  • Buffer
jethro's picture

Excel function of the week INT

I am combining the function of the week with a request I had to write some VBA code to use it. (Note the VBA function is not always the same as the application function).

CBR001292_LoRes Here is the question I was asked:

I have two columns - One "AA" and the other "AB"
I want to fill down the column AB based on the results in "AA" but I'm
confused about how to get the individual data from AA2 into AB2 - for
example...
Dim AAcell As Range
Dim ABcell As Range
For Each AAcell In Range("AA:AA")
If IsEmpty(AAcell) Then
    ABcell.Value = ""
Else
    ABcell.Value = Int(AAcell.Value)
End Sub
I'm sure this isnt' right/correct - as it isn't working - LOL - but I'm not
sure how to put it...

Reading this through I understood that the reader wanted to be able to fill a column based on another column. If the first column had a blank cell he wanted that repeated in the new column. All other entries in the new column were to be the INTEGER of the number in the first column. I have provided the code used to make this work at the end of this article. Click Read More to continue.

jethro's picture

Excel function of the week - FIND and SEARCH

This week we will look at some text functions. FIND and SEARCH are essentially the same function with only minor differences.

magnifying-glass-778751

These functions both allow you to search through a text string (think sentence or word or phrase) in a cell and return the number of the starting character. So when cell A1 has The quick brown fox, =FIND(“fox”,A1) would return 17.

The following screenshots indicate the function arguments and explain the functions syntax.

jethro's picture

Excel Function of the Week - MOD

The MOD function is very useful in certain circumstances.

The function returns the integer remainder after a number has been divided by a divisor. For example if you divide 10 by 3, it goes in 3 times with one remaining.

image

jethro's picture

Excel Function of the Week - ROUND

The round function enables you to truncate values to the number of decimal places you desire. This could be in fractions of a whole value e.g. hundredths and thousandths of whole number, or as large numbers, e.g. rounding to the closest million or billion.

There are some very similar functions, ROUNDUP, ROUNDDOWN and MROUND. In addition there are some complimentary functions such as FLOOR and CEILING.

These functions all perform the same way with specific variations. Round follows the 4/5 round principle. That is if the number ends in 4 or lower it rounds down, and if it ends in 5 or higher it rounds up.

image