Verknüpfung erstellen

  • GM 7

Diese Seite verwendet Cookies. Durch die Nutzung unserer Seite erklären Sie sich damit einverstanden, dass wir Cookies setzen. Weitere Informationen

  • edit: hat sich doch noch nicht erledigt, hab das jetzt ein bisschen verändert und es soll so arbeiten, dass die *.exe im Ordner gefunden wird und auf dem Desktop ein Shortcut mit dem gleichen Namen erstellt wird, diesen Code hab ich da jetzt:

    GML-Quellcode

    1. //Script: dll_shortcut
    2. //Arguments - [3]
    3. //0 - .lnk path - path to the shortcut to be created including the filename
    4. //1 - .exe path - path to the executable to create a shortcut to
    5. //2- description - optional shortcut description, if not needed use ""
    6. //3- working directory - directory to run the exe in (you might need to include the final backslash )
    7. ///////////////////
    8. global.defTestDLL_CreateShortcut=external_define("Shortcut.dll","makeShortCut",dll_stdcall,ty_real,4,ty_string,ty_string,ty_string,ty_string);
    9. arg0=string_replace_all(argument0,"\","\\")
    10. arg1=string_replace_all(argument1,"\","\\")
    11. external_call(global.defTestDLL_CreateShortcut,arg0,arg1,argument2,argument3);
    12. external_free("Shortcut.dll")
    Alles anzeigen


    GML-Quellcode

    1. //Create
    2. linkfile = file_find_first(working_directory + "\*.exe",0);
    3. shortcut = string_copy(linkfile,1,string_pos(".",linkfile)-1);
    4. dll_shortcut(shortcut + ".lnk",linkfile,"","Desktop\");


    Die Dll ist auch mit im Ordner, nur da kommt ein Error:
    Unexpected error occured when running the game
    An was kann das liegen?


    Gruß Gamer.


    edit:
    Hat diese Dll noch keiner verwendet?
    Gruß Gamer

    Dieser Beitrag wurde bereits 3 mal editiert, zuletzt von The Gamer ()