detect using Wine

detect using Wine

Postby mgsoft » Fri Jun 24, 2011 1:22 pm

Hi,

Is there a function to detect if the app is running using Wine under Linux or Mac?.

I can´t use windowsversions or registry as Wine emulates Windows XP.

I think this code, but is not very optimal:

Code: Select all  Expand view
function main()

 LOCAL cNotepad    := GetSysDir()+"\notepad.exe"
 LOCAL cContenido  := MemoRead( cNotepad )
 LOCAL cResultado  := AT("Wine", cContenido )
 LOCAL cDevuelve   := .F.


 IF !cResultado = 0
    cDevuelve := .T.
 ENDIF



 msgalert(cnotepad)
 msgalert(ccontenido)

 msgalert(cresultado)

msgalert(cdevuelve)


RETURN( cDevuelve )



Any alternative?.

Thanks ;)
Saludos,

Eduardo
User avatar
mgsoft
 
Posts: 422
Joined: Mon Aug 17, 2009 12:18 pm
Location: España

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 90 guests