Results 1 to 3 of 3

Thread: Help needed Run-Time Error 13: Type missmach

  1. #1

    Help needed Run-Time Error 13: Type missmach



    Register for a FREE account, and/
    or Log in to avoid these ads!

    Hi I`m useing Excel 2010 I have a macro which gives me Run-Time Error 13: Type missmach every time I try to lounch it. Can anybody help me? An error code line is folowing:


    Private Sub ProcessRace(nIndexStart As Long, nIndexEnd As Long, nCols As Long, bIsCreateCSVReport As Boolean, asRaces() As String, sFileName As String)

    oReport.RaceAnalysis nIndexStart, nIndexEnd, nCols, bIsCreateCSVReport, asRaces()

    End Sub



    Here is also link to screenshot of error line
    http://www.bildites.lv/images/zt9cd51b8wh69san7qo.jpg

    Thanks for in advance =)

  2. #2
    I think we need to see the other procedures, especially oReport.RaceAnalysis

  3. #3
    Administrator Ken Puls's Avatar
    Join Date
    Mar 2011
    Location
    Nanaimo, BC, Canada
    Posts
    2,064
    Articles
    79
    Blog Entries
    14
    I agree with Bob, but it may also be helpful to see the routine that calls ProcessRace. I wonder if you were to specially typecast the variables you're feeding it if the error would happen there. I.e. nIndexStart = CLng(myinput) would make sure you've actually passed it Long data and not an Integer or something.
    Ken Puls, FCPA, FCMA, MS MVP (Excel)

    Master your data with Power Query: Purchase your copy of my book M is for Data Monkey today!

    Main Site: http://www.excelguru.ca -||- Blog: http://www.excelguru.ca/blog -||- Forums: http://www.excelguru.ca/forums
    Check out the Excelguru Facebook Fan Page -||- Follow Me on Twitter

    If you've been given VBA code (a macro) for your solution, but don't know where to put it, CLICK HERE.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •