2024-02-01から1ヶ月間の記事一覧

【bat】リストを使用してファイルを移動

BAT

コードは以下の通り。 @echo off set "sourceFolder=C:\元のフォルダのパス" set "destinationList=C:\移動先のファイル・パスのリスト.txt" if exist "%destinationList%" ( for %%a in ("%sourceFolder%\*.*") do ( set "fileName=%%~nxa" set "destinatio…

【VBA】複数のHTMLファイルを一括でExcelに変換

VBA

コードは以下の通り。 Sub ConvertHTMLtoExcel() Dim FolderPath As String Dim HTMLFile As String Dim ExcelApp As Object Dim wb As Object ' 変換元のHTMLファイルが格納されているフォルダのパスを指定します FolderPath = "C:\Your\Folder\Path\" ' パ…