DELMIA V5 - Work Instruction Generation - How to Resize Screen 4:3

Dear colleagues.

I want to share an easy macro with all Delmia V5 users very useful when you want to modify the screen in order to get 4:3 ratio when you make a picture during the work instruction generation.

'**************************************'

'***** DELMIA_Screen_Resize *****'

'**************************************'

Sub CATMain()

Set myWindow = CATIA.ActiveWindow

if myWindow.windowstate = 2 then

myWindow.windowstate = 0

CATIA.ActiveWindow.Layout = 2

else

myWindow.windowstate = 0

WindowH = CATIA.ActiveWindow.Height

WindowW = CATIA.ActiveWindow.Width

'CATIA.ActiveWindow.Layout = 1

myWindow.windowstate = 2

CATIA.ActiveWindow.top = 0

CATIA.ActiveWindow.Height = WindowH

CATIA.ActiveWindow.Width = WindowH * 4/3

CATIA.ActiveWindow.left = ( WindowW -CATIA.ActiveWindow.Width) / 2

end if

'Value1 = 2

'myWindow.Width = WindowW * Value1

'myWindow.Height = WindowH * Value1

'myWindow.Width = WindowW * Value1

'myWindow.Height = WindowH * Value1

'CATIA.ActiveWindow.Width = WindowH*4 / 3

'CATIA.ActiveWindow.Height = WindowW *3 / 4

'msgbox "V:" & CATIA.ActiveWindow.Width & " H:" & CATIA.ActiveWindow.Height

'Set viewer3D1 = myWindow.ActiveViewer

'viewer3D1.Update

'CATIA.ActiveWindow.ActiveViewer.CaptureToFile catCaptureFormatJPEG, "c:\\temp\\Capture.jpg"

'myWindow.Width = WindowW

'myWindow.Height = WindowH

'CATIA.ActiveWindow.ActiveViewer.Reframe

'CATIA.ActiveWindow.Layout = 2

End Sub

Pointing the current macro library (Tools\\Macro\\Tool macro library) to this script is able to resize the screen supporting 4:3 ratio.

Regards