Josh Larios
-
11/10/2009 5:07:57 PM
Inappropriate cache in BizFormInfoProvider?
I'm writing a replacement for the "Generate Table Layout" button on the BizForm layout editing page, and to get all the information I want, I'd like to parse the bizform's definition. My first attempt was (roughly) this:
BizFormInfo bfi = BizFormInfoProvider.GetBizFormInfo(bizFormId); stringToParse = bfi.Form.GetXmlDefinition();
But it turned out that if I changed the fields on the bizform (by adding or deleting a field, or any other change), the definition string contained an old version. So I changed my method to this:
BizFormInfo bfi = BizFormInfoProvider.GetBizFormInfo(bizFormId); DataClassInfo dci = DataClassInfoProvider.GetDataClass(bfi.FormClassID); stringToParse = dci.ClassFormDefinition;
And that works. DataClassInfo.ClassFormDefinition contains current info, while BizFormInfo.Form.GetXmlDefinition() doesn't.
Is that supposed to be the case? Or is there some method of BizFormInfo I could call which would force it to flush its cache? TouchKeys() didn't seem to do anything.
|