Handles clause requires a WithEvents variable defined in the containing type or one of its base types

前端 未结 8 2049
旧巷少年郎
旧巷少年郎 2021-01-04 03:15

I get the error

Handles clause requires a WithEvents variable defined in the containing type or one of its base types.

in the following co

8条回答
  •  死守一世寂寞
    2021-01-04 03:26

    I had encountered this issue when upgrading a legacy page. The problem is in the Inherits attribute @Page directive has the wrong namespace.

    1. Correct the namespace for Inherits attribute
    2. Remove the namespace in the designer file or match with it in the designer code

提交回复
热议问题