This project is read-only.

Modifying FieldofView dynamically.

Jul 17, 2009 at 2:14 PM

Hi

I am trying to modify the FieldOfView dynamically by adding a textbox and a mouse_leave event.
When a number is entered and tabbed out the event triggers.
When setting the FieldOfValue propertty i am getthing this exception.

Cannot set a property on object 'System.Windows.Media.Media3D.PerspectiveCamera' because it is in a read-only state.

private void txtSecs_MouseLeave(object sender, MouseEventArgs e)
        {
            double result = 0.0;
            if(double.TryParse(this.txtCameraFldofView.Text, out result))
                this._elementFlow.Camera.FieldOfView = result;
        }
Please let me know if you have any suggestions.
Thanks
Navin