Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am creating an InputBox and I have 8 options a person may select from.
I would like my InputBox to display the choices in a list form, but I cannot figure out how to enter carriage returns. Right now the input box has one statement that looks like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I want it to look like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I have placed (Chr(13)) before each number in the list, but the VB editing box returns an error when I try to move off the coding line. Do you have any help for me on this one? I thank you in advance. Tofer |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
ans = InputBox("Enter the number of the type of work to be performed" &
vbNewLine & vbNewLine & _ "1. Excavation" & vbNewLine & _ "2. Excavation/Footings" & vbNewLine & _ "3. Sewer" & vbNewLine & _ "4. Sewer/Water" & vbNewLine & _ "5. Water" & vbNewLine & _ "6. Storm" & vbNewLine & _ "7. Irrigation" & vbNewLine & _ "8. Electric") -- HTH Bob Phillips (remove nothere from email address if mailing direct) "ToferKing" wrote in message ... I am creating an InputBox and I have 8 options a person may select from. I would like my InputBox to display the choices in a list form, but I cannot figure out how to enter carriage returns. Right now the input box has one statement that looks like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I want it to look like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I have placed (Chr(13)) before each number in the list, but the VB editing box returns an error when I try to move off the coding line. Do you have any help for me on this one? I thank you in advance. Tofer |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Note that this code
ans = InputBox("Enter the number of the type of work to be performed" & vbNewLine & vbNewLine & _ should all be on one line. -- HTH Bob Phillips (remove nothere from email address if mailing direct) "Bob Phillips" wrote in message ... ans = InputBox("Enter the number of the type of work to be performed" & vbNewLine & vbNewLine & _ "1. Excavation" & vbNewLine & _ "2. Excavation/Footings" & vbNewLine & _ "3. Sewer" & vbNewLine & _ "4. Sewer/Water" & vbNewLine & _ "5. Water" & vbNewLine & _ "6. Storm" & vbNewLine & _ "7. Irrigation" & vbNewLine & _ "8. Electric") -- HTH Bob Phillips (remove nothere from email address if mailing direct) "ToferKing" wrote in message ... I am creating an InputBox and I have 8 options a person may select from. I would like my InputBox to display the choices in a list form, but I cannot figure out how to enter carriage returns. Right now the input box has one statement that looks like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I want it to look like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I have placed (Chr(13)) before each number in the list, but the VB editing box returns an error when I try to move off the coding line. Do you have any help for me on this one? I thank you in advance. Tofer |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Bob, It works like a champ!
Thanks so much for your help. Tofer "Bob Phillips" wrote: ans = InputBox("Enter the number of the type of work to be performed" & vbNewLine & vbNewLine & _ "1. Excavation" & vbNewLine & _ "2. Excavation/Footings" & vbNewLine & _ "3. Sewer" & vbNewLine & _ "4. Sewer/Water" & vbNewLine & _ "5. Water" & vbNewLine & _ "6. Storm" & vbNewLine & _ "7. Irrigation" & vbNewLine & _ "8. Electric") -- HTH Bob Phillips (remove nothere from email address if mailing direct) "ToferKing" wrote in message ... I am creating an InputBox and I have 8 options a person may select from. I would like my InputBox to display the choices in a list form, but I cannot figure out how to enter carriage returns. Right now the input box has one statement that looks like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I want it to look like this: Enter the number of the type of work to be performed 1. Excavation 2. Excavation/Footings 3. Sewer 4. Sewer/Water 5. Water 6. Storm 7. Irrigation 8. Electric I have placed (Chr(13)) before each number in the list, but the VB editing box returns an error when I try to move off the coding line. Do you have any help for me on this one? I thank you in advance. Tofer |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Carriage returns - how to get rid of them (again) | Excel Discussion (Misc queries) | |||
Carriage returns in the formula bar? | Excel Worksheet Functions | |||
VBA: Concatenate with carriage returns | Excel Programming | |||
Carriage returns | Excel Discussion (Misc queries) | |||
Replacing Carriage Returns | Excel Programming |