First create solution
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
Partial Class ASPxGridViewVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,110 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Web.Editors.ASPx
|
||||
Imports DevExpress.Web
|
||||
Imports DevExpress.ExpressApp.Model
|
||||
|
||||
Public Class ASPxGridViewVC
|
||||
Inherits DevExpress.ExpressApp.ViewController(Of ListView)
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
If TryCast(View, ListView) IsNot Nothing Then
|
||||
'AddHandler View.ControlsCreated, AddressOf View_Controlcreated
|
||||
End If
|
||||
End Sub
|
||||
Protected Overrides Sub OnDeactivated()
|
||||
MyBase.OnDeactivated()
|
||||
'If TryCast(View, ListView) IsNot Nothing Then
|
||||
' Dim gridListEditor As ASPxGridListEditor = TryCast(View.Editor, ASPxGridListEditor)
|
||||
' If gridListEditor IsNot Nothing Then
|
||||
' Dim _Grid As ASPxGridView = TryCast(gridListEditor.Grid, ASPxGridView)
|
||||
' If _Grid IsNot Nothing And GLOBAL_ListViewReset = False Then
|
||||
' GetColumnWithfromGrid(_Grid)
|
||||
' View.SaveModel()
|
||||
' End If
|
||||
' End If
|
||||
'End If
|
||||
End Sub
|
||||
Private Sub View_Controlcreated(sender As Object, e As EventArgs)
|
||||
Dim gridListEditor As ASPxGridListEditor = TryCast(View.Editor, ASPxGridListEditor)
|
||||
If gridListEditor IsNot Nothing Then
|
||||
Dim _Grid As ASPxGridView = TryCast(gridListEditor.Grid, ASPxGridView)
|
||||
If _Grid IsNot Nothing Then
|
||||
AddHandler _Grid.HtmlDataCellPrepared, AddressOf Grid_HtmlDataCellPrepared
|
||||
|
||||
_Grid.SettingsBehavior.ColumnResizeMode = ColumnResizeMode.Control
|
||||
'_Grid.Settings.UseFixedTableLayout = True
|
||||
_Grid.Settings.HorizontalScrollBarMode = DevExpress.Web.ScrollBarMode.Auto
|
||||
_Grid.Settings.UseFixedTableLayout = False
|
||||
'_Grid.Settings.
|
||||
SetColumnWithfromModel(_Grid)
|
||||
|
||||
_Grid.SettingsPager.Position = System.Web.UI.WebControls.PagerPosition.TopAndBottom
|
||||
Dim _IModelListViewExtender As IModelListViewExtender = TryCast(View.Model, IModelListViewExtender)
|
||||
If _IModelListViewExtender IsNot Nothing Then
|
||||
_Grid.Settings.GroupFormat = _IModelListViewExtender.GridViewGroupFormat
|
||||
End If
|
||||
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
Private Sub SetColumnWithfromModel(_Grid As ASPxGridView)
|
||||
For Each column As WebColumnBase In _Grid.Columns
|
||||
If (TypeOf column Is GridViewDataColumn) Then
|
||||
column.Width = CType(column, GridViewDataColumn).Width
|
||||
End If
|
||||
Next
|
||||
End Sub
|
||||
Private Sub GetColumnWithfromGrid(_Grid As ASPxGridView)
|
||||
For Each column As WebColumnBase In _Grid.Columns
|
||||
If (TypeOf column Is GridViewDataColumn) Then
|
||||
CType(column, GridViewDataColumn).Width = column.Width.Value
|
||||
End If
|
||||
Next
|
||||
End Sub
|
||||
Private Sub Grid_BeforeColumnSortingGrouping(sender As Object, e As ASPxGridViewBeforeColumnGroupingSortingEventArgs)
|
||||
Dim _IModelListViewExtender As IModelListViewExtender = TryCast(View.Model, IModelListViewExtender)
|
||||
If _IModelListViewExtender IsNot Nothing Then
|
||||
sender.Settings.GroupFormat = _IModelListViewExtender.GridViewGroupFormat
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Private Sub Grid_HtmlDataCellPrepared(sender As Object, e As ASPxGridViewTableDataCellEventArgs)
|
||||
Dim modelColumn As IModelColumnExtender = Nothing
|
||||
|
||||
If View IsNot Nothing Then
|
||||
If e.DataColumn.FieldName <> "" Then
|
||||
If e.DataColumn.FieldName.Contains(".") Then
|
||||
Dim NewName As String() = e.DataColumn.FieldName.Split(New Char() {"."c}, StringSplitOptions.RemoveEmptyEntries)
|
||||
modelColumn = TryCast(CType(View.Model.Columns, IModelList(Of IModelColumn))(NewName(NewName.Length - 1)), IModelColumnExtender)
|
||||
Else
|
||||
modelColumn = TryCast(CType(View.Model.Columns, IModelList(Of IModelColumn))(e.DataColumn.FieldName), IModelColumnExtender)
|
||||
End If
|
||||
If modelColumn IsNot Nothing Then
|
||||
If modelColumn.HideValueIfZero = True Then
|
||||
If e.CellValue = 0 Then e.Cell.Text = ""
|
||||
End If
|
||||
End If
|
||||
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,31 @@
|
||||
Partial Class AboutInfoCustomizationVC
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,55 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.SystemModule
|
||||
Imports DevExpress.Persistent.BaseImpl
|
||||
Imports DevExpress.Data.Filtering
|
||||
|
||||
Public Class AboutInfoCustomizationVC
|
||||
Inherits DevExpress.ExpressApp.WindowController
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
AboutInfo.Instance.AboutInfoString = GetCustomAboutString()
|
||||
End Sub
|
||||
Function GetCustomAboutString() As String
|
||||
Dim _CustomAboutString As String = ""
|
||||
Dim _User As User
|
||||
Dim _Contacts As Contacts
|
||||
Dim _onew As Xpo.XPObjectSpace = Application.CreateObjectSpace
|
||||
Dim _PartnerInfo As String = ""
|
||||
|
||||
_User = _onew.GetObject(TryCast(SecuritySystem.CurrentUser, User))
|
||||
|
||||
If _User IsNot Nothing Then
|
||||
_Contacts = _onew.FindObject(Of Contacts)(CriteriaOperator.Parse("User=?", _User))
|
||||
If _Contacts IsNot Nothing Then
|
||||
_PartnerInfo = _Contacts.Customers.FullName
|
||||
End If
|
||||
End If
|
||||
|
||||
_CustomAboutString = TryCast(SecuritySystem.CurrentUser, User).FullName & "<br>"
|
||||
If GLOBAL_Company_Info <> "" Then _CustomAboutString += "<b>" & GLOBAL_Company_Info & "</b><br><br>"
|
||||
If _PartnerInfo <> "" Then _CustomAboutString += "<b>" & _PartnerInfo & "</b><br><br>"
|
||||
_CustomAboutString += Application.Model.Application.Description & "<br>"
|
||||
_CustomAboutString += "Version: " & System.Reflection.Assembly.GetExecutingAssembly.GetName.Version.ToString & "<br>"
|
||||
_CustomAboutString += "Copyright (C) " & Application.Model.Copyright
|
||||
|
||||
Return _CustomAboutString
|
||||
End Function
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class DashboardViewerVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,98 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Editors
|
||||
Imports DevExpress.DashboardCommon
|
||||
Imports DevExpress.DataAccess
|
||||
Imports DevExpress.DataAccess.ConnectionParameters
|
||||
Imports DevExpress.DataAccess.Sql
|
||||
|
||||
Public Class DashboardViewerVC
|
||||
Inherits DevExpress.ExpressApp.ViewController
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
|
||||
If View.Id = "Dashboard_DetailView" Then
|
||||
Dim _Dashboard As Dashboard = TryCast(View.SelectedObjects(0), Dashboard)
|
||||
Dim _DetailView As DetailView = TryCast(View, DetailView)
|
||||
Dim _DashboardViewer_ViewItem As ViewItem = _DetailView.FindItem("DashboardViewer")
|
||||
If _DashboardViewer_ViewItem IsNot Nothing Then
|
||||
AddHandler _DashboardViewer_ViewItem.ControlCreated, AddressOf _DashboardViewer_ViewItem_ControlCreated
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
Private Sub _DashboardViewer_ViewItem_ControlCreated(sender As Object, e As EventArgs)
|
||||
Dim _DashboardViewerPropertyEditor As DashboardViewerPropertyEditor = TryCast(sender, DashboardViewerPropertyEditor)
|
||||
If _DashboardViewerPropertyEditor IsNot Nothing Then
|
||||
|
||||
AddHandler _DashboardViewerPropertyEditor.ASPxDashboardViewer.ConfigureDataConnection, AddressOf _DashboardViewerPropertyEditor_ASPxDashboardViewer_ConfigureDataConnection
|
||||
'AddHandler _DashboardViewerPropertyEditor.ASPxDashboardViewer.PreRender, AddressOf _DashboardViewerPropertyEditor_ASPxDashboardViewer_PreRender
|
||||
|
||||
Dim _Dashboard As Dashboard = TryCast(View.SelectedObjects(0), Dashboard)
|
||||
|
||||
Dim _FileName As String = System.IO.Path.Combine(System.IO.Path.GetTempPath(), System.IO.Path.GetTempPath, _Dashboard.XMLFileData.FileName)
|
||||
Dim _StreamFile As System.IO.Stream = New System.IO.FileStream(_FileName, System.IO.FileMode.Create, System.IO.FileAccess.Write)
|
||||
_Dashboard.XMLFileData.SaveToStream(_StreamFile)
|
||||
_StreamFile.Close()
|
||||
|
||||
With _DashboardViewerPropertyEditor.ASPxDashboardViewer
|
||||
.DashboardXmlFile = _FileName
|
||||
.Width = 800
|
||||
.Height = 600
|
||||
End With
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub _DashboardViewerPropertyEditor_ASPxDashboardViewer_ConfigureDataConnection(sender As Object, e As ConfigureDataConnectionEventArgs)
|
||||
Dim _Dashboard As Dashboard = TryCast(View.SelectedObjects(0), Dashboard)
|
||||
If _Dashboard IsNot Nothing Then
|
||||
Select Case _Dashboard.SQLType.ToString
|
||||
Case "MSSQL"
|
||||
Dim _MsSqlConnectionParameters As New MsSqlConnectionParameters
|
||||
_MsSqlConnectionParameters.UserName = _Dashboard.UserName
|
||||
_MsSqlConnectionParameters.Password = _Dashboard.Password
|
||||
_MsSqlConnectionParameters.DatabaseName = _Dashboard.Database
|
||||
_MsSqlConnectionParameters.ServerName = _Dashboard.SQLServer
|
||||
|
||||
e.ConnectionParameters = _MsSqlConnectionParameters
|
||||
Case "MySQL"
|
||||
Dim _MySqlConnectionParameters As New MySqlConnectionParameters
|
||||
_MySqlConnectionParameters.UserName = _Dashboard.UserName
|
||||
_MySqlConnectionParameters.Password = _Dashboard.Password
|
||||
_MySqlConnectionParameters.DatabaseName = _Dashboard.Database
|
||||
_MySqlConnectionParameters.ServerName = _Dashboard.SQLServer
|
||||
|
||||
e.ConnectionParameters = _MySqlConnectionParameters
|
||||
Case "PostgerSQL"
|
||||
Dim _PostgreSqlConnectionParameters As New PostgreSqlConnectionParameters
|
||||
_PostgreSqlConnectionParameters.UserName = _Dashboard.UserName
|
||||
_PostgreSqlConnectionParameters.Password = _Dashboard.Password
|
||||
_PostgreSqlConnectionParameters.DatabaseName = _Dashboard.Database
|
||||
_PostgreSqlConnectionParameters.ServerName = _Dashboard.SQLServer
|
||||
|
||||
e.ConnectionParameters = _PostgreSqlConnectionParameters
|
||||
End Select
|
||||
End If
|
||||
End Sub
|
||||
Private Sub _DashboardViewerPropertyEditor_ASPxDashboardViewer_PreRender(sender As Object, e As EventArgs)
|
||||
'Beep()
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class HTMLEditorVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,52 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.Web.ASPxHtmlEditor
|
||||
Imports DevExpress.ExpressApp.HtmlPropertyEditor.Web
|
||||
Imports System.Web.UI.WebControls
|
||||
Imports System.Web.UI
|
||||
Imports DevExpress.ExpressApp.Editors
|
||||
|
||||
Public Class HTMLEditorVC
|
||||
Inherits DevExpress.ExpressApp.ViewController(Of DetailView)
|
||||
Private htmlEditors As ArrayList
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
htmlEditors = New ArrayList
|
||||
htmlEditors.Clear()
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnViewControlsCreated()
|
||||
MyBase.OnViewControlsCreated()
|
||||
Dim editor As ASPxHtmlPropertyEditor
|
||||
Dim htmlEditor As ASPxHtmlEditor
|
||||
If View.ViewEditMode = Editors.ViewEditMode.Edit Then
|
||||
For Each editor In View.GetItems(Of ASPxHtmlPropertyEditor)()
|
||||
If TryCast(editor.Control, Table) IsNot Nothing Then
|
||||
htmlEditor = TryCast(editor.Control, Table).Rows(0).Cells(1).Controls(0)
|
||||
If htmlEditor IsNot Nothing Then
|
||||
htmlEditors.Add(htmlEditor)
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
AddHandler TryCast(View.Control, Control).PreRender, AddressOf ChangeHtmlEditorWidthController_PreRender
|
||||
End If
|
||||
End Sub
|
||||
Sub ChangeHtmlEditorWidthController_PreRender(sender As Object, e As EventArgs)
|
||||
Dim htmlEditor As ASPxHtmlEditor
|
||||
|
||||
For Each htmlEditor In htmlEditors
|
||||
htmlEditor.Width = Unit.Percentage(100)
|
||||
Next
|
||||
htmlEditors.Clear()
|
||||
End Sub
|
||||
End Class
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class ListViewProcessVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,43 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Web.SystemModule
|
||||
Imports DevExpress.ExpressApp.SystemModule
|
||||
|
||||
Public Class ListViewProcessVC
|
||||
Inherits DevExpress.ExpressApp.ViewController(Of ListView)
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
If CType(View.Model, IModelListViewAllowSort).IsListViewProcess Then
|
||||
Else
|
||||
Frame.GetController(Of ListViewController).EditAction.Active.SetItemValue("", False)
|
||||
Frame.GetController(Of ListViewProcessCurrentObjectController).Active.SetItemValue("", False)
|
||||
'Frame.GetController(Of ListViewController).InlineEditAction.Active.SetItemValue("", False)
|
||||
|
||||
End If
|
||||
End Sub
|
||||
Protected Overrides Sub OnDeactivated()
|
||||
MyBase.OnDeactivated()
|
||||
If CType(View.Model, IModelListViewAllowSort).IsListViewProcess Then
|
||||
Else
|
||||
Frame.GetController(Of ListViewController).EditAction.Active.SetItemValue("", True)
|
||||
Frame.GetController(Of ListViewProcessCurrentObjectController).Active.SetItemValue("", True)
|
||||
'Frame.GetController(Of ListViewController).InlineEditAction.Active.SetItemValue("", False)
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
Partial Class LogonWC
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,45 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
Imports Microsoft.VisualBasic
|
||||
Imports System.Web
|
||||
Imports System.Web.Security
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Web
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
|
||||
Public Class LogonWC
|
||||
Inherits DevExpress.ExpressApp.WindowController
|
||||
Public NuvolarAction As SingleChoiceAction
|
||||
Public Const DBName As String = "Gatya; Zokni"
|
||||
Public Sub New()
|
||||
Me.TargetWindowType = WindowType.Main
|
||||
|
||||
'If WebApplication.OldStyleLayout Then
|
||||
' NuvolarAction = New SingleChoiceAction(Me, "Nuvolar", "Tools")
|
||||
'Else
|
||||
' NuvolarAction = New SingleChoiceAction(Me, "Nuvolar", "Security")
|
||||
'End If
|
||||
'For Each databaseName As String In DBName.Split(";"c)
|
||||
' NuvolarAction.Items.Add(New ChoiceActionItem(databaseName, databaseName))
|
||||
'Next databaseName
|
||||
'AddHandler NuvolarAction.Execute, AddressOf NuvolarAction_Execute
|
||||
End Sub
|
||||
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
'For Each item As ChoiceActionItem In NuvolarAction.Items
|
||||
' If Application.ConnectionString.Contains(CStr(item.Data)) Then
|
||||
' NuvolarAction.SelectedItem = item
|
||||
' Exit For
|
||||
' End If
|
||||
'Next item
|
||||
End Sub
|
||||
Private Sub NuvolarAction_Execute(ByVal sender As Object, ByVal e As SingleChoiceActionExecuteEventArgs)
|
||||
'WebApplication.Redirect(FormsAuthentication.DefaultUrl & "?" & DBName & "=" & CStr(e.SelectedChoiceActionItem.Data))
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class OpenObjectController
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,64 @@
|
||||
Imports Microsoft.VisualBasic
|
||||
Imports System
|
||||
Imports System.Linq
|
||||
Imports System.Text
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.Data.Filtering
|
||||
Imports System.Collections.Generic
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Utils
|
||||
Imports DevExpress.ExpressApp.Layout
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.ExpressApp.Editors
|
||||
Imports DevExpress.ExpressApp.Templates
|
||||
Imports DevExpress.Persistent.Validation
|
||||
Imports DevExpress.ExpressApp.SystemModule
|
||||
Imports DevExpress.ExpressApp.Model.NodeGenerators
|
||||
Imports DevExpress.Web
|
||||
Imports DevExpress.ExpressApp.Web.Editors.ASPx
|
||||
|
||||
' For more typical usage scenarios, be sure to check out http://documentation.devexpress.com/#Xaf/clsDevExpressExpressAppViewControllertopic.
|
||||
Partial Public Class OpenObjectController
|
||||
Inherits ViewController(Of ListView)
|
||||
Public Sub New()
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
' Target required Views (via the TargetXXX properties) and create their Actions.
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
AddHandler View.ControlsCreated, AddressOf View_Controlcreated
|
||||
End Sub
|
||||
Protected Overrides Sub OnViewControlsCreated()
|
||||
MyBase.OnViewControlsCreated()
|
||||
' Access and customize the target View control.
|
||||
End Sub
|
||||
Protected Overrides Sub OnDeactivated()
|
||||
RemoveHandler View.ControlsCreated, AddressOf View_Controlcreated
|
||||
MyBase.OnDeactivated()
|
||||
End Sub
|
||||
|
||||
Private Sub View_Controlcreated(sender As Object, e As EventArgs)
|
||||
Dim _ASPxGridListEditor As ASPxGridListEditor = TryCast(View.Editor, ASPxGridListEditor)
|
||||
If _ASPxGridListEditor IsNot Nothing Then
|
||||
|
||||
AddHandler _ASPxGridListEditor.CustomCreateCellControl, AddressOf CCC
|
||||
|
||||
Dim _ASXGridView As ASPxGridView = TryCast(_ASPxGridListEditor.Grid, ASPxGridView)
|
||||
If _ASXGridView IsNot Nothing Then
|
||||
'AddHandler _ASXGridView.
|
||||
|
||||
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub GridView_PreRender(sender As Object, e As EventArgs)
|
||||
Beep()
|
||||
End Sub
|
||||
|
||||
Private Sub CCC(sender As Object, e As DevExpress.ExpressApp.Web.Editors.CustomCreateCellControlEventArgs)
|
||||
Beep()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class QuickCreateVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,28 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
|
||||
|
||||
Public Class QuickCreateVC
|
||||
Inherits DevExpress.ExpressApp.ViewController
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
Frame.GetController(Of DevExpress.ExpressApp.Web.SystemModule.WebNewObjectViewController).QuickCreateAction.Active.SetItemValue("", False)
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
Partial Class ResetSettingsVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
Me.components = New System.ComponentModel.Container()
|
||||
Me.aResetView = New DevExpress.ExpressApp.Actions.SimpleAction(Me.components)
|
||||
'
|
||||
'aResetView
|
||||
'
|
||||
Me.aResetView.Caption = "aReset View"
|
||||
Me.aResetView.Category = "View"
|
||||
Me.aResetView.ConfirmationMessage = "Do you want to reset ListView ?"
|
||||
Me.aResetView.Id = "aResetView"
|
||||
Me.aResetView.ImageName = Nothing
|
||||
Me.aResetView.Shortcut = Nothing
|
||||
Me.aResetView.Tag = Nothing
|
||||
Me.aResetView.TargetObjectsCriteria = Nothing
|
||||
Me.aResetView.TargetViewId = Nothing
|
||||
Me.aResetView.TargetViewType = DevExpress.ExpressApp.ViewType.ListView
|
||||
Me.aResetView.ToolTip = Nothing
|
||||
Me.aResetView.TypeOfView = GetType(DevExpress.ExpressApp.ListView)
|
||||
|
||||
End Sub
|
||||
Friend WithEvents aResetView As DevExpress.ExpressApp.Actions.SimpleAction
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,126 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="aResetView.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="$this.TrayLargeIcon" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>False</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -0,0 +1,54 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Model.Core
|
||||
Imports DevExpress.ExpressApp.Model
|
||||
Imports DevExpress.ExpressApp.Web.Editors.ASPx
|
||||
Imports DevExpress.Web.ASPxGridView
|
||||
Imports DevExpress.ExpressApp.SystemModule
|
||||
Imports DevExpress.Web.ASPxEditors
|
||||
|
||||
Public Class ResetSettingsVC
|
||||
Inherits DevExpress.ExpressApp.ViewController(Of ListView)
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
GLOBAL_ListViewReset = False
|
||||
'// IDEIGLENES TILTÁS !
|
||||
'Frame.GetController(Of ResetSettingsVC).aResetView.Active.SetItemValue("", False)
|
||||
End Sub
|
||||
|
||||
Private Sub aResetView_Execute(sender As System.Object, e As DevExpress.ExpressApp.Actions.SimpleActionExecuteEventArgs) Handles aResetView.Execute
|
||||
GLOBAL_ListViewReset = True
|
||||
|
||||
Dim oldModel As IModelView = View.Model
|
||||
|
||||
AddHandler View.ModelSaving, AddressOf View_ModelSaving
|
||||
Application.MainWindow.SetView(Nothing)
|
||||
CType(oldModel, ModelNode).Undo()
|
||||
Application.MainWindow.SetView(Nothing)
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub View_ModelSaving(sender As Object, e As CancelEventArgs)
|
||||
|
||||
e.Cancel = True
|
||||
End Sub
|
||||
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class ViewModeEditVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,30 @@
|
||||
Imports System
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.Generic
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Editors
|
||||
|
||||
Public Class ViewModeEditVC
|
||||
Inherits DevExpress.ExpressApp.ViewController(Of DetailView)
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
Dim fView As DetailView = TryCast(View, DetailView)
|
||||
If (Not fView Is Nothing) Then
|
||||
fView.ViewEditMode = ViewEditMode.Edit
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
@@ -0,0 +1,33 @@
|
||||
Imports DevExpress.ExpressApp.Web.Editors.ASPx
|
||||
Imports DevExpress.Web
|
||||
Imports DevExpress.Utils
|
||||
|
||||
Public Class WebAllowSortListViewController
|
||||
Inherits AllowSortListViewController
|
||||
Protected Overrides Sub OnViewControlsCreated()
|
||||
MyBase.OnViewControlsCreated()
|
||||
UpdateAllowSort()
|
||||
End Sub
|
||||
Protected Overrides Sub UpdateAllowSort()
|
||||
'Dim gridListEditor As ASPxGridListEditor = TryCast(View.Editor, ASPxGridListEditor)
|
||||
'If gridListEditor IsNot Nothing Then
|
||||
' Dim allowSortListView As Boolean = GetAllowSortListView()
|
||||
' gridListEditor.Grid.SettingsBehavior.AllowSort = allowSortListView
|
||||
' If allowSortListView Then
|
||||
' For Each column As GridViewColumn In gridListEditor.Grid.Columns
|
||||
' Dim dataColumn As GridViewDataColumn = TryCast(column, GridViewDataColumn)
|
||||
' If dataColumn IsNot Nothing Then
|
||||
' If GetAllowSortColumn(dataColumn) Then
|
||||
' dataColumn.Settings.AllowSort = DefaultBoolean.True
|
||||
' Else
|
||||
' dataColumn.Settings.AllowSort = DefaultBoolean.False
|
||||
' End If
|
||||
|
||||
' End If
|
||||
' Next column
|
||||
' End If
|
||||
'End If
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
Partial Class WebGroupFooterViewController
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -0,0 +1,54 @@
|
||||
Imports Microsoft.VisualBasic
|
||||
Imports System
|
||||
Imports DevExpress.Data
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Model
|
||||
Imports DevExpress.ExpressApp.Web.Editors.ASPx
|
||||
Imports DevExpress.Web
|
||||
|
||||
Public Class WebGroupFooterViewController
|
||||
Inherits ViewController(Of ListView)
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnViewControlsCreated()
|
||||
MyBase.OnViewControlsCreated()
|
||||
Dim displayFormat As String = ""
|
||||
Dim modelListView As IModelListViewExtender = TryCast(View.Model, IModelListViewExtender)
|
||||
If modelListView IsNot Nothing AndAlso modelListView.IsGroupFooterVisible Then
|
||||
Dim gridListEditor As ASPxGridListEditor = TryCast(View.Editor, ASPxGridListEditor)
|
||||
If gridListEditor IsNot Nothing Then
|
||||
Dim gridView As ASPxGridView = gridListEditor.Grid
|
||||
gridView.Settings.ShowGroupFooter = GridViewGroupFooterMode.VisibleAlways
|
||||
For Each modelColumn As IModelColumn In View.Model.Columns
|
||||
Dim modelColumnExtender As IModelColumnExtender = TryCast(modelColumn, IModelColumnExtender)
|
||||
If modelColumnExtender IsNot Nothing AndAlso modelColumnExtender.GroupFooterSummaryType <> SummaryItemType.None Then
|
||||
Dim fieldName As String = modelColumn.ModelMember.MemberInfo.BindingName
|
||||
Dim summaryItem As ASPxSummaryItem = Nothing
|
||||
For Each currentItem As ASPxSummaryItem In gridView.GroupSummary
|
||||
If currentItem.FieldName = fieldName Then
|
||||
currentItem.ShowInGroupFooterColumn = modelColumn.Caption
|
||||
summaryItem = currentItem
|
||||
Exit For
|
||||
End If
|
||||
Next currentItem
|
||||
If summaryItem Is Nothing Then
|
||||
summaryItem = New ASPxSummaryItem(fieldName, modelColumnExtender.GroupFooterSummaryType)
|
||||
summaryItem.ShowInGroupFooterColumn = modelColumn.Caption
|
||||
summaryItem.DisplayFormat = modelColumn.DisplayFormat
|
||||
gridView.GroupSummary.Add(summaryItem)
|
||||
End If
|
||||
End If
|
||||
Next modelColumn
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user