.NET serialized objects during recording
We are using 12.50 against a .NET Windows client/server application.
When we record all large as well as SMALL objects returned by the server are captured at record time and are serialized and stored in *.XML files. Then vuGen recording adds the following LR statement to instantiate the object:
searchFilter = ((SearchFilter)(LrReplayUtils.GetSerializedObject( "Serialization_10.xml")));
We would prefer that LR record object creation and initialization as in this equivalent hand coded set of statements that replace the above:
SearchFilter searchFilter = new SearchFilter();
// default search options
searchFilter.SetValue(OrderSearchResultFilter.Date Type, 1);
searchFilter.SetValue(OrderSearchResultFilter.Orde rsInStage, 0);
searchFilter.SetValue(OrderSearchResultFilter.Item sInStage, 0);
searchFilter.SetValue(OrderSearchResultFilter.Quar antineInStage, 1);
searchFilter.SetValue(OrderSearchResultFilter.Incl udeCancelled, 1);
searchFilter.SetValue(OrderSearchResultFilter.Incl udeCompleted, 1);
searchFilter.SetValue(OrderSearchResultFilter.Show AllResults, 0);
searchFilter.SetValue(OrderSearchResultFilter.IsUn assignedOrderSearch, 0);
We have tried these settings in the .NET Recording Options:
1. unchecking the "Serialize long arrays" option
2. checking the "Serialize long arrays" option and setting the Threshold value to 9999999
But given this object creation is not an array I am not surprised this has no effect.
So is it possible to configure recording options to do what we want? Right now our workaround is to hand code what we want and delete the deserialization statement.
-Thanks, Terry Horwath
Last edited by Terry Horwath; 01-21-2016 at 05:10 AM.