Hello all, I need some help to develop a VBScript with macros for ARIS Toolset 7.1. Actually i've inserted the picture, but i can't move it cause the script is not recognizing the command to move pictures. Follow below this part of the code inside ARIS Toolset 7.1: Dim picture_left As Object Set picture_left = CurrentSheet.Pictures.Insert("C:\Program Files\ARIS7.1\script\basic\samplePic.jpg") CurrentSheet.Application.Shapes("picture_left").Select CurrentSheet.Application.Range("picture_left").Select CurrentSheet.Application.Selection.ShapeRange.IncrementLeft 0.10 CurrentSheet.Application.Selection.ShapeRange.IncrementTop -190 'CurrentSheet.Outline.AutomaticStyles = False Machine settings: OS: Windows 7 Home Premium Processor: Intel Core i3 2.13GHz Memory (RAM): 4Gb System type: 64-Bit ARIS Version: 7.1.0.478722 Local DB P.S. 1: I've already tryed the command "MoveTo" and create a new Excel Output Class (without macro), but doesn't work too. P.S. 2: This script was working fine in the ARIS Toolset 6.1.1.30317 release version, but after it was converted, this part of the code doesn't working fine anymore. Hope someone can help me. Kind regards, Andre Sales São Paulo / Brasil
3 Replies
Hello Martin,
Follow your answer:
Office: 2007
Yeah, I used this version (6.1.1.30317). After this, the database was converted to ARIS Toolset 6.2.3.50422 and finally to Toolset 7.1.0.478722. Do you have some idea?
Thanks,
Andre
Hello Andre,
you are using Excel VBA here, not Aris Basic, so my question was what has changed on the Excel end since you said this script was working fine in the ARIS Toolset 6.1?
If currentSheet is a reference to the Excel.Application.Workbook the code seems redundant to me:
CurrentSheet.Application.Shapes("picture_left").Select
CurrentSheet.Application.Range("picture_left").Select
CurrentSheet.Application.Selection.ShapeRange.IncrementLeft 0.10To get a ShapeRange object it should be sufficient to name the item of the Shapes array (cf. Excel 2007 Help):
With CurrentSheet.Shapes("picture_left").Select
.IncrementLeft 0.10
.IncrementTop -190
End With Hope this helps, Martin
Martin Schröder on
Hello Andre,
which Office or Excel version do you use now?
Which version did you use with ARIS Toolset 6.1.1.30317 ?
Regards, Martin