Results 1 to 2 of 2
  1. #1
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Summ +30 to a strng (2000 sr -1)

    I hav yhis line of code: TEST_CB = Sheets("ISTANTANEA").Range("A" + RIGA) and actually TEST_CB is CB45062, 1 how to summ +30 to this string and have CB450651...
    But use this type of summ only if the last 2 caracter of string finish for 21
    In effext :
    If TEST_CB = CBxxxx21 then summ +30 else nothing...

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Summ +30 to a strng (2000 sr -1)

    If TEST_CB Like "CB*21" Then
    TEST_CB = "CB" & (Val(Mid(TEST_CB, 3)) + 30)
    End If

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •