cancel
Showing results for 
Search instead for 
Did you mean: 

how to get IWDView ,but not in the wdModifyView method?

Former Member
0 Kudos

We can modify the property of view's UIs in the wdModifyView method,but if i want to get the IWDView in my own method,not static methods,can i get it?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

To Satyajit and Manoj,

First,thank you for replying the question!

I know your meanings,but i just want to know whether it's possible to get the view object in a non-static method directly.

Former Member
0 Kudos

Hi,

Yes again there is solution for this or rather a workaround. But still it is not adviced and hence i will not be able to provide you the solution. I will stick to the previous response i gave.

thanks & regards,

Manoj

Former Member
0 Kudos

Hi,

Yes, it's possible to have an IWDView reference in a non-static context. Edited.

But as mentioned this is not recommended.

Regards,

Satyajit.

Edited by: Satyajit Chakraborty on Mar 28, 2008 10:22 AM

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

As Satyajit correctly said, it is not adviced to use IWDView reference out side wdDoMidify().

Say if you want to make a inputfield disable onClick of a button then map a attribute of type boolean to the enabled property of the inputfield and onClick action of the button set this property to false.

This way you can achieve almost everything.

thanks & regards,

Manoj

Former Member
0 Kudos

Hi,

It is not a best practise to modify the view via an IWDView reference outside the dedicated hook method wdDoModifyView. If you want to make changes to the view from your own methods, then the standard way would be to raise a flag from your methods, check this flag in wdDoModifyView and then do the modifications within wdDoModifyView.

Regards,

Satyajit.