Missing records

HappyJoni
07-18-2003, 07:38 AM
I'm sorting a file with a .BAT and I'm calling it like this:


Dim StAppName As String

StAppName = ("M:\ScbMain\jbrower\sort.bat")
Call Shell(StAppName, 1)


The problem is that in the output file I only have 999 records but in the main file there is 1004 records. I know it has something to do with the way I'm calling my .BAT because if I go into DOS and run the .BAT from there my output has 1004 records. I'm clueless.

Any help would be greatly appreciated ;-)

Joan

Banjo
07-18-2003, 04:08 PM
What's in the batch file?

blindwig
07-18-2003, 04:40 PM
Have you seen this thread?
http://www.visualbasicforum.com/showthread.php?t=91733

HappyJoni
07-21-2003, 10:23 AM
Have you seen this thread?
http://www.visualbasicforum.com/showthread.php?t=91733


No, I didn't see that thread, I just figured the post was forgotten. How nice that it wasn't 8^)

Here's the BAT:

call dataprod
OTSORT m:\scbmain\jbrower\testqu.tst _
m:\scbmain\jbrower\testNP.tst /S(31,2,C,A)

OTSORT m:\scbmain\jbrower\testqu.tst _ m:\scbmain\jbrower\testRA.tst /S(33,3,C,A)

OTSORT m:\scbmain\jbrower\testqu.tst _ m:\scbmain\jbrower\testTV.tst /S(38,3,C,A)

OTSORT m:\scbmain\jbrower\testqu.tst _ m:\scbmain\jbrower\testMT.tst /S(36,2,C,A)


I'm creating 4 sorted files from testqu.tst
It's very strange and I can't figure it out.

reboot
07-21-2003, 10:37 AM
What is OTSORT ?

HappyJoni
07-21-2003, 12:39 PM
What is OTSORT ?

Opttech Sort High Performance Sort/Merge/Select Utility For Windows & Other Operating Systems. Usable as a stand-alone utility or callable from your programs.

reboot
07-21-2003, 12:47 PM
Then OTSORT is the program actually doing the sorting? Not your VB program?

HappyJoni
07-21-2003, 12:50 PM
Then OTSORT is the program actually doing the sorting? Not your VB program?

Right. I'm just learning VB and I was having a hard time trying to figure out how to do the sort so I just created a BAT file to do it and I call it from my VB program.

reboot
07-21-2003, 12:53 PM
Just as a wild guess, try

StAppName = ("M:\ScbMain\jbrower\sort.bat")
ChDir "M:\ScbMain\jbrower"
Call Shell(StAppName, 1)

HappyJoni
07-21-2003, 12:55 PM
Just as a wild guess, try

StAppName = ("M:\ScbMain\jbrower\sort.bat")
ChDir "M:\ScbMain\jbrower"
Call Shell(StAppName, 1)


Actually, I already have ' ChDir "m:\scbmain\jbrower" ' in the beginning of my program. Should I add it again?

reboot
07-21-2003, 12:57 PM
Probably not.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum