powerpoint - VBA assignment causing program to crash but only in presentation view -


i trying debug user form powerpoint. seems working when run directly using run button in editor. when try run presentation mode using button fixed in masterslide program seems crash suddenly. form run , when press ok first message box used debugging show , nothing.

here code

    private sub okbut_click() ' message box working msgbox ("okbut running") dim oslide slide  dim lcurrentview long        ' current view type. lcurrentview = activewindow.viewtype 'these message boxes not appear msgbox ("test") msgbox (cstr(lcurrentview)) 

thanks in advance guys

activewindow.viewtype applicable in design mode. when running slide show there no active windows , throw error thats why not hitting message box calls.


Comments

Popular posts from this blog

javascript - Karma not able to start PhantomJS on Windows - Error: spawn UNKNOWN -

c# - Display ASPX Popup control in RowDeleteing Event (ASPX Gridview) -

Nuget pack csproj using nuspec -