Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: .bat that translates custom code to words  (Read 8488 times)

0 Members and 1 Guest are viewing this topic.

millergram

    Topic Starter


    Rookie

    • Experience: Beginner
    • OS: Windows Vista
    .bat that translates custom code to words
    « on: February 11, 2011, 04:25:35 AM »
    I would like to know how to make a batch that converts a custom code of numbers like "486739" into letters like "Hello"
    can this be done?

    polle123



      Rookie

      • Experience: Beginner
      • OS: Unknown
      Re: .bat that translates custom code to words
      « Reply #1 on: February 11, 2011, 08:19:33 AM »
      yes it can be done, please explain presisly what you want. You want 1=A, 2=B, or something like that?

      millergram

        Topic Starter


        Rookie

        • Experience: Beginner
        • OS: Windows Vista
        Re: .bat that translates custom code to words
        « Reply #2 on: February 11, 2011, 10:19:36 AM »
        Yes exctaly

        millergram

          Topic Starter


          Rookie

          • Experience: Beginner
          • OS: Windows Vista
          Re: .bat that translates custom code to words
          « Reply #3 on: February 11, 2011, 10:19:56 AM »
          Yep
          yes it can be done, please explain presisly what you want. You want 1=A, 2=B, or something like that?

          mat123



            Hopeful

            Thanked: 16
            • Yes
            • Yes
            • Yes
          • Experience: Familiar
          • OS: Windows XP
          Re: .bat that translates custom code to words
          « Reply #4 on: February 11, 2011, 11:46:21 AM »
          ah what do you want to use to separate the numbers because Z=26,B=2,and F=6 does 26=Z or 26=BF we dont know unless you separate the numbers.



          millergram

            Topic Starter


            Rookie

            • Experience: Beginner
            • OS: Windows Vista
            Re: .bat that translates custom code to words
            « Reply #5 on: February 11, 2011, 04:26:08 PM »
            first i have to know how to apply letters to nums and yes i well make it like 1=c 24=z 45=d and so on or with num first idk how it goes

            Salmon Trout

            • Guest
            Re: .bat that translates custom code to words
            « Reply #6 on: February 11, 2011, 04:58:40 PM »

            Salmon Trout

            • Guest
            Re: .bat that translates custom code to words
            « Reply #7 on: February 11, 2011, 05:00:50 PM »
            Quote
            "486739" into letters like "Hello"

            Why has 486739 got 6 figures and hello only 5 letters?



            Salmon Trout

            • Guest
            Re: .bat that translates custom code to words
            « Reply #8 on: February 11, 2011, 05:02:46 PM »
            yes it can be done

            Interested to see your demo code

            millergram

              Topic Starter


              Rookie

              • Experience: Beginner
              • OS: Windows Vista
              Re: .bat that translates custom code to words
              « Reply #9 on: February 11, 2011, 05:25:38 PM »
              486739 that was just off the top of my head but i guess if would be somtin like this
              48=h
              6=e
              7=l
              3=l
              9=o

              Even thou that not the right format

              millergram

                Topic Starter


                Rookie

                • Experience: Beginner
                • OS: Windows Vista
                Re: .bat that translates custom code to words
                « Reply #10 on: February 11, 2011, 05:32:10 PM »
                Im a noob at this but heres what i got
                Code: [Select]
                @echo off
                set man=5
                :main
                if %man%==0 goto no
                cls
                echo.you have %man% tries left
                set /p Msn=Here:
                if "%msn%"=="jdhafj" goto no
                echo.Wrong
                goto yes

                :no
                echo.Error Code=Nm17*d
                pause

                :yes
                set /a man=%man%-1
                goto main
                This first one gives an error code when you guess wrong 5 times

                Code: [Select]
                @echo off
                set a=1
                set b=4
                set c=7
                set d=9
                set e=*d
                set f=Nm
                set g=jl
                set h=lj
                set i=90
                set l=45
                set p=89
                :main
                set /p do=Input code:
                if "%do%"=="%f%%a%%c%%e%" goto yes
                goto main

                :yes
                echo.Password=face
                pause
                cls
                goto main

                and the one above translates to the word face but i need the whole alphabet to be possible if you know what i mean
                « Last Edit: February 11, 2011, 06:03:59 PM by millergram »

                mat123



                  Hopeful

                  Thanked: 16
                  • Yes
                  • Yes
                  • Yes
                • Experience: Familiar
                • OS: Windows XP
                Re: .bat that translates custom code to words
                « Reply #11 on: February 12, 2011, 02:46:16 AM »
                are you turning letters into numbers or vica-verca



                millergram

                  Topic Starter


                  Rookie

                  • Experience: Beginner
                  • OS: Windows Vista
                  Re: .bat that translates custom code to words
                  « Reply #12 on: February 12, 2011, 03:39:33 AM »
                  vice versa

                  polle123



                    Rookie

                    • Experience: Beginner
                    • OS: Unknown
                    Re: .bat that translates custom code to words
                    « Reply #13 on: February 12, 2011, 03:46:35 AM »
                    Interested to see your demo code

                    How about a for loop that uses a space as a delimmiter and then makes 1=a, 2=b and so on.
                    It can't be done without spaces as this would indeed cause confusion where 26= z and at the same time 26= bf

                    millergram

                      Topic Starter


                      Rookie

                      • Experience: Beginner
                      • OS: Windows Vista
                      Re: .bat that translates custom code to words
                      « Reply #14 on: February 12, 2011, 04:01:28 AM »
                      idk how to use delimiters  at all