- リリース ノート
- 基本情報
- チュートリアル
- オートメーション プロジェクト
- オートメーションの作成
このチュートリアルでは、スプレッドシートのヘッダー行のセルに 1 つの書式を適用し、同じスプレッドシートの最初の列のセルに別の書式を適用する、単純なオートメーションを作成します。各書式をプロジェクトのプロジェクト ノートブックのセルに適用し、2 つの [範囲をコピー] アクティビティを使用して、各セルの書式をスプレッドシートの目的の行と列にコピーします。
-
手順 1: プロジェクトを設定し、必要なファイルを取得する
- Create a new blank project using the default settings.
- このチュートリアルでは、このページ下部にあるボタンを使用して、オートメーション プロジェクトを含むアーカイブをダウンロードして展開し、DoubleUI.xlsx ファイルをプロジェクト フォルダーにコピーします。
-
手順 2: 希望の書式設定をプロジェクト ノートブックの 2 つのセルに適用する
-
StudioX のリボンの [プロジェクト ノートブック] をクリックします。ファイル Project_Notebook.xlsx が開きます。
-
第 1 列用の次の書式設定をプロジェクト ノートブックの Scratchpad シートのセル A1 に適用します。
- 塗りつぶしの色: ライト ブルー
- 小数点以下 2 桁の数値形式
-
ヘッダー行用の次の書式設定をプロジェクト ノートブックの Scratchpad シートのセル B1 に適用します。
- 塗りつぶしの色: ライト グレー
- フォント スタイル: 太字
-
プロジェクト ノートブックを保存して閉じます。
-
-
手順 3: DoubleUI.xlsx をプロジェクトに追加し、書式設定を列と行にコピーする
書式設定は、プロジェクト ノートブック ファイルの Scratchpad シートの 2 つのセルから DoubleUI ファイルのヘッダー行と第 1 列にコピーされます。
-
Click Add activity
in the Designer panel, and then find the Use Excel File activity in the search box at the top of the screen and select it. A Use Excel File activity is added to the Designer panel. -
アクティビティで次の操作を行います。
-
Click Browse
next to the Excel file field, and then browse to and select the file DoubleUI.xlsx -
[参照名] フィールドに「
DoubleUI」と入力します。これで、このオートメーションでは名前を DoubleUI としたファイル DoubleUI.xlsx を操作対象として指定したことになります。
-
-
In the Use Excel File activity, click Add activity
, then find the Copy Range activity in the search box at the top of the screen and double-click it. The activity is added inside the Use Excel File activity. -
[範囲をコピー] アクティビティで、次の操作を行います。
-
Click Plus
on the right side of the Source range field, and then select Project Notebook (Notes) > Indicate in Excel. -
In the Excel file, select cell A1 in the Scratchpadsheet, and then click Confirm in the UiPath tab in the Excel ribbon.
これで、プロジェクト ノートブックの Scratchpad シートの A1 セルをコピーするように指定したことになります。
-
Click Plus
on the right side of the Destination range field, and then select DoubleUI > Indicate in Excel. -
Excel ファイルで、列 A 全体を選択し、Excel のリボンの [UiPath] タブで [Confirm (確定)] をクリックします。
これで、DoubleUI ファイルの第 1 列にデータを貼り付けるように指定したことになります。
-
[コピーする内容] ドロップダウン メニューから [形式] を選択し、セルの書式設定のみがコピーされるよう指定します。
-
-
2 つ目の [範囲をコピー] アクティビティを既存の当該アクティビティのすぐ下に追加します。
-
2 つ目の [範囲をコピー] アクティビティで、次の操作を行います。
-
Click Plus
on the right side of the Source range field, and then select Project Notebook (Notes) > Indicate in Excel. -
In the Excel file, select cell B1 in the Scratchpadsheet, and then click Confirm in the UiPath tab in the Excel ribbon.
これで、プロジェクト ノートブックの Scratchpad シートの B1 セルをコピーするように指定したことになります。
-
Click Plus
on the right side of the Destination range field, and then select DoubleUI > Indicate in Excel. -
Excel ファイルで、ヘッダー行 (範囲 A1:D1) を選択し、Excel のリボンの [UiPath] タブで [Confirm (確定)] をクリックします。
これで、DoubleUI ファイルの範囲 A1:D1 にデータを貼り付けるように指定したことになります。
-
[コピーする内容] ドロップダウン メニューから [形式] を選択し、セルの書式設定のみがコピーされるよう指定します。
-
-
2 つの [範囲をコピー] アクティビティをより簡単に識別するには、各アクティビティの上部のバーで名前を編集します。たとえば、最初のアクティビティには
Copy Format Column、2 番目のアクティビティにはCopy Format Rowを使用します。 -
StudioX のリボンで [保存] をクリックしてオートメーションを保存し、[実行] をクリックしてオートメーションを実行します。
-