これは私のコードです:VBA - 入力ボックス - ユーザーフォーム
qty = InputBox("Please enter the quantity to be added.", "Add Quantity")
Cells(row, 2) = qty
Description = InputBox("Please enter a description.", "Enter Description")
Cells(row, 3) = Description
Unitp = InputBox("Please enter a unit price.", "Enter UnitPrice")
Cells(row, 4) = Unitp
Amount = InputBox("Please enter an amount.", "Enter Amount")
Cells(row, 5) = Amount
Qty
& Unitp
はExcelで正しく表示されつつあります。しかし、Description
入力ボックスに文字を入力すると、エラーが発生します。しかし、もし私がno
と入力すると。それは通過しますが、FALSE
とExcelセルに表示されます。これは、両方ともの場合です。Descripton
& Amount
です。
誰かが助けることができますか?
'Description 'はどのように定義されていますか? – GSerg
「Dim Description As Bool」と書いてありますか? – iBug