Copying Additional Data into Separate Sheets

stinkingcedar

New Member
Joined
May 2, 2016
Messages
23
Hey guys,

First things first here is my code:

Code:
Option Explicit


Public Sub CopyDataLoad()


Dim WSCount As Long, StartCellRow As Long, i As Long
Dim sht As Worksheet
Dim region As String






WSCount = Worksheets.Count
Application.ScreenUpdating = False


For i = 3 To WSCount
    
    region = Sheets(i).Range("D1").Text
    Set sht = Sheets(i)
    Sheets(i).UsedRange
    StartCellRow = sht.Cells.Find("Please DO NOT TOUCH formula driven:", LookAt:=xlWhole, LookIn:=xlValues, SearchOrder:=xlByRows, SearchDirection:=xlNext).Row + 1
    sht.Range(sht.Cells(StartCellRow, 6), sht.Cells(StartCellRow + 29, 27)).Copy
    
    
    Select Case region


        Case Is = "A"
        Sheets("Sheet1").Range("F" & Rows.Count).End(xlUp).Offset(1).PasteSpecial (xlPasteValues)
        Case Else
        Sheets("Sheet2").Range("F" & Rows.Count).End(xlUp).Offset(1).PasteSpecial (xlPasteValues)
    
    End Select


Next i


End Sub

So just to give you a quick background...

I am attempting to write a code that cycles through every sheet of a workbook(except the first two) copies two specific ranges from each sheet, and then pastes that into the appropriate sheet (1 or 2).

I am able to get all the larger ranges with the data to copy and paste over(which is all I am doing with the code above), but I can not seem to figure out how to get the text from cell E5 on every sheet to copy over to the new sheet. This cell's text needs to be copied over in the same row as the starting point for the larger range, but offset 5 columns to the left to column A.

I know this is a rather confusing question, so if any clarifications are needed in order to answer please don't hesitate to ask.

Thank you!
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)

Forum statistics

Threads
1,223,630
Messages
6,173,454
Members
452,514
Latest member
cjkelly15

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