LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,942
Default input box to allow range OR strings

hi
tricky problem. you could use a msgbox to get a yes/no responce. something
like this...
Dim rngto As Range
Dim stgto As String
If MsgBox("Do you wish to enter the mail addresses?" & vbNewLine & _
"Click yes?" & vbNewLine & _
"Or to select email addresses by range" & vbNewLine & _
"Click No") = vbNo Then
Set rngto = Application.InputBox("Select range with addressees emails
for the 'TO:' field")
Else
Set stgto = Application.InputBox("Enter emails here separated by
semicolon.")
End If

lot of extra code but it would solve the delima.

Regards
FSt1

"Greg" wrote:

Hi,

I'd like the user to either select the range of cell with email addresses or
type it OR be able to type them in directly. I can only think of one either
declare a range or string. for example, when declaring a range my code looks
like following:


Set rngTo = Application.InputBox("Select range with addressees emails
for the 'TO:' field" & _
vbNewLine & "or enter emails here separated by semicolon", "Select",
Type:=8)

This won't allow a string to be typed in...
Can anything suggest the workaround?
Thank you,
--
______
Regards,
Greg

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
strings in a range Peter Morris Excel Worksheet Functions 4 September 5th 06 01:00 AM
strings in a range Peter Morris Excel Programming 4 September 5th 06 01:00 AM
Only allow specified strings in a range Slick Willie Excel Programming 2 September 15th 04 12:27 PM
Input Boxes & getting tied up in knots with strings! RogerNZ Excel Programming 3 July 7th 04 10:42 AM
CODE to select range based on User Input or Value of Input Field Sandi Gauthier Excel Programming 4 December 8th 03 03:22 PM


All times are GMT +1. The time now is 02:24 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"