I am settting up control propertis on page load. Like visiblilty of control depending on loaded data. And very simple setting up images to button controls. For page load it works fine but on postback these values are not set back. This is my code. When it’s a postback btnSecurityQA image is missing and visibility of all following controls is not set accordingly.
If Not IsPostBack Then
ButtonImage.SetPath(btnSecurityQA, GetLocalResourceObject(btnSecurityQA.ID & "BaseName").ToString())
' following control's visibility is set by the view interface
Dim accountsPresenter = New AccountsPresenter
accountsPresenter.SetAccountVisibility(Me, m_Account)
chkMoneyMarket.Visible = _moneyMarketVisible
lblRoutingNumber.Visible = _routingNumberVisible
txtRoutingNumber.Visible = _routingNumberVisible
lblSubType.Visible = _loanSubTypeVisible
cboLoanSubType.Visible = _loanSubTypeVisible
If Not IsNothing(m_Account) Then
If m_Account.Id <> Guid.Empty Then
Call PopulateLoanAccountSubTypes()
Call PopulateData()
End If
End If
End If