Results 1 to 2 of 2

Thread: I need help with coding this function on VBA

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    VBAX Newbie
    May 2021

    Exclamation I need help with coding this function on VBA

    1. Write a Public Function named “Reverse” that returns an array with four items (the output will be a row vector with four items) – (1) reverse string so that the last letter will be the first (for instance “school” => "loohcs"), (2) the length of the string, (3) the number of numeric charters and (4) the number of special characters (non-alphabetic and non-numeric). The user can decidewhetherthefirstletterofthereversestringwillbecapitalornot.The function should take two arguments: (1) a string to be converted and (2) a (Boolean) parameter that indicates whether the first letter should be capital (true) or not (false). All other letter should not be capital. Please note that it should be programmed as a function and not subroutine!!!

  2. #2
    Moderator VBAX Sage SamT's Avatar
    Oct 2006
    Near Columbia
    for i = Len() to 1 step -1
    and the Mid function
    I expect the student to do their homework and find all the errrors I leeve in.

    Please take the time to read the Forum FAQ

Posting Permissions

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