I am trying to use the Folder Picker and installing as described, but when I create the new Data type and choose TH.FolderPicker as the Render Control and then choose Save I immediately get an Object reference not set to an instance of an object error. The stack trace is as follows:
[NullReferenceException: Object reference not set to an instance of an object.] TH.FolderPicker.ExtensionMethods.GetWebFolder(TreeNode node) +32 TH.FolderPicker.PrevalueEditor.Save() +174 umbraco.cms.presentation.developer.editDatatype.save_click(Object sender, ImageClickEventArgs e) +31 System.Web.UI.WebControls.ImageButton.OnClick(ImageClickEventArgs e) +108 System.Web.UI.WebControls.ImageButton.RaisePostBackEvent(String eventArgument) +118 System.Web.UI.WebControls.ImageButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565
I am using umbraco v 4.0.2.1, Windows 7, Firefox 3.5.5, IIS 7 and Asp.net 3.5. The same happens in Internet Explorer.
I suspect that the tree node is null, because I have had no opportunity to select a node because no treeview has appeared when I chose the TH.FolderPicker as the Render Control. I can't remember if this was always the case in Umbraco, but when choosing any control to render, specific properties of the control are not displayed until after the Save button is pressed and datatype is saved and re-rendered.
Any suggestions on why this is happening and what I can do about it?
Not sure but I think the datatype depends on a configuration(had that issue with some datatypes in the past). To solve it hover over the datatype in the node tree (in Umbraco) You will see the node Id when you hover over the item. Open up Sql server, insert a new record in the table cmsDataTypePreValues , Enter the node Id in column dataTypeNodeId, emty string in value and alias. 0 in sort.
Can't make datatype without error
Thomas,
I am trying to use the Folder Picker and installing as described, but when I create the new Data type and choose TH.FolderPicker as the Render Control and then choose Save I immediately get an Object reference not set to an instance of an object error. The stack trace is as follows:
I am using umbraco v 4.0.2.1, Windows 7, Firefox 3.5.5, IIS 7 and Asp.net 3.5. The same happens in Internet Explorer.
I suspect that the tree node is null, because I have had no opportunity to select a node because no treeview has appeared when I chose the TH.FolderPicker as the Render Control. I can't remember if this was always the case in Umbraco, but when choosing any control to render, specific properties of the control are not displayed until after the Save button is pressed and datatype is saved and re-rendered.
Any suggestions on why this is happening and what I can do about it?
Regards,
Brian.
Had been ill, will look into ti this evening...
Thomas
Hi Thomas,
Hope you are feeling better.
Have you had a chance to look in to the problem I am having with the folder picker. Have you been able to reproduce it?
Regards,
Brian.
Hi Brian,
Not sure but I think the datatype depends on a configuration(had that issue with some datatypes in the past). To solve it hover over the datatype in the node tree (in Umbraco) You will see the node Id when you hover over the item. Open up Sql server, insert a new record in the table cmsDataTypePreValues , Enter the node Id in column dataTypeNodeId, emty string in value and alias. 0 in sort.
Hope this works for you,
Richard
Richard,
Thanks for the suggestion, but I'm afraid it didn't work.
Regards,
Brian.
Sorry for the delay,
I am taking a look into right now...
Thomas
Found and fixed the bug (don't know why I didn't get it in my tests, weired)...
Uploaded v0.2 please use this version.
Thanks for submitting this bug,
Thomas
Thanks Thomas, that worked fine.
Brian.
is working on a reply...