mainMenu and SendKeys.Send("^c")

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • ucasesoftware

    #1

    mainMenu and SendKeys.Send("^c")

    In my mainMenu i have items Copy, cut, paste...

    I have a form with a lot of textbox

    In my sub of item copy i have : SendKeys.Send(" ^c")

    but if the user select a text in a textbox... click Copy in the
    mainMenu...
    it doesn't work

  • Ken Tucker [MVP]

    #2
    Re: mainMenu and SendKeys.Send(& quot;^c")

    Hi,

    Clipboard.SetDa taObject("This is a test", True)



    Ken

    ----------------------

    "ucasesoftw are" <ucasesoftware@ hotmail.fr> wrote in message
    news:1126301363 .012627.283510@ o13g2000cwo.goo glegroups.com.. .[color=blue]
    > In my mainMenu i have items Copy, cut, paste...
    >
    > I have a form with a lot of textbox
    >
    > In my sub of item copy i have : SendKeys.Send(" ^c")
    >
    > but if the user select a text in a textbox... click Copy in the
    > mainMenu...
    > it doesn't work
    >[/color]


    Comment

    • Ken Tucker [MVP]

      #3
      Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

      Hi,

      Clipboard.SetDa taObject("This is a test", True)



      Ken

      ----------------------

      "ucasesoftw are" <ucasesoftware@ hotmail.fr> wrote in message
      news:1126301363 .012627.283510@ o13g2000cwo.goo glegroups.com.. .[color=blue]
      > In my mainMenu i have items Copy, cut, paste...
      >
      > I have a form with a lot of textbox
      >
      > In my sub of item copy i have : SendKeys.Send(" ^c")
      >
      > but if the user select a text in a textbox... click Copy in the
      > mainMenu...
      > it doesn't work
      >[/color]


      Comment

      • ucasesoftware

        #4
        Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

        ???? i know this but i want to send CTRL C in main menu

        Comment

        • ucasesoftware

          #5
          Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

          ???? i know this but i want to send CTRL C in main menu

          Comment

          • Ken Tucker [MVP]

            #6
            Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

            Hi,

            I added a Copy menu item to the main menu and assigned a short
            cut key of control c to it. It worked as expected.

            mnuCopy.Shortcu t = Shortcut.CtrlC



            Ken

            -----------------------------

            "ucasesoftw are" <ucasesoftware@ hotmail.fr> wrote in message
            news:1126357569 .815139.322960@ o13g2000cwo.goo glegroups.com.. .[color=blue]
            > ???? i know this but i want to send CTRL C in main menu
            >[/color]


            Comment

            • Ken Tucker [MVP]

              #7
              Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

              Hi,

              I added a Copy menu item to the main menu and assigned a short
              cut key of control c to it. It worked as expected.

              mnuCopy.Shortcu t = Shortcut.CtrlC



              Ken

              -----------------------------

              "ucasesoftw are" <ucasesoftware@ hotmail.fr> wrote in message
              news:1126357569 .815139.322960@ o13g2000cwo.goo glegroups.com.. .[color=blue]
              > ???? i know this but i want to send CTRL C in main menu
              >[/color]


              Comment

              • ucasesoftware

                #8
                Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

                ken
                Private Sub mnItemCopier_Cl ick(ByVal sender As System.Object, ByVal
                e As System.EventArg s) Handles mnItemCopier.Cl ick
                mnItemCopier.Sh ortcut = Shortcut.CtrlC
                End Sub

                this is not enough to copy ! ?? you need a SendKeys.Send(" ^c") ??? no ?

                Comment

                • ucasesoftware

                  #9
                  Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

                  ken
                  Private Sub mnItemCopier_Cl ick(ByVal sender As System.Object, ByVal
                  e As System.EventArg s) Handles mnItemCopier.Cl ick
                  mnItemCopier.Sh ortcut = Shortcut.CtrlC
                  End Sub

                  this is not enough to copy ! ?? you need a SendKeys.Send(" ^c") ??? no ?

                  Comment

                  • Ken Tucker [MVP]

                    #10
                    Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

                    Hi,

                    You would need code in the menu items click event to copy the info
                    to the clipboard.

                    Ken
                    -------------------
                    "ucasesoftw are" <ucasesoftware@ hotmail.fr> wrote in message
                    news:1126465392 .734519.34230@o 13g2000cwo.goog legroups.com...[color=blue]
                    > ken
                    > Private Sub mnItemCopier_Cl ick(ByVal sender As System.Object, ByVal
                    > e As System.EventArg s) Handles mnItemCopier.Cl ick
                    > mnItemCopier.Sh ortcut = Shortcut.CtrlC
                    > End Sub
                    >
                    > this is not enough to copy ! ?? you need a SendKeys.Send(" ^c") ??? no ?
                    >[/color]


                    Comment

                    • Ken Tucker [MVP]

                      #11
                      Re: mainMenu and SendKeys.Send(& quot;^c&quot;)

                      Hi,

                      You would need code in the menu items click event to copy the info
                      to the clipboard.

                      Ken
                      -------------------
                      "ucasesoftw are" <ucasesoftware@ hotmail.fr> wrote in message
                      news:1126465392 .734519.34230@o 13g2000cwo.goog legroups.com...[color=blue]
                      > ken
                      > Private Sub mnItemCopier_Cl ick(ByVal sender As System.Object, ByVal
                      > e As System.EventArg s) Handles mnItemCopier.Cl ick
                      > mnItemCopier.Sh ortcut = Shortcut.CtrlC
                      > End Sub
                      >
                      > this is not enough to copy ! ?? you need a SendKeys.Send(" ^c") ??? no ?
                      >[/color]


                      Comment

                      Working...