vba insert where day =

Shutz

New Member
Joined
Aug 23, 2019
Messages
8
hi, this is the 2nd part of my auto banking project

Sheet 1

[TABLE="width: 500"]
<tbody>[TR]
[TD]Column A (Day)
[/TD]
[TD]Column B (Date)
[/TD]
[TD]Column C (Amount)
[/TD]
[/TR]
[TR]
[TD]Monday
[/TD]
[TD]2/9/19
[/TD]
[TD]0
[/TD]
[/TR]
[TR]
[TD]Tuesday
[/TD]
[TD]3/9/19
[/TD]
[TD]0
[/TD]
[/TR]
[TR]
[TD]Wednesday
[/TD]
[TD]4/9/19
[/TD]
[TD]0
[/TD]
[/TR]
[TR]
[TD]Thursday
[/TD]
[TD]5/9/19
[/TD]
[TD]0
[/TD]
[/TR]
[TR]
[TD]Friday
[/TD]
[TD]6/9/19
[/TD]
[TD]0
[/TD]
[/TR]
</tbody>[/TABLE]

Sheet 2
[TABLE="width: 500"]
<tbody>[TR]
[TD]Column A (Date of each month)
[/TD]
[TD]Column B (bank)
[/TD]
[TD]Column C (amount
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]mine
[/TD]
[TD]100
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]mine
[/TD]
[TD]105
[/TD]
[/TR]
[TR]
[TD]3
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]4
[/TD]
[TD]Mine
[/TD]
[TD]101
[/TD]
[/TR]
[TR]
[TD]5
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

sheet 3
[TABLE="width: 500"]
<tbody>[TR]
[TD]Column A (day of week)
[/TD]
[TD]Column B (Bank)
[/TD]
[TD]Column C (amount)
[/TD]
[/TR]
[TR]
[TD]Monday
[/TD]
[TD]mine
[/TD]
[TD]100
[/TD]
[/TR]
[TR]
[TD]Tuesday
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Wednesday
[/TD]
[TD]Mine
[/TD]
[TD]30
[/TD]
[/TR]
[TR]
[TD]Thursday
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]


i wuld like to have vba populate sheet 1 column c with the data from sheet 2 column c

i would like to cycle through this for date +1 - 180 days

so on the 2nd of each month it would insert 105 into column c. also there is another table that has weekly payments. so every wednesday it would have 30. so it needs to calculate sheet 1 column c with sheet 2 column c and insert it.

if worksheets(sheet1.columnA)=(current Date + 1) = 4th then
worksheets(sheet1.columnc).value = worksheets(sheet2.columnc) + worksheets(sheet1.columnc)

obviously that isnt how to write it otherwise i wouldnt be here.

thank you
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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
Back
Top