How to show a * (asterisk) in Application Title when document has changed and is not saved

StackOverflow https://stackoverflow.com/questions/1762412

  •  21-09-2019
  •  | 
  •  

문제

I have a MDI Application with one MDI child.

When a user changes a Textbox on the MDI child, the MDI child (= document) is changed and is not saved. I want this to be visible in the Titlebar of the Application, like this:

ApplicationName [DocumentName*]

When the users saves the Document and doesn't change anything after, it should display:

ApplicationName [DocumentName]

How can I achieve this?

도움이 되었습니까?

해결책

You need a "document modified" flag. Then in your code that pulls out the document name to display in the title you can check this and if the document has been modified append "*".

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top