forked from ventrian/News-Articles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathucEditTags.ascx.vb
executable file
·60 lines (37 loc) · 1.54 KB
/
ucEditTags.ascx.vb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
Imports DotNetNuke.Common.Utilities
Imports DotNetNuke.Services.Exceptions
Imports DotNetNuke.Services.Localization
Imports Ventrian.NewsArticles.Base
Namespace Ventrian.NewsArticles
Partial Public Class ucEditTags
Inherits NewsArticleModuleBase
#Region " Private Methods "
Private Sub BindTags()
Dim objTagController As New TagController
Localization.LocalizeDataGrid(grdTags, Me.LocalResourceFile)
grdTags.DataSource = objTagController.List(Me.ModuleId, Null.NullInteger)
grdTags.DataBind()
If (grdTags.Items.Count > 0) Then
grdTags.Visible = True
lblNoTags.Visible = False
Else
grdTags.Visible = False
lblNoTags.Visible = True
lblNoTags.Text = Localization.GetString("NoTagsMessage.Text", LocalResourceFile)
End If
End Sub
#End Region
#Region " Event Handlers "
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Try
BindTags()
Catch exc As Exception 'Module failed to load
ProcessModuleLoadException(Me, exc)
End Try
End Sub
Private Sub cmdAddTag_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdAddTag.Click
Response.Redirect(EditUrl("EditTag"), True)
End Sub
#End Region
End Class
End Namespace