Nelsons
Nelsons

Reputation: 47

data load from excel into datagridview

I am loading data into the datagridview from excel. The data is loaded correctly however the validation of the cells is not carried out. I have the validation code in the cell end edit event.

How can it be done?

Upvotes: 0

Views: 149

Answers (1)

D_Bester
D_Bester

Reputation: 5931

Just put the DataGridView into edit mode and then exit the edit mode. That should trigger the EndEdit event.

    DataGridView.BeginEdit(True)
    DataGridView.EndEdit()

Upvotes: 0

Related Questions