Help extending the Windows Computer form
No matter how I extend the class or the form, I can't get the date to successfully save in the SCSM console. Any help would be appreciated!
Here's what I have so far:
A sealed management pack that contains the class extension. I extended the Windows Operating System class (Hosted & Extension).
I added one new property to this class extension and it's a Date Time (currently called Date Test for testing).
I have another sealed management pack containing the form extension. I am customizing the Windows Computer form.
We want the new date to be located into the Operating System section. I added one in the screenshot below.
I bind it to the property I created (two way).
I import the two seal MPs in my dev console and when I fill in the date and save, the data is lost when I close the form.
If I try to do the same thing directly into the Windows Computer class and into the Computer Identity section of the form, it will work but any extension to the OS section doesn't save. It probably have something to do because it's a hosted class but I can't find any information about it.
Any hint or help would be greatly appreciated!
Thanks
Best Answer
-
David_Morris1 Member Advanced IT Monkey ✭✭✭Hi,
this is because authoring tool gets confused with the sub-class within the form.
once you have created the custom form and class property and bind them as you have in the previous post open the unsealed management pack xml
go to the forms section
find your customised form
find the Propertybindingchange section
in new bindings change the path from "OperatingSystem.datetime" to just "datetime" where datetime is your property name
once this is complete seal your pack6
Answers
https://systemcenternoise.wordpress.com/2015/03/10/form-customisations-dont-show-in-the-console/
Do you have the Cireson preview MP's installed?
These can introduce this issue.
I am trying to expand the Operating System section hosted in the Windows Computer class and form. Any extension that I do to the Windows Computer class and form will work and save successfully except when they are located in the "Operating System" section of the Windows Computer General tab (from extension).
For example, in the screenshot below;
- the date property located in Computer Identity section can be saved
- the Windows.Operating.System date field in the Operating System section won't save
- the Windows.Computer date field in the Operating System section won't save
Even if I extended the Windows Computer Operating System hosted class, the property won't save which seems to me like the thing to do.
Is the "Ext of the Windows Computer Class" property the same in both sections on this form?
If it's working for one and not on the other, what are the differences between the two?
This is why I tried to extend the Windows Operating System hosted class instead but I get the same result unfortunately. I can successfully save if I edit an Windows OS object directly but from the windows computer form, it doesn't save.
this is because authoring tool gets confused with the sub-class within the form.
once you have created the custom form and class property and bind them as you have in the previous post open the unsealed management pack xml
go to the forms section
find your customised form
find the Propertybindingchange section
in new bindings change the path from "OperatingSystem.datetime" to just "datetime" where datetime is your property name
once this is complete seal your pack
I can't believe it was only that. It will be useful to know in the future.