locked
How to add shortcut of my app to Start Menu (Windows Mobile 6) just after .cab Installation ? RRS feed

  • Question

  • Hi All,
      I have created Setup and deployment project for smart devices.
    For creating CAB file,
      In this project  i have given  shortcut  of .exe file to  Start Menu folder. So After installing the CAB on target device, It should create shortcut in Start Menu. But its not Creating Short cut just after installation for WM6. It creates shortcut in Recent Programs, only after I run my application first time by clicking on .exe.
           I know Folder \Windows\Start Menu\ has the limitation on the number of shortcuts it contains. If we force to put a shortcut in this folder, all the lnk file will be redirect to its subfolder Programs. I want it should create the short cut in Start Menu just after installation of .cab , so that user dont need to search the .exe to run it for first time?
     




    Thanks,
    Prashant
    Friday, May 16, 2008 11:36 AM

Answers

  • Hi Prashant,

    You just add a "Start Menu Folder" to smart device cab project, while installing cab to the device, it will add a shortcut in "\windows\Start Menu" folder.  But Start menu only contains fixed number items, if you want to add your own shortcut , It will be forced to copy to subfolder Programs , that's by design.

     

    So  you can remove existing item and add your own shortcut. It will not cut to subfolder.

     

    Best regards,

    Guang-Ming Bian - MSFT

    Monday, May 19, 2008 8:23 AM
  • Hi Prashant_611,

    For delete it programatically, you can use DeleteFile to delete it. The limitation number is 7. So far, there is no such way to achieve this without removing existing item.

     

    Thanks.

     

    Best regards,

    Guang-Ming Bian - MSFT

    Thursday, May 22, 2008 3:52 AM

All replies

  • Hi Prashant,

    You just add a "Start Menu Folder" to smart device cab project, while installing cab to the device, it will add a shortcut in "\windows\Start Menu" folder.  But Start menu only contains fixed number items, if you want to add your own shortcut , It will be forced to copy to subfolder Programs , that's by design.

     

    So  you can remove existing item and add your own shortcut. It will not cut to subfolder.

     

    Best regards,

    Guang-Ming Bian - MSFT

    Monday, May 19, 2008 8:23 AM
  • Thanks Guang-Ming Bian ,
     I tried it by deleting existing item it works, but how to delete existing item from "Start Menu Folder"
    programatically is there any API ? As
    Folder \Windows\Start Menu\ has the limitation on the number of shortcuts it contains, is this limit is 7 for all WM devices or its not a fix number ?
      And is there any other way by which i dont need to remove existing item in "Start Menu Folder" and also i will bw abel to put my app short cut in "Start Menu Folder".


    Thanks,
    Prashant
    Wednesday, May 21, 2008 6:03 AM
  • Hi Prashant_611,

    For delete it programatically, you can use DeleteFile to delete it. The limitation number is 7. So far, there is no such way to achieve this without removing existing item.

     

    Thanks.

     

    Best regards,

    Guang-Ming Bian - MSFT

    Thursday, May 22, 2008 3:52 AM
  • This does not work:

    I have called

    CeRapiInit



    Then call:

      if( !CeDeleteFile( _T(

    "Windows\\Start Menu\\Calendar.lnk") ) )
      {
        // something is wrong
      }


    Sunday, February 28, 2010 1:54 AM
  • You just add a "Start Menu Folder" to smart device cab project, while installing cab to the device, it will add a shortcut in "\windows\Start Menu" folder.  But Start menu only contains fixed number items, if you want to add your own shortcut , It will be forced to copy to subfolder Programs , that's by design.

    Could you please be more precise?

    I want to have a shortcut added to my application while instalation, but I don't know how it can be done.

    My app. main program is "yes_no.exe", and I want to have a shortcut added into Start/Program/YES_NO/yes_no.lnk or sth like this.

    As a workareound, I'm using different program (WinCE CAB Manager) to edit my cab and add a shortcut, but I suppose that it can be done in VS2008?

     

    Sunday, May 2, 2010 9:50 PM