Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a .exe running in my Windows XP PC.

This .exe needs a file in the same directory to run and has no problem finding it in Windows XP. But, in Windows Vista (I tried this in several machines and works on some of them) fails to run.

I'm guessing there is a problem finding the path. The program is written in basic (Yes I know..)

I attached the code below. Can you think of any workarounds?

The .exe is located in C:\tools Also the program runs in the Windows console (It starts but then during the execution cannot find a custom file type .TOP made by the creator of the program)

     '   PROGRAMM  TOP11.BAS



DEFDBL A-Z
CLS
LOCATE 1, 1
COLOR 14, 1
FOR I = 1 TO 80
   PRINT "±";
NEXT I
LOCATE 1, 35: PRINT "ΝΝ TOP11 ΝΝ"
PRINT "    €€‚—‚„‘ ’— ‹„’†‘„— ‘’† „”€„€ ’†‘ ‡€€‘‘†‘ ‰€ † „.‚.‘.€.     "
COLOR 7, 0
PRINT "-------------------------------------------------------------------------------"
PRINT
INPUT "ƒι©« «¦¤ ©¬¤«Ά©«γ ¤ΰγ... :  ", Factor#
INPUT "¤¦£ ¨®ε¦¬ [.TOP] : ", topfile$
VIEW PRINT 7 TO 25
file1$ = topfile$ + ".TOP"
file2$ = topfile$ + ".T_P"
file3$ = "Syntel"
OPEN file3$ FOR OUTPUT AS #3
PRINT #3, " ‘¬¤«Ά©«γ ¤ΰγ = " + STR$(Factor#) + "   †‹„‹†€: " + DATE$
CLOSE #3

command1$ = "copy" + " " + file1$ + " " + file2$
SHELL command1$   '’¦ ¨®ε¦ .TOP ¤« ¨α­«  £ «¤ ΅«αΆ¥ .T_P



OPEN file2$ FOR INPUT AS #1
OPEN file1$ FOR OUTPUT AS #2
bb$ = " \\\    \ ,   ###.####   ###.####   ####.###    ##.### "
DO
         LINE INPUT #1, Line$
         Line$ = RTRIM$(LTRIM$(Line$))
         icode$ = LEFT$(Line$, 1)
        IF icode$ = "1" THEN
           Line$ = " " + Line$
           PRINT #2, Line$
           PRINT Line$
        ELSEIF icode$ = "2" THEN
           Line$ = " " + Line$
           PRINT #2, Line$
           PRINT Line$
        ELSEIF icode$ = "3" THEN
             Number$ = MID$(Line$, 3, 6)
             Hangle = VAL(MID$(Line$, 14, 9))
             Zangle = VAL(MID$(Line$, 25, 9))
             Distance = VAL(MID$(Line$, 36, 9))
             Distance = Distance * Factor#
             Height = VAL(MID$(Line$, 48, 6))
           PRINT #2, USING bb$; icode$; Number$; Hangle; Zangle; Distance; Height
           PRINT USING bb$; icode$; Number$; Hangle; Zangle; Distance; Height
         ELSE
        END IF

LOOP UNTIL EOF(1)
VIEW PRINT
CLS
LOCATE 1, 1
PRINT "               ***  ’„‘ ’“ ‚€‹‹€’‘ ***                "
END
share|improve this question

migrated from stackoverflow.com Jan 18 '10 at 9:09

This question came from our site for professional and enthusiast programmers.

    
Can you provide the path you're using? –  ssg31415926 Jan 17 '10 at 8:11
    
What error are you getting? –  Jack Leow Jan 17 '10 at 15:23
    
Do you mean a DLL file (so the program doesn't even start) or some other file which is read by the program? –  AndiDog Jan 17 '10 at 15:38
    
I've not seen BASIC in too long... –  Matthieu Cartier Jan 31 '11 at 23:25
add comment

1 Answer

Wow!

Well, my first guess would be an UAC (Use Account Control) issue, try right clicking the file and choosing Run as administrator and see if it works.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.