ChrisHammond / DNNTemplates

Christoc's DotNetNuke Extension Development templates for Visual Studio
http://www.christoc.com/Products/DNN-Development-Templates
Other
97 stars 38 forks source link

Exception: Input string was not in a correct format #63

Closed micahsdad1402 closed 3 years ago

micahsdad1402 commented 5 years ago

When using SampleModule (Video 13), and no Assigned User is selected (there are none in the drop down), there is an exception from Edit.ascx.cs

Line 88: AssignedUserId = Convert.ToInt32(ddlAssignedUser.SelectedValue)

Changed it to AssignedUserId = (ddlAssignedUser.SelectedValue == "") ? 0 : Convert.ToInt32(ddlAssignedUser.SelectedValue)

ChrisHammond commented 3 years ago

Thanks for this @micahsdad1402 I will work to get this fix into a new release, along with a VB version of this fix as wel.

ChrisHammond commented 3 years ago

This is resolved in the 10.2 release coming ;)