Results 1 to 2 of 2

Thread: If Button A is pressed then Button B is pressed it runs VBScript at Network Location

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 2013
    Posts
    9

    Question If Button A is pressed then Button B is pressed it runs VBScript at Network Location

    Morning All!

    Name:  queryform.jpg
Views: 616
Size:  19.6 KB

    I'm clutching at straws as to how to sort this out; I have a split container with navigation buttons on the left and number of panels that are then positioned into the right on the clicking of a navigation button.

    I can sort out the click events, but I have also assigned keydown events on each of the navigation buttons, for example;

    Code:
     
           'Key Response to pressing number 1 or numpad 1
            If e.KeyCode = Keys.D1 Or e.KeyCode = Keys.NumPad1 Then Project13_Panel.BringToFront()
            If e.KeyCode = Keys.D1 Or e.KeyCode = Keys.NumPad1 Then Project13Nav_Btn.Select()
            If e.KeyCode = Keys.D1 Or e.KeyCode = Keys.NumPad1 Then Project13_Panel.Location = New Point(280, 115)
            If e.KeyCode = Keys.D1 Or e.KeyCode = Keys.NumPad1 Then Project13_Panel.Visible = True


    My question is a two parter:

    Question 1 - Does anyone know how to reference the Launch(Enter) button on the right panel shown above in a keydown event to then launch a VBScript? I'm currently using a msgbox to test that it works.

    Question 2 - Does anyone know how to launch a VBScript from a .NET form? the VBScript is located in a network NETLOGON folder. I would prefer to stay away from integrating the script into the .NET application as we are intending to use it as a front end to log-in scripts.

    Thank you very much in advance!!

    Chris

  2. #2

    Thread Starter
    New Member
    Join Date
    Nov 2013
    Posts
    9

    Question Re: If Button A is pressed then Button B is pressed it runs VBScript at Network Locat

    or does anyone know how to use two types of keydown entries in a single statement? I'm using the following but it isn't working:

    Code:
    If e.KeyCode.D1 and e.KeyCode = Keys.Enter Then Archived_MsgBox.Show()
    I've looked at keycode.control and e.keycode = D1 etc but that doesn't do what I need. I'm looking for e.keycode.d1 (number 1) to then open the relevant panel and then when I press enter, the launch button on the relevant panel will launch the relevant script assigned to that button.

Tags for this Thread

Posting Permissions

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



Click Here to Expand Forum to Full Width