Jump to content

how to check if a program is installed or not ?


Recommended Posts

hi ,

please tell me how can i check if a program is installed or not.

For example what should i do if i want to check if the download manager is installed or not.

thanx for the help.

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

yes , i know but how to detect them ?

i mean if folder exists @ProgramDir & "IDM" Then

MsgBox(4096, "IDM Found", "Please Click ok to continue adding new files", 10)

how can i detect if a folder or reg entry exists or not.

thanx for the help !

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

Use FileExists to check for your folder or file.

If FileExists(@ProgramsDir & "\IDM") Then
    MsgBox(4096, "IDM Found", "Please Click ok to continue adding new files", 10)
EndIfoÝ÷ Øw«z+P1_¢»j·!x¢¶§z{kË­)íë§{-jYd{+~+kzÛ«ËazéâËZ[-®)ࢺ-êÚ±ùZ¶§Ø¬{-jY^u«­¢+Øì¹ÑÈ¥ÍÁ±å¹µÌÁɵÑÈ(ÀÌØíÉÍÕ±Ðô}U¹¥¹Íѱ±¹ÑÉä ÌäíÕѽ%ÐØ̸ȸÄȸÀÌäì°Ä¤)%9½ÐÉɽÈQ¡¸(%5Í  ½à À°ÌäìÌäì°ÀÌØíÉÍձФ)¹%()Õ¹}U¹¥¹Íѱ±¹ÑÉä ÀÌØí¥ÍÁ±å¹µ°ÀÌØíÙ±ÕôÀ¤(%1½°ÀÌØí­å}µ¥¸ôÌäí!-14ÀäÈíM=Q]IÀäÈí5¥É½Í½ÐÀäÈí]¥¹½ÝÌÀäÈí
ÕÉɹÑYÉÍ¥½¸ÀäÈíU¹¥¹Íѱ°Ìäì(1½°ÀÌØí¤°ÀÌØí­å}µ¥¸°ÀÌØí­å}ÉÍձаÀÌØí­å}ÍÕ°ÀÌØíÙÉÍ¥½¸°ÀÌØíÍ¥éôMÑÉ¥¹1¸ ÀÌØí¥ÍÁ±å¹µ¤(%MÝ¥Ñ ÀÌØíÙ±Õ($%
ÍÄ($$$ÀÌØíÙ±ÕôÌäíU¹¥¹Íѱ±MÑÉ¥¹Ìäì($%
ÍÈ($$$ÀÌØíÙ±ÕôÌäíEÕ¥ÑU¹¥¹Íѱ±MÑÉ¥¹Ìäì($%
ÍÌ($$$ÀÌØíÙ±ÕôÌäí¥ÍÁ±åYÉÍ¥½¸Ìäì($%
ͱÍ($$$ÀÌØíÙ±ÕôÌäìÌäì(%¹MÝ¥Ñ (%½ÈÀÌØí¤ôÄQ¼ÄÀÀÀ($$ÀÌØí­å}ÍÕôI¹Õµ-ä ÀÌØí­å}µ¥¸°ÀÌØí¤¤($%%ÉɽÈQ¡¸á¥Ñ1½½À($%%MÑÉ¥¹1СII ÀÌØí­å}µ¥¸µÀìÌäìÀäÈìÌäìµÀìÀÌØí­å}ÍÕ°Ìäí¥ÍÁ±å9µÌä줰ÀÌØíÍ¥é¤ôÀÌØí¥ÍÁ±å¹µQ¡¸($$$ÀÌØíÑôII ÀÌØí­å}µ¥¸µÀìÌäìÀäÈìÌäìµÀìÀÌØí­å}ÍÕ°ÀÌØíÙ±Õ¤($$%%ÀÌØíÙ±ÕôÌäìÌäìQ¡¸IÑÕɸÌäí%¹Íѱ±Ìäì($$%%ÀÌØíÑôÌäìÌäì=ÈÉɽÈQ¡¸
½¹Ñ¥¹Õ1½½À($$%IÑÕɸÀÌØíÑ($%¹%(%9áÐ(%MÑÉÉ½È Ä¤(%IÑÕɸ)¹Õ¹

You can use a part name like "AutoIt" and it will find it by using StringLeft(). Something to learn from.

:)

Link to comment
Share on other sites

thanx for the help !

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

  • 1 year later...

Hello,

It appears I am not able to see the correct scriptyou attached. What encoding have you used?

Thanks.

Use FileExists to check for your folder or file.

If FileExists(@ProgramsDir & "\IDM") Then
    MsgBox(4096, "IDM Found", "Please Click ok to continue adding new files", 10)
EndIfoÝ÷ Øw«z+P1_¢»j·!x¢¶§z{kË­)íë§{-jYd{+~+kzÛ«ËazéâËZ[-®)ࢺ-êÚ±ùZ¶§Ø¬{-jY^u«­¢+Øì¹ÑÈ¥ÍÁ±å¹µÌÁɵÑÈ(ÀÌØíÉÍÕ±Ðô}U¹¥¹Íѱ±¹ÑÉä ÌäíÕѽ%ÐØ̸ȸÄȸÀÌäì°Ä¤)%9½ÐÉɽÈQ¡¸(%5Í  ½à À°ÌäìÌäì°ÀÌØíÉÍձФ)¹%()Õ¹}U¹¥¹Íѱ±¹ÑÉä ÀÌØí¥ÍÁ±å¹µ°ÀÌØíÙ±ÕôÀ¤(%1½°ÀÌØí­å}µ¥¸ôÌäí!-14ÀäÈíM=Q]IÀäÈí5¥É½Í½ÐÀäÈí]¥¹½ÝÌÀäÈí

ÕÉɹÑYÉÍ¥½¸ÀäÈíU¹¥¹Íѱ°Ìäì(1½°ÀÌØí¤°ÀÌØí­å}µ¥¸°ÀÌØí­å}ÉÍձаÀÌØí­å}ÍÕ°ÀÌØíÙÉÍ¥½¸°ÀÌØíÍ¥éôMÑÉ¥¹1¸ ÀÌØí¥ÍÁ±å¹µ¤(%MÝ¥Ñ ÀÌØíÙ±Õ($%

ÍÄ($$$ÀÌØíÙ±ÕôÌäíU¹¥¹Íѱ±MÑÉ¥¹Ìäì($%

ÍÈ($$$ÀÌØíÙ±ÕôÌäíEÕ¥ÑU¹¥¹Íѱ±MÑÉ¥¹Ìäì($%

ÍÌ($$$ÀÌØíÙ±ÕôÌäí¥ÍÁ±åYÉÍ¥½¸Ìäì($%

ͱÍ($$$ÀÌØíÙ±ÕôÌäìÌäì(%¹MÝ¥Ñ (%½ÈÀÌØí¤ôÄQ¼ÄÀÀÀ($$ÀÌØí­å}ÍÕôI¹Õµ-ä ÀÌØí­å}µ¥¸°ÀÌØí¤¤($%%ÉɽÈQ¡¸á¥Ñ1½½À($%%MÑÉ¥¹1СII ÀÌØí­å}µ¥¸µÀìÌäìÀäÈìÌäìµÀìÀÌØí­å}ÍÕ°Ìäí¥ÍÁ±å9µÌä줰ÀÌØíÍ¥é¤ôÀÌØí¥ÍÁ±å¹µQ¡¸($$$ÀÌØíÑôII ÀÌØí­å}µ¥¸µÀìÌäìÀäÈìÌäìµÀìÀÌØí­å}ÍÕ°ÀÌØíÙ±Õ¤($$%%ÀÌØíÙ±ÕôÌäìÌäìQ¡¸IÑÕɸÌäí%¹Íѱ±Ìäì($$%%ÀÌØíÑôÌäìÌäì=ÈÉɽÈQ¡¸

½¹Ñ¥¹Õ1½½À($$%IÑÕɸÀÌØíÑ($%¹%(%9áÐ(%MÑÉÉ½È Ä¤(%IÑÕɸ)¹Õ¹

You can use a part name like "AutoIt" and it will find it by using StringLeft(). Something to learn from.

:D

Link to comment
Share on other sites

Hello,

It appears I am not able to see the correct scriptyou attached. What encoding have you used?

Thanks.

There's no encoding, that is what happened to text in the old AutoIt tags after the upgrade. If you want an example for FileExist() then check the helpfile, it has everything you need.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...