VBA help

ian0886

New Member
Joined
Dec 10, 2016
Messages
42
Hi All,

I'm trying to write a formula such that, if the first column is a B, i'd multiple -1 to the counter amount. if the first column is S i'd multiple -1 to the amount column. i'd think a if.. then .. vba should work but i can't figure out whats next. could anyone please help?

B/SAmountCurrencyPriceCounter Amount
B30 000.00AUD0.7450122 350.30
B1 000.00AUD0.74451744.51
S500AUD0.74421372.1
B1 000.00AUD0.74411744.11
B1 000 000.00AUD0.74375743 750.00
S1 000 000.00AUD0.74375743 750.00
S1 000 000.00AUD0.74374743 740.00
B1 000 000.00AUD0.74374743 740.00
B1 000 000.00AUD0.74375743 750.00

<colgroup><col><col><col span="2"><col></colgroup><tbody>
</tbody>
 

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.

mole999

Well-known Member
Joined
Oct 23, 2004
Messages
10,524
Office Version
  1. 2019
  2. 2016
  3. 2013
Platform
  1. Windows
show your code between code tags
 
Upvote 0

Forum statistics

Threads
1,191,170
Messages
5,985,066
Members
439,938
Latest member
MAlhash

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top