各製品の資料を入手。
詳細はこちら →Viewing Dynamics 365 Business Central データ in RAD Studio Data Explorer
How to view Dynamics 365 Business Central データ in RAD Studio Data Explorer using the CData ODBC Driver for Dynamics 365 Business Central.
最終更新日:2023-06-12Embarcadero RAD Studio provides a development environment for Delphi and C++Builder applications. With the CData ODBC Driver for Dynamics 365 Business Central, you gain access to live Dynamics 365 Business Central データ within RAD Studio, abstracting the data into tables, views, and stored procedures that can be used to both retrieve and update Dynamics 365 Business Central データ. This article will walk through connecting to Dynamics 365 Business Central using the Data Explorer.
Configure a Connection to Dynamics 365 Business Central
If you have not already, first specify connection properties in an ODBC DSN (data source name). This is the last step of the driver installation. You can use the Microsoft ODBC Data Source Administrator to create and configure ODBC DSNs.
Dynamics 365 Business Central 接続プロパティの取得・設定方法
Dynamics 365 Business Central への認証には、User およびAccessKey プロパティが必要です。
データに接続するには、OrganizationUrl を指定します。OrganizationUrl は、 http://businesscentral.dynamics.com/abc123/ などのBusiness Central アカウントへのエンドポインであるか、Web サービスのルートを参照する必要があります。OrganizationUrl を指定する方法 および利用可能なエンドポイントについての詳細は、Business Central エンドポイント を参照してください。組織内に複数の会社がある場合は、どの会社に接続するかを特定するためにCompany を指定する必要があります。 会社が1つだけの場合は、Company を指定する必要はありません。
Dynamics 365 Business Central に認証するには、User およびAccessKey 接続プロパティを指定します。Microsoft では、これらをテストおよび開発目的で推奨します。ただし、運用環境での使用は推奨していません。User およびAccessKey の値を取得するには、Dynamics 365 Business Central の「ユーザー」ページに移動して「編集」をクリックします。User Name および Web Service Access Key の値は、User およびPassword 接続文字列プロパティとして入力する値です。User Name はE メールアドレス ではありません。短縮されたユーザー名です。
Microsoft では、OAuth 認証を使用する本番ユースケースを推奨します。詳細については、ヘルプドキュメントの「OAuth 認証の使用」を参照してください。
Connecting to Dynamics 365 Business Central データ Using Data Explorer
You can create a simple application for displaying Dynamics 365 Business Central データ by utilizing the CData FireDAC Components for Dynamics 365 Business Central and a new VCL Forms Application:
- Open the Data Explorer in RAD Studio and expand FireDAC.
- Right-click the ODBC Data Source node in the Data Explorer.
- Click Add New Connection.
- Enter a name for the connection.
- In the FireDAC Connection Editor that appears, set the DataSource property to the name of the ODBC DSN for Dynamics 365 Business Central.
- Back in the Data Explorer, expand the tables for the connection.
Create a new VCL Forms application and drag a table (for example: Accounts) onto the form.
- Select the AccountsTable object on the form and set the Active property to true.
Right-click on the object, bind visually, and link everything (*) to a new control (TStringGrid).
Arrange the TStringGrid on the form and run the application to see the Accounts data.
Related Articles
Below you can find other articles for using the CData ODBC Driver with RAD Studio, Delphi, and C++ Builder.