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: 11
Default Type Mismatch Error when using InputBox Method

I'm getting a Type Mismatch error and the macro stops at Set myDir (see ERROR
below). Since I'm using a string of numbers, letters and symbols, I

thought I would select the type as 2 for text. Please help!

Dim myCell, myRange, myDir, myDateTime
Set myRange = Application.InputBox(prompt:="Enter a Range", Type:=8)
ERROR Set myDir = Application.InputBox(prompt:="Enter File Location",
Default:="U:\CC EB 500 Reports\mmddyy\", Type:=2)
Set myDateTime = Application.InputBox(prompt:="Enter Date and Time",
Default:="mm/dd/yy hh:mm am", Type:=2)
Windows("PERSONAL.XLS").Visible = True
Workbooks("Personal.xls").Activate
Sheets("Sheet1").Select
For Each myCell In myRange
Workbooks.Open Filename:=myFile.Text & myCell.Value

 
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
Help: Compile error: type mismatch: array or user defined type expected lvcha.gouqizi Excel Programming 1 October 31st 05 08:20 PM
Error 424 with inputbox method after OK Herman[_4_] Excel Programming 1 September 14th 04 11:12 PM
Inputbox method using type:=8 - How to Cancel? Joe 90 Excel Programming 0 July 10th 03 12:24 AM
Inputbox method using type:=8 - How to Cancel? Harlan Grove[_5_] Excel Programming 1 July 9th 03 12:06 AM
Inputbox method using type:=8 - How to Cancel? Jim Cone Excel Programming 0 July 8th 03 06:15 PM


All times are GMT +1. The time now is 12:17 AM.

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

About Us

"It's about Microsoft Excel"