Where the dialog is called/created:
private void displayMessageButtonMouseClicked(java.awt.event.MouseEvent evt) {
GenericDialog myDialog = new GenericDialog(this, true);
myDialog.changeLabel("Text to Display:");
myDialog.setVisible(true);
// would like to get the value of a text field here
String response = myClass.displayMessage(<<response from dialog should go here>>);
logTextArea.append(new java.util.Date().toString() + " :: displayMessage :: " + response + '\n');
}
Where the dialog is closed/disposed:
private void okButtonActionPerformed(java.awt.event.ActionEvent evt) {
this.dispose();
}
What should be added to either of those methods to return the value of a text field in the dialog?