Message 1 of 3
Select default value for InitializeUserInput when user presses Enter
Not applicable
04-24-2009
05:57 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I'm using the following code to set some options and I would like to know how to select a default value when the user presses enter as many other AutoCAD commands allow.
ThisDrawing.Utility.InitializeUserInput 1, "A S"
TempVal = ThisDrawing.Utility.GetKeyword("Current Area Type [Acre/Sf] <" & AreaString & ">: ")
If Err.Number = -2147352567 Then Exit Sub
Select Case UCase(TempVal)
Case "A"
CurrentAreaType = AreaType.acre
Case "L"
CurrentAreaType = AreaType.sf
End Select
I tried appending the the carriage return character on to the string like:
"A S" & chr(13)
but this did not work. Thanks for any suggestions.
ThisDrawing.Utility.InitializeUserInput 1, "A S"
TempVal = ThisDrawing.Utility.GetKeyword("Current Area Type [Acre/Sf] <" & AreaString & ">: ")
If Err.Number = -2147352567 Then Exit Sub
Select Case UCase(TempVal)
Case "A"
CurrentAreaType = AreaType.acre
Case "L"
CurrentAreaType = AreaType.sf
End Select
I tried appending the the carriage return character on to the string like:
"A S" & chr(13)
but this did not work. Thanks for any suggestions.