CProfile.GetSegments: Difference between revisions
Jump to navigation
Jump to search
Kate Racaza (talk | contribs) (Created page with '{{DISPLAYTITLE:cProfile.GetSegments}}{{Template:API}}{{Template:APIBreadcrumb|.cProfile}}{{InProgress}} <onlyinclude>Returns an array of [[ProfileSegment Cla…') |
Kate Racaza (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
{{DISPLAYTITLE:cProfile.GetSegments}}{{Template:API}}{{Template:APIBreadcrumb|.[[CProfile_Class|cProfile]] | {{DISPLAYTITLE:cProfile.GetSegments}}{{Template:API}}{{Template:APIBreadcrumb|.[[CProfile_Class|cProfile]]}} | ||
Latest revision as of 22:17, 22 March 2017
Member of: SynthesisAPI.cProfile
Returns an array of ProfileSegment objects that represent the segments in the profile.
Syntax
.GetSegments()
Example
This example assumes that a profile with ID #1 exists in the first project of a Synthesis repository.
VBA 'Declare a new Repository object and connect to a Synthesis repository. Dim MyRepository As New Repository MyRepository.ConnectToAccessRepository("C:\RSRepository1.rsr11") 'Get profile #1 from project #1. Dim Resource As cProfile MyRepository.Project.SetCurrentProject(1) Set Resource = MyRepository.Profile.GetProfile(1) 'Get the profile's segments. Dim ListofSegments() As ProfileSegment ListofSegments = Resource.GetSegments 'Output sample: Display the value of the first segment. MsgBox (ListofSegments(0).Value)
VB.NET 'Declare a new Repository object and connect to a Synthesis repository. Dim MyRepository As New Repository MyRepository.ConnectToAccessRepository("C:\RSRepository1.rsr11") 'Get profile #1 from project #1. Dim Resource As cProfile MyRepository.Project.SetCurrentProject(1) Resource = MyRepository.Profile.GetProfile(1) 'Get the profile's segments. Dim ListofSegments() As ProfileSegment ListofSegments = Resource.GetSegments 'Output sample: Display the value of the first segment. MsgBox (ListofSegments(0).Value)