cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Reinitialize Shapes using vbscript

supportshift
New Contributor

Hi,

 

Does this script work on HOPEX V2R1 U02?

 

oQuery = "Select [Diagram] Where nature Not = 'ANALYSISDIAGRAM' And Nature Not = 'GENERICGANTT' And [Update Version]<'30208'"

 

Set cDiag = GetSelection(oQuery, "Short name", -1)

For each oDiag in cDiag

  Set oDrawing = oDiag.Drawing("RW")

    

                                                                oDrawing.Resetshapes

        oDrawing.Flush

Next

 

I tried it but I am getting the below error:

 

Script Editor Default: Microsoft VBScript runtime error line 7, offset 70 :

Error(0x800a01a8) : Object required: ‘oDrawing’

 

Any hints?

1 Reply

hsoegaard
MEGA Partner
MEGA Partner

Hi,

 

I just quickly tested your script on HOPEX V2R1 update 3 - and I dont get any error, and it looks like it is running as expected.