How to make an app - Andromo App Maker

Announcement

Collapse
No announcement yet.

Custom File Types/Open In App

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    i cant get the icon part right...

    RizlaUK, nice work with the open with app... it works fine... only one nasty thing won't work when i build your example program.... the icon...

    i just cant get it right...

    i click the mxt file and it opens it with your example program... but i see a unreconized windows icon...

    what should i do?

    greets... Crusiatus Black
    Bas Groothedde
    Imagine Programming :: Blog

    AMS8 Plugins
    IMXLH Compiler

    Comment


    • #17
      I do not know English. I need help. This APZ file worked for me. Could not figure out where the error I'm doing.

      Global Functions;
      function CreateFileAssociation(strApplicationPath, strFileExtension, strAppShortName, strIconFile)
      Registry.SetValue(HKEY_CLASSES_ROOT,strFileExtensi on,"",strAppShortName);
      local strCommandLine = "\""..strApplicationPath.."\" \"%1\"";
      Registry.SetValue(HKEY_CLASSES_ROOT, strAppShortName.."\\shell\\open\\command", "", strCommandLine);
      if(File.DoesExist(strIconFile))then
      local strApp83path = File.GetShortName(strIconFile);
      Registry.SetValue(HKEY_CLASSES_ROOT, strAppShortName.."\\DefaultIcon", "", strApp83path..",0");
      end
      end
      On Preload;
      local strApplication = "C:\\Program Files\\Windows Media Player\\wmplayer.exe"
      CreateFileAssociation(strApplication, ".mp3", "MŁzik Dosyası", _SourceFolder.."\\AutoPlay\\Icons\\48x48x32.ico") ;
      On Show;

      -- check to see if any commandline arg was passed to the app
      if _CommandLineArgs[1] then
      if String.Left(_CommandLineArgs[1], 3) ~= "SFX" then
      YourCustomFile = _CommandLineArgs[1]
      sPath = String.SplitPath(YourCustomFile);
      Input.SetText("Input1", sPath.Filename);

      Audio.Load(CHANNEL_USER1, YourCustomFile, true, false);

      end
      end

      Page.StartTimer(100);

      Comment

      Working...
      X