API Tutorials: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
(10 intermediate revisions by the same user not shown)
Line 2: Line 2:
{{Template:BacktoPrevPage|[[Synthesis API Reference|<< Back to API Main Page]]}}
{{Template:BacktoPrevPage|[[Synthesis API Reference|<< Back to API Main Page]]}}


Below are simple tutorials to help you get started with using the Synthesis API. The tutorials assume some basic working knowledge in VBA or VB.NET programming, and general familiarity with the Synthesis Platform.  
Below are simple tutorials to help you get started with using the Synthesis API. The tutorials assume some basic working knowledge in VBA or .NET programming, and general familiarity with Synthesis applications.  


Before you begin, be sure to review the [[Synthesis_API_Reference|prerequisites]] presented in the API overview page.


==Using Object IDs==
==Referencing the Synthesis API Library File==
Each item in a Synthesis repository is identified by a unique record identifier called an ''object ID''. Object IDs can help you trace responses from the API, which are helpful when learning how to use the API to read/write data to a repository.
{{:Synthesis API Reference}}
 
==Tutorials==
To display the object ID in a Synthesis application, choose '''File > Application Setup''', then click '''Other''' under the '''Synthesis Settings''' heading in the navigation panel. Select the check box for '''Display Object IDs'''. The object IDs will be displayed for the following items:
Before you begin, be sure to review the [[Synthesis_API_Reference|prerequisites]] presented in the overview page. The tutorials are designed to work with the latest version of the Synthesis applications.
 
{|border="1" cellpadding="5" cellspacing="0" style="border-collapse: collapse; text-align: left; cellborder"
|- style="background:#F2F2F2;"
!<span style="color:#585858;">Item</span>
!<span style="color:#585858;">Location of ID in the application</span>
|-
|Project||The ID is displayed in two locations:


* The Project Properties window ('''Project > Management > Edit Project Properties''') displays the project's object ID at the caption bar of the window.
* The Manage Projects window ('''Project > Management > Manage Projects''') displays a column containing the object IDs of each project in the database.
|-
|Resource (e.g., models,URDs, etc.)||The Resource Manager ('''Project > Synthesis > Resource Manager''') displays a column containing the object IDs of the resources.
|-
|Xfmea, RCM++ or RBI system hierarchy item||To display the object ID (also called ''record ID'') of a system hierarchy item, right-click any of the column headers in the System Hierarchy panel and choose '''Customize Columns'''. Select the '''Record ID''' check box.
|-
|FMEA records (e.g., functions, causes, etc.)||To display the object IDs of FMEA functions, causes, effects, controls and actions, right-click any of the column headers in the FMEA analysis and choose '''Customize Columns'''. Select the '''Record ID''' check box.
|-
|BlockSim diagrams and block IDs ||The IDs are displayed on the diagram control panel.
|}
==Tutorials==
====Basics====
====Basics====
If you're new to the Synthesis API, we recommend starting with the basic tutorials in the order given below.
*[[Connect or Disconnect from a Synthesis Repository]]
 
*[[Add New Synthesis Resources to a Repository]]
* [[Connect or Disconnect from a Synthesis Repository]]
*[[Edit Existing Synthesis Resources]]
 
*[[Calculate Results from a Model]]
* [[Add New Synthesis Resources to a Repository]]
 
* [[Edit Existing Synthesis Resources]]
 
====Applications====
* [[Calculate Results from a Model]]
 
* [[Transfer Data to the Synthesis Data Warehouse (SDW)]]
 


====Importing Data====
*[[Transfer Data to the Synthesis Data Warehouse (SDW)]]


''<span style="font-size:12pt; color:#808080;">More tutorials coming soon...</span>''
====Performing Analyses and Creating Plots <span style="color:#585858">(requires a Synthesis API license)</span>====
*[[Perform Life Data Analysis on External Data Source|Perform Life Data Analysis]]
*[[Perform Accelerated Life Testing Data Analysis on External Data Source|Perform Accelerated Life Testing Data Analysis]]
*[[Perform Accelerated Life Testing Data Analysis with Stress Profiles]] (Click [[Perform Accelerated Life Testing Data Analysis with Stress Profiles 10|here]] for Version 10 of this tutorial.)
*[[Create Plots]]

Latest revision as of 23:29, 2 August 2017

APIWiki.png


<< Back to API Main Page

Below are simple tutorials to help you get started with using the Synthesis API. The tutorials assume some basic working knowledge in VBA or .NET programming, and general familiarity with Synthesis applications.


Referencing the Synthesis API Library File

To use the ReliaSoft API in your code, you must reference the ReliaSoft API library in your VBA or .NET projects. The file is located in the folder where the ReliaSoft desktop applications are installed. By default for Version 2023, this folder is at "C:\Program Files\ReliaSoft\ReliaSoft 2023." For VBA, you will use the ReliaSoftAPI23.tlb file; for .NET applications, you will use the ReliaSoftAPI23.dll file.

To reference the library in VBA:

  1. Enter the VBA environment by clicking the Visual Basic command on the Developer tab (If the Developer tab is not visible, see this Microsoft article).
  2. In the VBA environment, choose Tools > References.
  3. Click Browse and find the ReliaSoftAPI23.tlb file on your computer. Click OK.

To reference the library in Visual Studio:

  1. In the Solution Explorer, right-click the References node of your project and choose Add References.
  2. In the Reference Manager window, click the Browse tab and find the ReliaSoftAPI23.dll file on your computer. Click OK.
  3. Edit your project file, either directly using any text editor, or by right-clicking your project and choosing Unload Project, then right-clicking your project again and choosing Edit Project File
  4. Insert the following line just before the last </Project> clause (change the path if necessary):
<Import Project="C:\Program Files\ReliaSoft\ReliaSoft 2023\ReliaSoftAPI.targets" />
This will ensure the required files are copied into your project’s destination folder during the build.
  1. Save the project file. If you unloaded the project in step 3, right-click the project and choose Reload Project.

Tutorials

Before you begin, be sure to review the prerequisites presented in the overview page. The tutorials are designed to work with the latest version of the Synthesis applications.

Basics

Importing Data

Performing Analyses and Creating Plots (requires a Synthesis API license)