Add forward slashes to clickable options in custom command
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello all,
I'm creating a new command for users at my company to insert blocks by. I've got the command working fine for now, but I'm using prompts such as
What size? <5/16" 3/8" 1/2" 5/8">:
I would like to change those static options over to clickable ones by changing the angle brackets to square brackets and separating the options with forward slashes, which is where I run into some trouble. I've tried escaping the forward slashes (\/), doubling them (//) and using concatenation and character codes ((strcat "5" (chr 47) "16\"")), all with no luck. I've even tried using unicode char 824 (the long solidus) and a space or unicode char 8260 (the actual fraction slash) with either strcat or just directly in the prompt, but that only returns the numerator, e.g. "5" or "1", which won't work because several of the options have the same numerator. I know I can't use the initget and getkword functions, because you can't have forward slashes in the keywords.
Does anyone know of a way to push forward slashes through to the command line without them being intercepted and turned into dividers for the clickable options? Or perhaps there's a way to return a different value when clicked than is displayed? I would be fine with the command returning something like "A" "B" or "C", but I'm unaware of how to do that. The only resource I've been able to locate on this function was a remarkably short blog post about it whose URL is now buried in my history.
Thanks.