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. C#
  4. Opening our windows application by double clicking a file...

Opening our windows application by double clicking a file...

Scheduled Pinned Locked Moved C#
help
8 Posts 5 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
    jaypatel512
    wrote on last edited by
    #1

    Hey all... I came across a very basic problem .... Suppose I made a simple Notepad like editor... Now I want that whenever I double click on any presice extension file . .. i.e. .jpg or anything... It should open my application and the file should be opened .... It is somewhat like opening a word document by double clicking the .doc file ... This is exactly what I want in my application... Thanx in advance techies...

    G X 2 Replies Last reply
    0
    • J jaypatel512

      Hey all... I came across a very basic problem .... Suppose I made a simple Notepad like editor... Now I want that whenever I double click on any presice extension file . .. i.e. .jpg or anything... It should open my application and the file should be opened .... It is somewhat like opening a word document by double clicking the .doc file ... This is exactly what I want in my application... Thanx in advance techies...

      G Offline
      G Offline
      Giorgi Dalakishvili
      wrote on last edited by
      #2

      Here is an example: Registering the Extension[^]

      Giorgi Dalakishvili #region signature My Articles Asynchronous Registry Notification Using Strongly-typed WMI Classes in .NET [^] My blog #endregion

      J 1 Reply Last reply
      0
      • J jaypatel512

        Hey all... I came across a very basic problem .... Suppose I made a simple Notepad like editor... Now I want that whenever I double click on any presice extension file . .. i.e. .jpg or anything... It should open my application and the file should be opened .... It is somewhat like opening a word document by double clicking the .doc file ... This is exactly what I want in my application... Thanx in advance techies...

        X Offline
        X Offline
        Xmen Real
        wrote on last edited by
        #3

        you have to associate your application with that file type. 2 ways to do that 1. Just right click on any file of that type > open with > Choose Default Program > and browse your app and check 'Always use this pro....' 2. You can directly edit registry, read this article[^] plus when you done, you have catch the arguments that will give you that file path you open by double click. you can get through Main(string[] args) or Environment.CommandLineArgs

        TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L %^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2 W_AD`EPABIKRDFVS)EVLQK)JKQUFK[M`UKs*$GwU#QDXBER@CBN% R0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i’TV.C\y<pŠjxsg-b$f4ia>

        ----------------------------------------------- 128 bit encrypted signature, crack if you can

        J 1 Reply Last reply
        0
        • G Giorgi Dalakishvili

          Here is an example: Registering the Extension[^]

          Giorgi Dalakishvili #region signature My Articles Asynchronous Registry Notification Using Strongly-typed WMI Classes in .NET [^] My blog #endregion

          J Offline
          J Offline
          jaypatel512
          wrote on last edited by
          #4

          But after registering also.. Suppose it opened the application.. But how to load that file because of which it is opened... Did you understand the problem ..

          V 1 Reply Last reply
          0
          • X Xmen Real

            you have to associate your application with that file type. 2 ways to do that 1. Just right click on any file of that type > open with > Choose Default Program > and browse your app and check 'Always use this pro....' 2. You can directly edit registry, read this article[^] plus when you done, you have catch the arguments that will give you that file path you open by double click. you can get through Main(string[] args) or Environment.CommandLineArgs

            TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L %^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2 W_AD`EPABIKRDFVS)EVLQK)JKQUFK[M`UKs*$GwU#QDXBER@CBN% R0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i’TV.C\y<pŠjxsg-b$f4ia>

            ----------------------------------------------- 128 bit encrypted signature, crack if you can

            J Offline
            J Offline
            jaypatel512
            wrote on last edited by
            #5

            I think this might surely work . .. This was the thing that I want. . Thanks dude. .

            D 1 Reply Last reply
            0
            • J jaypatel512

              But after registering also.. Suppose it opened the application.. But how to load that file because of which it is opened... Did you understand the problem ..

              V Offline
              V Offline
              V 0
              wrote on last edited by
              #6

              If I'm not mistaken windows will automatically add the path of the file as an argument...

              V.
              Stop smoking so you can: Enjoy longer the money you save. Moviereview Archive

              1 Reply Last reply
              0
              • J jaypatel512

                I think this might surely work . .. This was the thing that I want. . Thanks dude. .

                D Offline
                D Offline
                dan sh
                wrote on last edited by
                #7

                jaypatel512 wrote:

                I think this might surely work .

                Think, might and surely. :omg:

                जय हिंद

                J 1 Reply Last reply
                0
                • D dan sh

                  jaypatel512 wrote:

                  I think this might surely work .

                  Think, might and surely. :omg:

                  जय हिंद

                  J Offline
                  J Offline
                  jaypatel512
                  wrote on last edited by
                  #8

                  It worked dude. .. Thanks a lot all of you . .. I really appreciated man . .

                  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