Others have asked if there is a way to determine if an where JBossAS is installed on a system. Unfortunately, because the entire installation procedure is to unzip a zip file, there is no way to tell where it is located.
I feel your pain because I once had to write code that determined if JBossAS was installed. My algorithm first searched in "primary" locations (root dir of each drive, in Program Files (in case anyone was crazy enough to put it there), and x:/apps (this was a directory commonly used by our testers)). After that, I would fire off another
thread that searched the whole disk, doing about 100 directories at a time before pausing a second (did the pause to prevent the disk from rattling as we scanned the directories and to let others have a chance at the disk). We looked for key files such as jbossall-client.jar or jboss-service.xml (as Jaikiran pointed out, though run.bat would not be a good candidate because that is too generic).