Hi guys,

I'm a QT programmer, now I need to enable users to specify a name for an object in my program. There's a rule that the name can only contain several characters, and if user inputs an invalid character, I want to pop up a dialog to indicate the error, like Windows does (see the attached image). I have implemented a sub-class deriving from QRegExpValidator, and can successfully obtain the signal when it fails to validate. But how can I implement a dialog like this? Anyone has any idea about this?

Thanks in advance.InvalidFileName.png