why i create a file name with extension. but it come out without extention.
Sub Output_ScanDat()
Dim loc As String
Open App.Path & "\scan.dat" For Append As #1
ap$ = Chr$(34)
bt$ = ap$ + "," + ap$
a$ = ap$ + "A000001" + bt$
b$ = Mid$(Date$, 1, 2) + Mid$(Date$, 4, 2) + Mid$(Date$, 9, 2) + bt$
h$ = Mid$(Time$, 1, 2) + Mid$(Time$, 4, 2) + Mid$(Time$, 7, 2) + bt$
b$ = a$ + b$ + h$
g$ = bt$ + Trim(Form1.txtLoc.Text) + ap$
For I = 1 To nldiff
c$ = b$ + Trim(quantity(I)) + bt$ + parts(I) + bt$ + lots(I) + bt$ + "A000000" + bt$
Pref2$ = Mid$(lots(I), 1, 2)
Pref1$ = Mid$(lots(I), 2, 1)
loc = GetLocationByLot(Pref2$)
If loc = "FG?" Then
invloc = 1
Else
invloc = 0
End If
f$ = c$ + loc + g$
Print #1, f$
Next I
Close 1
End Sub
This is some of my code ignore other but this code is to create "scan.dat" under my application path. But after the system create the file, the file become "scan" and not scan.dat. (without extension)
This problem is happened only in one pc, other pc run this code and create scan.dat successfully.
Can somebody help me to solve this.

