En savoir plus sur Microsoft .NET
L’interface vers .NET permet d’introduire des assemblys .NET dans l’environnement MATLAB, de construire des objets à partir des classes contenues dans ces assemblys et d’appeler des méthodes sur ces objets.
MATLAB supporte le chargement de ces assemblies .NET :
.NET y compris .NET Core (Microsoft® Windows®, macOS et Linux®)
.NET Framework (Windows uniquement)
Pour de plus amples informations, veuillez consulter System Requirements for Using MATLAB Interface to .NET. Pour plus d’informations sur les versions .NET compatibles avec MATLAB, consultez MATLAB Interfaces to Other Languages (Interfaces MATLAB vers d’autres langages).
Pour déterminer si votre système dispose d’une version supportée, utilisez la fonction NET.isNETSupported
.
Fonctions
NET.addAssembly | Make .NET assembly visible to MATLAB |
NET.isNETSupported | Check for supported version of Microsoft .NET |
NET.interfaceView | Explicit interface view of .NET object (depuis R2023b) |
NET | Summary of functions in MATLAB .NET interface |
enableNETfromNetworkDrive | (To be removed) Enable access to .NET commands from network drive |
Classes
NET.Assembly | Members of .NET assembly |
Objets
NET.NetException | Capture error information for .NET exception |
Rubriques
- System Requirements for Using MATLAB Interface to .NET
Using a supported version of .NET.
- Access a Simple .NET Class
This example shows how to access .NET functionality already installed on your system.
- Work with Microsoft Excel Spreadsheets Using .NET
This example for Microsoft .NET Framework uses the
Microsoft.Office.Interop.Excel.ApplicationClass
class to create a spreadsheet, copy MATLAB data to it, and then close it. - Work with Microsoft Word Documents Using .NET
This example for Microsoft .NET Framework uses the
Microsoft.Office.Interop.Word.ApplicationClass
class to create a Word document. - Build a .NET Application for MATLAB Examples
Basic information for building the .NET examples included with MATLAB.
- Save and Load .NET Objects in MAT Files
When you save and load .NET objects in MAT files, MATLAB uses
System.Runtime.Serialization.DataContractSerializer
to perform the serialization and deserialization. - Simplify .NET Class Names
Use the MATLAB
import
function to refer to .NET class names. - Use import in MATLAB Functions
Guidelines for using the
NET.addAssembly
andimport
functions. - Use .NET Nested Classes
Using reflection to instantiate a nested class.
- Handle .NET Exceptions
MATLAB catches exceptions thrown by .NET and converts them into a
NET.NetException
object. - Assembly Is a Library of .NET Classes
An assembly is a collection of types and resources built to work together and form a logical unit of functionality in .NET applications.
- Use .NET from MATLAB
How you can benefit from using .NET from MATLAB.
- Create .NET Objects
How to create a .NET object.
- .NET Terminology
Understanding namespaces and reference and value types.
Résolution des problèmes
Troubleshooting Security Policy Settings from Network Drives
For MATLAB releases R2012b or earlier, call the
enableNETfromNetworkDrive
function to create a
MATLAB security policy entry.
.NET features not supported in MATLAB.
Limitations to Support of .NET Arrays
.NET features not supported in MATLAB.
Limitations to Support of .NET Methods
.NET features not supported in MATLAB.
Limitations to Support of .NET Events
.NET features not supported in MATLAB.
Limitations to Support of .NET Delegates
.NET features not supported in MATLAB.
Limitations to Support of .NET Enumerations
.NET features not supported in MATLAB.