Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 3 of 3

Thread: iban validation

  1. #1
    Junior Member
    Join Date
    Nov 2013
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default iban validation

    Hi,
    I was looking for a java method to validate belgian iban number using the following algorithm:
    -Check that the total IBAN length is 16. If not, the IBAN is invalid
    -Move the four initial characters to the end of the string
    Replace each letter in the string with two digits, thereby expanding the string, where A = 10, B = 11, ..., Z = 35
    -Interpret the string as a decimal integer and compute the remainder of that number on division by 97
    -If the remainder is 1, the check digit test is passed and the IBAN might be valid.

    also there should be some general checks as the string is valid, only contains letters and digits and no special characters.. etc

    i am not able to figure out how to move initial four characters to the end replace letters in string as mentioned above..
    Kindly help..


    Thanks
    Regards


  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,042
    Thanks
    63
    Thanked 2,708 Times in 2,658 Posts

    Default Re: iban validation

    If you don't understand my answer, don't ignore it, ask a question.

  3. #3
    Grand Poobah
    Join Date
    Mar 2011
    Posts
    1,545
    My Mood
    Grumpy
    Thanks
    0
    Thanked 167 Times in 158 Posts

    Default Re: iban validation

    Quote Originally Posted by samaira View Post
    i am not able to figure out how to move initial four characters to the end replace letters in string as mentioned above..
    Split the String into 2 substrings. Concatenate them back together.
    Improving the world one idiot at a time!

Similar Threads

  1. Validation
    By Dipali86 in forum Other Programming Languages
    Replies: 1
    Last Post: October 29th, 2012, 11:25 AM
  2. Validation for SpecialCharacter
    By surendran610 in forum JavaServer Pages: JSP & JSTL
    Replies: 1
    Last Post: August 29th, 2011, 03:00 PM
  3. Help With Validation
    By bengregg in forum Loops & Control Statements
    Replies: 4
    Last Post: February 1st, 2011, 04:24 AM
  4. Jtextfield Validation
    By nimishalex in forum AWT / Java Swing
    Replies: 8
    Last Post: December 11th, 2010, 02:42 AM
  5. Problems with If validation
    By websey in forum Loops & Control Statements
    Replies: 1
    Last Post: November 18th, 2009, 09:43 AM