<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Ascii value in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316519#M1393636</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __jive_macro_name="thread" id="1168564"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 12 Nov 2009 13:42:14 GMT</pubDate>
    <dc:creator>kesavadas_thekkillath</dc:creator>
    <dc:date>2009-11-12T13:42:14Z</dc:date>
    <item>
      <title>Ascii value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316518#M1393635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gurus,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've a small requirement. I need to implement alogic where if the last digit of an order is 'a' then I have to change it as 'b'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;similarly if it is 'b' then we have to change it to 'c'. similarly I need to repeat this logic to all alphabets.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so if there would be any FM or logic to extract a number(like ascii value) for a particular character. Then I shall increment the value and convert back to alphabet and that is how I will change one alphabet to another.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly let me know if there is any FM to convert a character into a number.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Natasha.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Nov 2009 13:36:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316518#M1393635</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-11-12T13:36:30Z</dc:date>
    </item>
    <item>
      <title>Re: Ascii value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316519#M1393636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __jive_macro_name="thread" id="1168564"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Nov 2009 13:42:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316519#M1393636</guid>
      <dc:creator>kesavadas_thekkillath</dc:creator>
      <dc:date>2009-11-12T13:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: Ascii value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316520#M1393637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;U can use something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;PARAMETERS: P_CHAR(1) TYPE C.

DATA: MY_CHAR   TYPE I,
      NEXT_CHAR TYPE I.

IF SY-ABCDE CS P_CHAR.
  MY_CHAR   = SY-FDPOS + 1.
  NEXT_CHAR = MY_CHAR + 1.

  WRITE: 'Next char:', SY-ABCDE+MY_CHAR(1), NEXT_CHAR.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Nov 2009 13:48:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316520#M1393637</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-11-12T13:48:52Z</dc:date>
    </item>
    <item>
      <title>Re: Ascii value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316521#M1393638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use of SY-FDPOS, SY-ABCDE is definitely the simplest solution for getting the next letter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But was thinking of a solution taking into account the ASCII value of the character, it goes something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;PARAMETER:
V_STR TYPE CHAR1 DEFAULT 'A'.

DATA:
V_ASCII TYPE I.

TRY.
    CALL METHOD CL_ABAP_CONV_OUT_CE=&amp;gt;UCCPI
      EXPORTING
        CHAR = V_STR
      RECEIVING
        UCCP = V_ASCII.
  CATCH CX_SY_CODEPAGE_CONVERTER_INIT .
  CATCH CX_SY_CONVERSION_CODEPAGE .
  CATCH CX_PARAMETER_INVALID_RANGE .
ENDTRY.

WRITE: 'Input', 10 V_STR.

ADD 1 TO V_ASCII.

TRY.
    CALL METHOD CL_ABAP_CONV_IN_CE=&amp;gt;UCCPI
      EXPORTING
        UCCP = V_ASCII
      RECEIVING
        CHAR = V_STR.
  CATCH CX_SY_CONVERSION_CODEPAGE .
  CATCH CX_PARAMETER_INVALID_RANGE .
  CATCH CX_SY_CODEPAGE_CONVERTER_INIT .
ENDTRY.

WRITE: / 'Output', 10 V_STR.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;May be this is of some help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Suhas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Nov 2009 14:11:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316521#M1393638</guid>
      <dc:creator>SuhaSaha</dc:creator>
      <dc:date>2009-11-12T14:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: Ascii value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316522#M1393639</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __default_attr="blue" __jive_macro_name="color"&gt;Hi Natasha, 
&amp;lt;li&amp;gt;Try this way.
&lt;PRE&gt;&lt;CODE&gt;
REPORT zvenkat_notepad4.
DATA: g_position    TYPE i,
      g_next_letter TYPE c.
PARAMETERS p_given type char10 default '100000108k'.

START-OF-SELECTION.
  IF p_given+9(1) = 'Z'.
    WRITE 'A'.
  ELSE.
    FIND p_given+9(1) IN sy-abcde IGNORING CASE MATCH OFFSET g_position.
    g_position = g_position  + 1.
    g_next_letter = sy-abcde+g_position(1).
    WRITE / g_next_letter.
  ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;
Thanks
Venkat.O&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Nov 2009 03:14:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ascii-value/m-p/6316522#M1393639</guid>
      <dc:creator>venkat_o</dc:creator>
      <dc:date>2009-11-13T03:14:28Z</dc:date>
    </item>
  </channel>
</rss>

