| description | Learn more about: importidl | |
|---|---|---|
| title | importidl (C++ COM Attribute) | |
| ms.date | 10/02/2018 | |
| f1_keywords |
|
|
| helpviewer_keywords |
|
|
| ms.assetid | 4b0a4b55-6c57-4e6e-bc7b-a12cc8063941 |
Inserts the specified .idl file into the generated .idl file.
[ importidl(idl_file) ];idl_file
Identifies the name of the .idl file that you want to merge with the .idl file that will be generated for your application.
The importidl C++ attribute places the section outside of the library block (in idl_file) into your program's generated .idl file and the library section (in idl_file) into the library section of your program's generated .idl file.
You may want to use importidl, for example, if you want to use a hand-coded .idl file with your generated .idl file.
// cpp_attr_ref_importidl.cpp
// compile with: /LD
[module(name="MyLib")];
[importidl("import.idl")];| Attribute context | Value |
|---|---|
| Applies to | Anywhere |
| Repeatable | No |
| Required attributes | None |
| Invalid attributes | None |
For more information, see Attribute Contexts.
Compiler Attributes
Stand-Alone Attributes
import
importlib
include
includelib