Now after setting up everything on a new Machine, we came across the Error as
The virtual path maps to another application, which is not allowed
Finally after investigation, we figured out that we have created multiple virtual directories which mainly causes the issue. For instance, we have another virtual directory created for DATADEF which is inside the virtual directory of TEMS8. So this was the main issue. The resolution was to remove the DATADEF Virtual Directory. Everything worked out perfectly, once we removed the inner virtual directory. We should not have something like this image below
We should always have one Virtual Directory and must not have inner virtual directories. When we removed the Virtual directory of GOALS (as in the above case), everything started working properly. This structured worked out as mentioned in the below image. Notice, we have only one root Virtual Directory.