Talk:Repository.BlockSim.UpdateRBDBlockData/Notes: Difference between revisions
Jump to navigation
Jump to search
Kate Racaza (talk | contribs) No edit summary |
Kate Racaza (talk | contribs) No edit summary |
||
Line 26: | Line 26: | ||
BlockData = MyRepository.BlockSim.GetAllRBDBlocksData(21) | BlockData = MyRepository.BlockSim.GetAllRBDBlocksData(21) | ||
{{APIComment|'Change the name of the first block in the array.}} | {{APIComment|'Change the block name and associated URD of the first block in the array.}} | ||
BlockData(0).DisplayName = {{APIString|"New Block Name"}} | BlockData(0).DisplayName = {{APIString|"New Block Name"}} | ||
BlockData(0).URDID = 2 | |||
{{APIComment|'Send the | |||
{{APIComment|'Send the changes to the Synthesis repository.}} | |||
{{APIPrefix|Call}} MyRepository.BlockSim.UpdateRBDBlockData(BlockData(0)) | {{APIPrefix|Call}} MyRepository.BlockSim.UpdateRBDBlockData(BlockData(0)) | ||
Line 45: | Line 46: | ||
BlockData = MyRepository.BlockSim.GetAllRBDBlocksData(21) | BlockData = MyRepository.BlockSim.GetAllRBDBlocksData(21) | ||
{{APIComment|'Change the name of the first block in the array.}} | {{APIComment|'Change the block name and associated URD of the first block in the array.}} | ||
BlockData(0).DisplayName = {{APIString|"New Block Name"}} | BlockData(0).DisplayName = {{APIString|"New Block Name"}} | ||
BlockData(0).URDID = 2 | |||
{{APIComment|'Send the change to the Synthesis repository.}} | {{APIComment|'Send the change to the Synthesis repository.}} | ||
MyRepository.BlockSim.UpdateRBDBlockData(BlockData(0)) | MyRepository.BlockSim.UpdateRBDBlockData(BlockData(0)) |
Revision as of 18:01, 27 May 2016
Member of: SynthesisAPI.Repository
Sends any changes made to a BlockSim block to the Synthesis repository. Returns a Boolean value; when true, indicates a successful save.
Syntax
.BlockSim.UpdateRBDBlockData(data)
Parameters
data
- Required. The RBDBlockData object to be updated.
Example
VBA 'Connect to a Synthesis repository. Dim MyRepository As New Repository MyRepository.ConnectToAccessRepository("C:\RSRepository1.rsr10") 'Connect to project #1 in the repository. MyRepository.Project.SetCurrentProject (1) 'Get the data for all blocks in diagram #21. Dim BlockData() As RBDBlockData BlockData = MyRepository.BlockSim.GetAllRBDBlocksData(21) 'Change the block name and associated URD of the first block in the array. BlockData(0).DisplayName = "New Block Name" BlockData(0).URDID = 2 'Send the changes to the Synthesis repository. Call MyRepository.BlockSim.UpdateRBDBlockData(BlockData(0))
VB.NET 'Connect to a Synthesis repository. Dim MyRepository As New Repository MyRepository.ConnectToAccessRepository("C:\RSRepository1.rsr10") 'Connect to project #1 in the repository. MyRepository.Project.SetCurrentProject (1) 'Get the data for all blocks in diagram #21. Dim BlockData() As RBDBlockData BlockData = MyRepository.BlockSim.GetAllRBDBlocksData(21) 'Change the block name and associated URD of the first block in the array. BlockData(0).DisplayName = "New Block Name" BlockData(0).URDID = 2 'Send the change to the Synthesis repository. MyRepository.BlockSim.UpdateRBDBlockData(BlockData(0))