No announcement yet.

Button shortcut to pressing 2 keyboard keys

  • Filter
  • Time
  • Show
Clear All
new posts

  • Button shortcut to pressing 2 keyboard keys

    I am using an EEEPC as my carpc, and I want to be able to control the lcd gamma from a button on my skin, rather than having to press Fn+F6.
    How can I create a shortcut, such that when touching the button on the front end, will have the same result as pressing two keys on the actual keyboard.

    Thank you in advance.

  • #2
    Let me dig up some of my old stuff but you can write a small "VB Script" to mimic keyboard presses. You would map that Front End button to run the vb script achieving what you want. Just for clarification for myself, what is EEEPC?


    • #3
      Ok here is a small script that I wrote.

      Open Notepad in windows.

      Add the following:

      set objShell = WScript.CreateObject("WScript.Shell")
      objShell.SendKeys "]"

      Where the "]" in the second line is is where you put the key of your choice. Now I have not done multiple Key's before so some googling might be in order.

      But from what I understand, to do multiple keys, they need to be separated like this example:

      [HL]set objShell = WScript.CreateObject("WScript.Shell")
      objShell.SendKeys "{FN} {F6}"[/HL]


      set objShell = WScript.CreateObject("WScript.Shell")
      objShell.SendKeys "FN F6"

      I don't know if it will work for a combination but it's doable. If my examples don't work then there would just be a small issue with how to properly put combination commands. There is a whole "Command Guide" out ther eon google that I can't locate at the moment. I'd upload compiled scripts for you but this forum won't allow upload of extensions with .vbs

      Open notepad and copy the highlighted example to it. Save it as a VBS script.
      Example "Gamma.vbs", just add .vbs after whatever you name it. Then, double click it and it will run the script and hopefully your gamma will change every time you run it. If that doesn't work make another one with the later of the two examples. As far as getting RR to run with a button that's up to you. What skin are you using?

      For more help google "Windows Sendkeys"


      • #4
        WOW, thank you so much! I should be good from here with a little research. I'm using Shock Skin V5. I think there's also a tutorial for skinning that I can use for this.


        • #5
          Just as long as you can figure out how to skin a button to run that script. I know how to do it in DFX 4 skin, if it's anything close maybe we can figure something out. In the meantime, did simply running the script in windows work?


          • #6
            Is the code for FN {FN}?


            • #7
              I don't know to be honest. I haven't actually seen if FN or function works with send keys...I'll try it out on my laptop...


              • #8
                i think "FN" is hardware based only, i cut be wrong.
                BASSRR ==> [Audio Player/MusicDB/Cd Player/Ripper/Rate/Internet Radio/Audio Capture/Youtube Video]
                RRTube ==> [View/Download Youtube Videos]
                WifiMan ==> [Wifi Manager]
                RRec ==> [Audio Capture]

                If You Want To Be Given Everything, Give Everything Up ...
                Bird York -- In The Deep --


                • #9
                  Yeah I'm starting to wonder whether that would have been written into Visual Basic Scripting host...At worse we can find some sort of gamma control program that accpets different hotkeys.


                  • #10
                    Try this and play with it...

                    If you can map a hotkeys other than involving the standard hardware of using the function button and get gamma to change, then we are in business. Let me know.


                    • #11
                      Alright, that download sight was a no go...I have the prgram and it works perfectly for what you want, I wrote the vb scripts to provide gamma up and gamma down using F9, and F11..You can change these in the scripts by right clicking and hitting "Edit". It will open in notepad and you will see what you need to change if you do so. The Magic Key program is SIMPLE. Open it, and set Gamm up to the correlating key, and gamma down as well. Once set, when you doubble click either of the 2 scripts the gamma should go up and down with them. PM me your email and I will send you the Program along with the scripts. From here, you just need to code a button to activate the gamma up VB script and another for the gamma down. The hot key program can be set to start with windows and it runs in the tray. Perfect for use with rr.


                      • #12
                        Dougw133 you are a lifesaver. Thank you again! I will try it on my carpc as soon as I set it up in the car. It's been bench tested, and ghetto hooked up so far. I'm working on building the enclosure for the guts and then testing this.