Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Get and Set Frame Rate for a Motion Study leads to a crash when using late binding.

3 views
Skip to first unread message

Noel

unread,
Dec 15, 2009, 5:04:37 AM12/15/09
to sanj...@gmail.com, dps...@gmail.com, noel....@gmail.com
Hi All,

I am having a problem when I use Late Binding to Get and Set the Frame
Rate for a Motion Study. Following is the code snippet that I use.

int nFrameRate = System.Convert.ToInt32(msProperty.GetType
().InvokeMember
("GetFrameRate",BindingFlags.InvokeMethod,null,msProperty,null));

msProperty.GetType().InvokeMember
("SetFrameRate",BindingFlags.InvokeMethod,null,msProperty,new object[]
{ nFrameRate });

msProperty is an object of MotionStudyProperties class.

This code was running fine in early binding. But the application does
not work across different versions of SolidWorks, hence I had to use
late binding.

A resolution or workaround for the issue would be highly appreciated.

Thanks.

Noel

0 new messages