Results 1 to 14 of 14

Thread: its all about shorcut!!

  1. #1

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    Unhappy

    I have a problem ->

    When i create icon in the start menu and i create it under the programs group, it works fine,and i can also create icon on the desktop. But if i go a group futher,like accessories,no icon are created(both the start menu and the desktop).

    Does somebody know what's happening??

  2. #2
    Lively Member
    Join Date
    Sep 2000
    Posts
    68

    Talking hmm

    Hi there,

    Sorry I dont have an awnser to your question...

    I have a question :-)


    You said that you could create shortcuts on the desktop..

    How??? API??
    THE DOUGSTER!!!!!!


    *-MCSD-*

  3. #3
    Lively Member
    Join Date
    Sep 2000
    Location
    NC, USA
    Posts
    102

    Exclamation

    If you would post a copy of the working and non working code and I will take a look at it.

  4. #4

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

  5. #5

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    my code

    that my sub:
    Code:
    Sub create_icon()
    'create the icon in the selected group
    On Error GoTo EH
    Dim x As Integer
    Dim strProgramPath   As String   ' The path of the executable file
    Dim strGroup         As String
    Dim strProgramIconTitle As String
    Dim strProgramArgs   As String
    Dim sParent          As String
    MkDir start_group_path & "\ISI Databases" 'this make a new folder in the selected group
       strGroup = "ISI Databases"
       strProgramArgs = ""
       
    sParent = "$(" & group_parent & ")"
    'group_parent is the folder above the selected group
    'ex:programs ->group_parent=start menu
    For x = 0 To UBound(component)
        strProgramPath = Destination & "\" & component(x) & ".exe"
        strProgramIconTitle = component(x)
        CreateShellLink strProgramPath, strGroup, strProgramArgs, strProgramIconTitle, True, sParent
        ProgressBar1.Value = ProgressBar1.Value + 1
        Label2.Caption = ((ProgressBar1.Value * 100) \ ProgressBar1.Max) & "%"
        Label2.Refresh
    Next x
       Exit Sub
    EH:
       MsgBox Err.Description
       Resume Next
    End Sub

  6. #6
    Lively Member
    Join Date
    Sep 2000
    Location
    NC, USA
    Posts
    102

    Lightbulb

    assuming everything else is working fine you need to change one thing.

    From:
    Code:
       strGroup = "ISI Databases"
    To:
    Code:
       strGroup = ".\ISI Databases"
    Hope that helps,
    KillemAll

  7. #7

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    ok ill try...but

    How did i do to put the smilie face in my thread???

  8. #8

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    still don't work

    i try it and it does it work,

    dunno why????

  9. #9
    Lively Member
    Join Date
    Sep 2000
    Location
    NC, USA
    Posts
    102

    Question hmmm

    first off, that particular smiley is as a result of an "p" imediately following a ":" like this . You can disable this when you post by clicking on the "Disable Smilies in This Post" checkbox just above the buttons and below the reply window.

    Now back to the problem at hand. Is the directory being created? The directory must exist for the icon to be created. If the directory is not created then it is likey a problem with the value of "start_group_path". Where and how are you setting that value?

    I would create the directory manually then test it if that works the only thing you need to do is fix the fact that the MKDir is not working properly.

  10. #10

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    it is created

    My folder is created,

    But is empty,and when i want to put it in the start menu or programs it work,it's confusing!!@????

  11. #11
    Lively Member
    Join Date
    Sep 2000
    Location
    NC, USA
    Posts
    102

    Lightbulb hmmmm

    Try replacing...

    Code:
    sParent = "$(" & group_parent & ")"
    with...
    Code:
    sParent = "$(Programs)"
    if that does not work can you post the project somewhere or email it to me? let me know how big it is before you email it though. Since I did not have all of the code and forms I cut out alot of it and just used the basic stuff and it worked fine. so I need more of your code to figure it out.

  12. #12

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    Arrow ok

    I'll send you my code(zipped)
    Hope that you don't get lost in it.


  13. #13
    Lively Member
    Join Date
    Sep 2000
    Location
    NC, USA
    Posts
    102

    Lightbulb

    I went through it. It worked for me. The only things I did was rem out some lines that I didn't want to run, as follows:

    'copy_tlb
    'copy_exe 'copy the .exe of all the selected component
    'copy_dll
    'copy_ocx
    'copy_dbase
    'write_reg
    'write_path_reg


    and change the one line I mentioned earlier

    strGroup = ".\ISI Databases"

    It was still in there as "ISI Databases". Once I added the .\ to it, it worked just fine.

    try it again and let me know if you still have problems.

  14. #14

    Thread Starter
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606

    Unhappy you mean...

    When you try it , did you try to put it in the accessories,cuz i try again and still don't work(the folder is created but it's empty)I don't know why it work for you??
    For me it work only if i pet it in start menu or programs!

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