Exists Picture 追蹤

0
Avatar
Legacy Poster

Hi,

 

Is it possible to test if an picture is in de layout.

 

if i use : btObject = btFormat.Objects.Find("Picture1")

 

It workst if "Picture1" exists

 

and crashes if it not exists. why..........

 

Problem is i want to change the picture if it exists.

 

thanks,

 

 

 

2 意見

0
Avatar
Ian Cummings
版主
評論操作 永久連結

Have you tried making the call in a Try...Catch statement?

 

http://msdn.microsoft.com/en-us/library/fk6t46tz(v=vs.71).aspx

0
Avatar
Legacy Poster
評論操作 永久連結

Thanx,

 

i'm writing in VBA, but build a function with on error goto:

this works

登入寫評論。