Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. contextmenu when 2 files are selected

contextmenu when 2 files are selected

Scheduled Pinned Locked Moved Visual Basic
questionlinux
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    JR212
    wrote on last edited by
    #1

    Hi, i want to create an option when I click right on 2 files. I added the regkey in HKCU\Software\Classes\*\shell and command. but when I select my option it is executed twice. Once on file 1 and once on file 2. I want to run the command on the 2 files at once so that I can check that there are exactly 2 files selected as a parameter and than I can do my stuff with those files. How can I make windows run my command on the 2 files in 1 instance of my command? Jan

    L 1 Reply Last reply
    0
    • J JR212

      Hi, i want to create an option when I click right on 2 files. I added the regkey in HKCU\Software\Classes\*\shell and command. but when I select my option it is executed twice. Once on file 1 and once on file 2. I want to run the command on the 2 files at once so that I can check that there are exactly 2 files selected as a parameter and than I can do my stuff with those files. How can I make windows run my command on the 2 files in 1 instance of my command? Jan

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      It will now launch two instances, right? There's some articles here on preventing a second instance of your app, and how to send the starting-params to the first instance of the application, before exiting. That way the first instance of the app could receive the params for the second instance and do it's work, while the second instance exits.

      Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^] "If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.

      J 1 Reply Last reply
      0
      • L Lost User

        It will now launch two instances, right? There's some articles here on preventing a second instance of your app, and how to send the starting-params to the first instance of the application, before exiting. That way the first instance of the app could receive the params for the second instance and do it's work, while the second instance exits.

        Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^] "If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.

        J Offline
        J Offline
        JR212
        wrote on last edited by
        #3

        Unfortunately it's not an app :( but a vb-script. I try to converted it and work like you describe thanks I'll get back later; Maybe a lot later :) Jan

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups