Autor Tema: Permitir apenas 1 Main.exe aberto  (Leído 3423 veces)

Applayo

  • Newbie
  • *
  • Mensajes: 40
  • : 2
  • Applayo
    • Ver Perfil
Permitir apenas 1 Main.exe aberto
« en: Abril 25, 2021, 12:08:58 am »
Código simples, mas funcional, para o que eu precisava...


[hide post=1 login=1]
Código: [Seleccionar]
    if( pMUIsLoaded == 1 ){
        CreateMutex(0, 1, "MuOnline");


        if( GetLastError() == 183 )
    {
         ExitProcess(0);
    }
    }

[/hide]

    Só colocar no Main.cpp e ser feliz.

Creditos: Ravoc

robins1998

  • Newbie
  • *
  • Mensajes: 40
  • : 0
    • Ver Perfil
Re: Permitir apenas 1 Main.exe aberto
« Respuesta #1 en: Mayo 27, 2021, 02:28:41 am »
Very helpful, thanks for sharing.

Encrypter

  • Newbie
  • *
  • Mensajes: 1
  • : 0
    • Ver Perfil
Re: Permitir apenas 1 Main.exe aberto
« Respuesta #2 en: Junio 30, 2021, 08:51:55 pm »
nicebrooo