I would like to provide some fixes to Feedback_03.02.01
Bug 1. Feedback Comments categories do not work.
Fix.
Open: ViewComments.ascx.vb
Find: Note: Is located in Sub BindData()
If Not Settings("Category") Is Nothing Then
Category = CType(Settings("Category"), Integer)
End If
Change to: Note: change ‘Category’ to lowercase ‘category’.
If Not Settings("category") Is Nothing Then
Category = CType(Settings("category"), Integer)
Bug 2. Feedback Comments settings Category does not populate.
Open: CommentSettings.ascx.vb
Find:
Public Overrides Sub LoadSettings()
Try
If (Page.IsPostBack = False) Then
'bind the categories from the Lists table
Dim oLists As New Lists.ListController
Dim aList As Lists.ListEntryInfoCollection = oLists.GetListEntryInfoCollection("Feedback_Categories")
Me.cboCategory.DataSource = aList
Me.cboCategory.DataTextField = "Text"
Me.cboCategory.DataValueField = "Value"
Me.cboCategory.DataBind()
Me.cboCategory.Items.Insert(0, New System.Web.UI.WebControls.ListItem("None Selected", "0"))
End If
Catch exc As Exception 'Module failed to load
ProcessModuleLoadException(Me, exc)
End Try
End Sub
Add:
Me.cboCategory.SelectedIndex = Me.cboCategory.Items.IndexOf(Me.cboCategory.Items.FindByValue(CType(ModuleSettings("category"), String)))
Example:
Public Overrides Sub LoadSettings()
Try
If (Page.IsPostBack = False) Then
'bind the categories from the Lists table
Dim oLists As New Lists.ListController
Dim aList As Lists.ListEntryInfoCollection = oLists.GetListEntryInfoCollection("Feedback_Categories")
Me.cboCategory.DataSource = aList
Me.cboCategory.DataTextField = "Text"
Me.cboCategory.DataValueField = "Value"
Me.cboCategory.DataBind()
Me.cboCategory.Items.Insert(0, New System.Web.UI.WebControls.ListItem("None Selected", "0"))
Me.cboCategory.SelectedIndex = Me.cboCategory.Items.IndexOf(Me.cboCategory.Items.FindByValue(CType(ModuleSettings("category"), String)))
End If
Catch exc As Exception 'Module failed to load
ProcessModuleLoadException(Me, exc)
End Try
End Sub
Recompile.. walaa…