1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

初投稿

Last updated at Posted at 2019-07-07

#目的
当面は自身の知識のインターネット上での公開のためにこのブログを使うかな。。。

#試し書き

test01.xlsm
    Public Sub MakeApplicationHolidayWork()
    Dim i As Integer
    Dim fPath As String
    Dim fName As String
    Dim area As Range
    Dim temp As Range
    
    Set area = Worksheets("休出予定社員一覧").Range("B3").CurrentRegion
    Set area = area.Offset(1).Resize(area.Rows.Count - 1)
   
    'シートをコピーして新規ブックを作る
    

        'ブックの保存
    For Each temp In area.Rows
        fPath = ThisWorkbook.Path
        fName = ThisWorkbook.Path & "休日出勤届" & "_" & temp.Cells(1, 2).Value
        '週間予定表シートを最終シートにコピーする
        Worksheets("休日出勤届").Copy
        Workbooks(Workbooks.Count).Close SaveChanges:=True, Filename:=fName
    Next
            

End Sub

#気になっている事
後から記事の修正ってどうやるんだろう、、、

1
0
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?