Talk:Repository.Action.GetAllActions/Notes: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
(Created page with '<onlyinclude>Gets a list of actions associated with a project. Returns a '''cAction''' object array that contains the actions in that project.</onlyinclude> …')
 
(Blanked the page)
 
Line 1: Line 1:
<onlyinclude>Gets a list of actions associated with a project. Returns a '''[[CAction Class|cAction]]''' object array that contains the actions in that project.</onlyinclude> 


== Syntax ==
'''.Action.GetAllActions'''(''Filter'')
===Parameters===
''Filter''
:Optional. A filter that returns a particular type of action resource (e.g., global only, local and global only, etc.). Can be any [[ResourceFilterEnum Enumeration|ResourceFilterEnum]] constant. Default value = 0, which returns local actions only.
== Example ==
This example assumes that actions exist in the first available project of a repository.
'''VBA|VB.NET'''
{{APIComment|'Add code to connect to a Synthesis repository.}}
  {{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository
  {{APIComment|...}}
 
{{APIComment|'Get a list of all local actions in project #1.}}
  {{APIPrefix|Dim}} ListofActions() {{APIPrefix|As}} cAction
  MyRepository.Project.SetCurrentProject (1) 
  ListofActions = MyRepository.Action.GetAllActions()
{{APIComment|'Output sample: Display the number of elements in the array.}}
  {{APIPrefix|Dim}} NumberofElements {{APIPrefix|As}} Integer
  NumberofElements = UBound(ListofActions) - LBound(ListofActions) + 1
  MsgBox (NumberofElements)

Latest revision as of 17:17, 13 January 2016