Repeat File Name for Each Row

C_0k

New Member
Joined
Nov 24, 2021
Messages
4
Office Version
  1. 365
Platform
  1. Windows
Hello,

I have combined different workbooks in one excel worksheet with Kuttols Plus.

The worksheet information is mentioned just before each range. A blank raw was also inserted in front of each range.

Is there any quick way to have the workbook name (highlighted in yellow) in front of each item as there's around 100 different range in the worksheet? Don't want to do this manually.

_Combined results(2021-11-24 175547).xlsx
ABCDEFGH
3582Workbooks:Steel substructure Hook MW205.R.221-002_Assembly.xlsx Worksheets:PARTS LIST Range:$A$1:$F$13
3583ITEMQTYPART NUMBERDESCRIPTIONWIDTH [mm]LENGTH [mm]
358411Steel substructure CR Hook MW205.R.221-002Steel substructure for hooks Case 2557.60
358532Female Hook C2.tubeAluminium Profile SP0317220.00
358652DIN 916 - M5 x 16Hexagon Socket Set Screw
358762DIN 916 - M16 x 20Hexagon Socket Set Screw
358821Male Hook C2.tubeAluminium Profile SP0735156.50
3589714DIN 125 - A 13Washer DIN 125-A - A4-70
359094DIN 933 - M12 x 40Hex-Head Bolt DIN 933 - A4-70
359186DIN 934 - M12Hex Nut DIN 934 - A4-70
3592102DIN 933 - M12 x 50Hex-Head Bolt DIN 933 - A4-70
3593112DIN 933 - M12 x 30Hex-Head Bolt DIN 933 - A4-70
3594121Male Hook C2.profileAluminium Profile SP0735156.50
3595131ISO 8752 - 6 x 80 ASpring-type straight pins - Slotted, heavy duty
3596
3597Workbooks:Steel substructure Hook MW205.R.221-002_Parts list.xlsx Worksheets:PARTS LIST Range:$A$1:$H$5
3598ITEMQTYPART NUMBERDESCRIPTIONWIDTH [mm]LENGTH [mm]MATERIAL
359911Steel tube MW205.R.221-002Steel SHS 80x3mm557.60Steel S275
360022Steel plate Hook L C2 MW205.R.221-002Steel plate thk.10mmSteel S275
360131Steel plate Lh C2 MW205.R.221-002Steel plate thk.10mm100.00220.00Steel S275
360241Steel plate Rh C2 MW205.R.221-002Steel plate thk.10mm100.00220.00Steel S275
3603
3604Workbooks:Steel substructure Hook MW205.R.225-002_Assembly.xlsx Worksheets:PARTS LIST Range:$A$1:$F$13
3605ITEMQTYPART NUMBERDESCRIPTIONWIDTH [mm]LENGTH [mm]
360611Steel substructure CR Hook MW205.R.225-002Steel substructure for hooks Case 2563.50
360732Female Hook C2.tubeAluminium Profile SP0317220.00
360852DIN 916 - M5 x 16Hexagon Socket Set Screw
360962DIN 916 - M16 x 20Hexagon Socket Set Screw
361021Male Hook C2.tubeAluminium Profile SP0735156.50
3611714DIN 125 - A 13Washer DIN 125-A - A4-70
361294DIN 933 - M12 x 40Hex-Head Bolt DIN 933 - A4-70
361386DIN 934 - M12Hex Nut DIN 934 - A4-70
3614102DIN 933 - M12 x 50Hex-Head Bolt DIN 933 - A4-70
3615112DIN 933 - M12 x 30Hex-Head Bolt DIN 933 - A4-70
3616121Male Hook C2.profileAluminium Profile SP0735156.50
3617131ISO 8752 - 6 x 80 ASpring-type straight pins - Slotted, heavy duty
3618
3619Workbooks:Steel substructure Hook MW205.R.225-002_Parts list.xlsx Worksheets:PARTS LIST Range:$A$1:$H$5
3620ITEMQTYPART NUMBERDESCRIPTIONWIDTH [mm]LENGTH [mm]MATERIAL
362111Steel tube MW205.R.225-002Steel SHS 80x3mm563.50Steel S275
362222Steel plate Hook L C2 MW205.R.225-002Steel plate thk.10mmSteel S275
362331Steel plate Lh C2 MW205.R.225-002Steel plate thk.10mm100.00220.00Steel S275
362441Steel plate Rh C2 MW205.R.225-002Steel plate thk.10mm100.00220.00Steel S275
PARTS LIST


Thanks in davance !
 

Attachments

  • 1637765570977.png
    1637765570977.png
    45.1 KB · Views: 18

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
Should this start from row 2?
 
Upvote 0
Ok, how about
VBA Code:
Sub C_0k()
   Dim Rng As Range
  
   For Each Rng In Range("C2", Range("C" & Rows.Count).End(xlUp)).SpecialCells(xlConstants).Areas
      Rng.Offset(, -2).Value = Rng.Offset(-1, -1).Resize(1).Value
   Next Rng
End Sub
 
Last edited:
Upvote 0
Solution
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,550
Messages
6,179,463
Members
452,915
Latest member
hannnahheileen

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