**メモ: ** Type が 8 の場合、Set ステートメントを使用して結果を Range オブジェクトに割り当てる必要があります。次に例を示します。 Set myRange = Application.InputBox(prompt := "Sample", type := 8) 次の例では、ユーザーにコピーの数を入力するよう要求するメッセージを表示し、アクティブ ワークシートをその数だけ印刷します。メソッドが数値を要求するよう型で指定することに注目してください。 Sub PrintActiveSheet() Dim TotalCopies As Long, NumCopies As Long Dim sPrompt As String, sTitle As String sPrompt = "How many copies do you want?" sTitle = "Pri
![Excel 2007 Application オブジェクト開発者向けガイド](https://cdn-ak-scissors.b.st-hatena.com/image/square/d6e4cb632c7025e9f5e05fd314fbf6dcd6144e8d/height=288;version=1;width=512/https%3A%2F%2Flearn.microsoft.com%2Fen-us%2Fmedia%2Fopen-graph-image.png)