Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. COM
  4. MIDL Compiler problem

MIDL Compiler problem

Scheduled Pinned Locked Moved COM
helpc++comdebuggingquestion
4 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    msh
    wrote on last edited by
    #1

    Hi all, I have a stupid problem but I do not know if it can solved some way. While trying to compile a ATL/COM component, I want the MIDL compiler include some other .idl files stored in a path like C:\Program Files\DanLoad 6000\Include. So I put the project settings for MIDL compiler with the /I option (/I "C:\Program Files\Danload 6000\Include"). When I try to build the project, I get the follwoing error. It look as if the MIDL compiler does not understand blanks in the path for include files. Anyone can help? Thank you in advance. --------------------Configuration: DldDanload6000 - Win32 Debug-------------------- Creating Type Library... Microsoft (R) MIDL Compiler Version 5.01.0164 Copyright (c) Microsoft Corp 1991-1997. All rights reserved. Processing C:\temp\DldDanload6000\DldDanload6000.idl Danload fatal error C1083: Cannot open source file: 'Files\Danload': No such file or directory 6000 fatal error C1083: Cannot open source file: '6000': No such file or directory Include fatal error C1083: Cannot open source file: '6000\Include': No such file or directory DldDanload6000.idl midl : command line error MIDL1003 : error returned by the C preprocessor (2) Error executing midl.exe. DldDanload6000.dll - 4 error(s), 0 warning(s) _________________________________________________________________________

    V G 2 Replies Last reply
    0
    • M msh

      Hi all, I have a stupid problem but I do not know if it can solved some way. While trying to compile a ATL/COM component, I want the MIDL compiler include some other .idl files stored in a path like C:\Program Files\DanLoad 6000\Include. So I put the project settings for MIDL compiler with the /I option (/I "C:\Program Files\Danload 6000\Include"). When I try to build the project, I get the follwoing error. It look as if the MIDL compiler does not understand blanks in the path for include files. Anyone can help? Thank you in advance. --------------------Configuration: DldDanload6000 - Win32 Debug-------------------- Creating Type Library... Microsoft (R) MIDL Compiler Version 5.01.0164 Copyright (c) Microsoft Corp 1991-1997. All rights reserved. Processing C:\temp\DldDanload6000\DldDanload6000.idl Danload fatal error C1083: Cannot open source file: 'Files\Danload': No such file or directory 6000 fatal error C1083: Cannot open source file: '6000': No such file or directory Include fatal error C1083: Cannot open source file: '6000\Include': No such file or directory DldDanload6000.idl midl : command line error MIDL1003 : error returned by the C preprocessor (2) Error executing midl.exe. DldDanload6000.dll - 4 error(s), 0 warning(s) _________________________________________________________________________

      V Offline
      V Offline
      valikac
      wrote on last edited by
      #2

      Why do you want to include the .idl file? Do you need the interface declarations of other some other coclasses? One solution is to include the .c and .h files. Kuphryn

      1 Reply Last reply
      0
      • M msh

        Hi all, I have a stupid problem but I do not know if it can solved some way. While trying to compile a ATL/COM component, I want the MIDL compiler include some other .idl files stored in a path like C:\Program Files\DanLoad 6000\Include. So I put the project settings for MIDL compiler with the /I option (/I "C:\Program Files\Danload 6000\Include"). When I try to build the project, I get the follwoing error. It look as if the MIDL compiler does not understand blanks in the path for include files. Anyone can help? Thank you in advance. --------------------Configuration: DldDanload6000 - Win32 Debug-------------------- Creating Type Library... Microsoft (R) MIDL Compiler Version 5.01.0164 Copyright (c) Microsoft Corp 1991-1997. All rights reserved. Processing C:\temp\DldDanload6000\DldDanload6000.idl Danload fatal error C1083: Cannot open source file: 'Files\Danload': No such file or directory 6000 fatal error C1083: Cannot open source file: '6000': No such file or directory Include fatal error C1083: Cannot open source file: '6000\Include': No such file or directory DldDanload6000.idl midl : command line error MIDL1003 : error returned by the C preprocessor (2) Error executing midl.exe. DldDanload6000.dll - 4 error(s), 0 warning(s) _________________________________________________________________________

        G Offline
        G Offline
        geo_m
        wrote on last edited by
        #3

        Difficult to say - but just a wild guess - if you put the /I "C:\Program Files\Danload 6000\Include" option, it will receive the path as: C:\Program Files\Danload 6000\Include from the command line. And when it is just passed to another procedure or where, it might be misunderstood. I would try: /I """C:\Program Files\Danload 6000\Include""" or something similar, just to achieve the effect, that the MIDL will receive "C:\Program Files\Danload 6000\Include" instead of mentioned C:\Program Files\Danload 6000\Include Maybe this helps...

        J 1 Reply Last reply
        0
        • G geo_m

          Difficult to say - but just a wild guess - if you put the /I "C:\Program Files\Danload 6000\Include" option, it will receive the path as: C:\Program Files\Danload 6000\Include from the command line. And when it is just passed to another procedure or where, it might be misunderstood. I would try: /I """C:\Program Files\Danload 6000\Include""" or something similar, just to achieve the effect, that the MIDL will receive "C:\Program Files\Danload 6000\Include" instead of mentioned C:\Program Files\Danload 6000\Include Maybe this helps...

          J Offline
          J Offline
          J Dunlap
          wrote on last edited by
          #4

          I'm interested to know if this one works, because I'm having the same problem passing a response file name to the csc.exe compiler.

          "Do unto others as you would have them do unto you." - Jesus
          "An eye for an eye only makes the whole world blind." - Mahatma Gandhi

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups