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 FileAttachementsVC 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 = "C3CGeneratedInvoice_DocumentFile_ListView" Or View.Id = "OfferAskIn_OfferAskInDocuments_ListView" Or View.Id = "OfferAskOut_OfferAskOutDocuments_ListView" Or View.Id = "OfferAnswerIn_OfferAnswerInDocuments_ListView" Or View.Id = "Products_ProductsDocumentations_ListView" Or View.Id = "Customers_CustomersFileAttachment_ListView" Or View.Id = "OfferAnswerOut_OfferAnswerOutDocuments_ListView" Then Else Frame.GetController(Of DevExpress.ExpressApp.FileAttachments.Win.FileAttachmentListViewController).AddFromFileAction.Active.SetItemValue("", False) End If End Sub Protected Overrides Sub OnDeactivated() MyBase.OnDeactivated() Frame.GetController(Of DevExpress.ExpressApp.FileAttachments.Win.FileAttachmentListViewController).AddFromFileAction.Active.SetItemValue("", True) End Sub End Class