I would like to convert this string: req.getParameter("officecode" to integer.
Can I do it something like this:
officecode = toInteger( req.getParameter("officecode");
int officeCode = Integer.parseInt(req.getParameter("officecode");
Your above codes will not work unless you have a method toInteger that accepts a String as an input and returns a int value and within the method, you convert the String to an int value. Remember when you do something like abc(), this means that you are calling the method abc().
Regards,
Leon If you need additional help, you can email to me at zaoliang@hotmail.com I don't guaranty that I will be able to solve your problems but I will try my best
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.