I have this line of Code, which i am having problems with.
name = (JOptionPane.showInputDialog("What is the name of the new Client? \n (Format) \" Jake Michael Drewberg\" "));
nameCheck= JOptionPane.showInputDialog("Please check that this is correct: "+name+". \n If this is correct please enter \"true\". if not enter \"false\". ");
i Get the error of incompatible types because I have the String inside the nameCheck line which is a boolean, but i just want the name entered in "name" to appear in the text of nameCheck for the user to check that what they have entered is actually correct.
But i don't know how to incorporate the name enter in the boolean Dialog window so that they can type true if the name is correct or false if it is not correct which will then take them to the line
if (nameCheck==false)
{
name = JOptionPanel.showInputDialog("Please enter the full name of the Client with the first letter of each name in Capital letters. ");
System.out.println("This is the final name being saved to our files, if any further issue present themselves please reffer to our Admin staff at [email protected]; \n Client Name: "+name);
}
so that they can Retype the name they want saved if they made a mistake in the beginning.
but i still sit with the problem of "error: incompatible types: String cannot be converted to boolean"