Questions tagged [winmd]
39 questions
13
votes
3 answers
How to read a winmd (WinRT metadata file)?
A WinMD is a binary medadata file, that contains everything you need to learn about namespaces, types, classes, methods, parameters available in a native WinRT dll.
From Windows Runtime design:
The Windows Runtime is exposed using API metadata…

Ian Boyd
- 246,734
- 253
- 869
- 1,219
10
votes
1 answer
Force BuildManager to use another version of MSBuild
The following code tries to build a Solution programmatically, using BuildManager:
ProjectCollection pc = new ProjectCollection();
pc.DefaultToolsVersion = "12.0";
pc.Loggers.Add(fileLogger);
Dictionary globalProperty = new…

Maria Ines Parnisari
- 16,584
- 9
- 85
- 130
8
votes
2 answers
How to package a Windows Runtime component for distribution?
I have built a WinRT component (.winmd) for use by both JavaScript and XAML Windows Store apps. When including and referencing the loose .winmd file output in a JavaScript client, I see this build warning:
Microsoft.AppXPackage.Targets(808,9):…

Jesse Johnston
- 81
- 1
- 2
5
votes
3 answers
Given a .winmd file, where can we find the real implementation DLL?
I have question that given a .winmd file, where can we find the real implementation is? .winmd files just like a head file or dynamic library's .lib file, it doesn't contain any implementation, I curious that where is its implementation.
Thanks.

codewarrior
- 723
- 7
- 22
4
votes
1 answer
How would I call WebView2 and other modern winmd features in VBA
I would like to embed a modern WebView2 component (Edge Chromium Browser Control) inside an old-style VBA UserForm.
I surmise that I would need the following installed on the system:
Edge Chromium Broswer
Webview2 SDK
While I have the Edge…

Sam
- 2,745
- 3
- 20
- 42
4
votes
1 answer
UWP - binding Enum differences
I have come across a very interesting issue.
Suppose you have the following XAML page content in a UWP app:
And in the code-behind…

Martin Zikmund
- 38,440
- 7
- 70
- 91
3
votes
1 answer
How to get the Interface ID (IID, i.e. the GUID) of an interface when importing a WinRT winmd?
Short version
How to you get the interface identifier (IID) for an interface from a *.winmd file when using IMetadataImport?
e.g. Windows.Globalization.ICalendar: {CA30221D-86D9-40FB-A26B-D44EB7CF08EA}
Longer Version
A good example is…

Ian Boyd
- 246,734
- 253
- 869
- 1,219
3
votes
1 answer
Inheritance impossible in Windows Runtime Component?
Scenario:
I have 3 classes (A,B,C) in my Windows Runtime Component project.
class A{}
public sealed class B : A {}
public sealed class C : A {}
On compiling the above code, I get the following error:
"Inconsistent accessibility: base class 'A'…

Raunak Yadav
- 119
- 1
- 1
- 7
3
votes
0 answers
What is the relationship between winmd files in different directories
I'm working on Windows Store Apps development, and I found winmd files in different directories of Windows.
When developing a Windows Store App, the App is referencing Windows.winmd file under:
C:\Program Files (x86)\Windows…

caisx25
- 363
- 2
- 4
2
votes
1 answer
Referencing Windows SDK winmd files and VS Team Services build
I have created a C# .Net Standard library which references two Windows SDK libraries.
The references are
C:\Program Files (x86)\Windows…

tymtam
- 31,798
- 8
- 86
- 126
2
votes
0 answers
Embedding Winmd to a dll and using the dll in an C# app
How can I link a Winmd component (UWP 10) to a dll so that when I use the dll from an app.exe it can execute WinRT functions without showing TypeLoad Exception.
I could link the winmd component to a portable class library (Windows UWP) and the dll…
2
votes
1 answer
Universal Windows .NET Native and winmd component libraries
How .NET Native toolchain treat managed .winmd component libraries in detail?
I know that .NET Native merge all managed code from DLLs into one executable and remove unused code when compiling it into native.
But what algorithm is used for .winmd…

Evgeny Ipatov
- 101
- 1
- 5
2
votes
1 answer
What's the point in using .winmd library if I still need the .dll and .pri file?
I wanted to use the winfbsdk (see here) which is an SDK for using Facebook inside UWP (Universal Windows Apps (Windows 10)). But it seems that the .winmd file that is built is not enough to be able to use this library. I can do one of the…

Whyser
- 2,187
- 2
- 20
- 40
2
votes
1 answer
TypeLoadException in Windows store app
I am using a Winmd (Windows Runtime Component) in a windows store app. When I try to instantiate a type that is defined the in the winmd, I get the following exception:
System.TypeLoadException was unhandled by user code
HResult=-2146233054
…

user3634197
- 21
- 3
1
vote
1 answer
How to export data, functions, classes from C++/WinRT library
Usually we are using dllexport/dllimport method for c++ libraries. Then a test application can use the dll implicitly/explicitly for accessing the dll functions.
Also we can make use of .winmd files in the c++/winRT to access the classes, functions…

Hari
- 19
- 4