Programming Tools
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingProgramming Tools

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old December 6th, 2004, 08:52 AM
asforme asforme is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Dec 2004
Posts: 1 asforme User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Run-time error 53

Need help with a simple problem. I am supplied with a file of integer numbers. From within
Visual basic 6.0, I sort the file as follows

Shell "command.com /C type K:\Recycler\temp|sort>K:\Recycler\TEMP1", vbHide

this is quick and dirty, but works well. I then try to open the file to read and get
the run time error 53 "file not found". The file is there as I can open it with notpad.
But program wise it not there. this is the code I use to read the file. I am trying to
load list box. Thanks in advance

Open "K:\Recycler\TEMP1" For Input As #1
Do While Not EOF(1)
Line Input #1, buf
c.AddItem buf
Loop
Close #1

Reply With Quote
  #2  
Old January 18th, 2005, 09:21 AM
strod strod is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jan 2005
Posts: 3 strod User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
When calling a shell command, VB executes the shell and immediately continues on to the next line of code.

If this happens to be your open command, the file might not have been created in time but it will be there when you close your program and use notepad.

I usually put a few seconds delay in after the shell command.

for example

at start of sub, put in Dim TimeOut as long

after shell command put in

TimeOut = Timer + 5 'for 5 seconds
do until timer>TimeOut
loop

hope that helps

Reply With Quote
  #3  
Old February 13th, 2006, 08:59 AM
mayle mayle is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2006
Posts: 2 mayle User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 m 27 sec
Reputation Power: 0
My question is can't setup when occur Error 53...

Hi Strod

My question is:
Occured
"Visual Basic 5.0 Setup Toolkit
Run-time Error '53'
File Not Found"
windows and setup terminated when I setup my software.

Please advise how to solve?

Regards,
May

Reply With Quote
  #4  
Old February 14th, 2006, 03:38 AM
Cirus Cirus is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Mar 2005
Posts: 296 Cirus User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 13 h 30 m 11 sec
Reputation Power: 14
As suggested by strod, try to give some delay.Also the reason of error is due to file usage.i.e The file may not have been closed after creating it.Some applications like World behave absurdly, they exist but program denies its existence.Close the file, free its handle and then your code would read it.

Reply With Quote
  #5  
Old February 15th, 2006, 08:33 AM
mayle mayle is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2006
Posts: 2 mayle User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 m 27 sec
Reputation Power: 0
how to write a exe file to patch

Quote:
Originally Posted by Cirus
As suggested by strod, try to give some delay.Also the reason of error is due to file usage.i.e The file may not have been closed after creating it.Some applications like World behave absurdly, they exist but program denies its existence.Close the file, free its handle and then your code would read it.


Hi Cirus,

It is a software had been installed in system and this software using VB6.0, but my software is using VB5.0 it is why meet error 53.

I can fix it using this way:

copy the program which had been setup successfully to this PC Sysytem which occured error 53, and copy COMCT232.ocx file to C:\windows\system32\, then execute C:\windows\system32\regsvr32 COMCT232.OCX under DOS.

Now i want to write a EXE file as a patch to execute these two steps to make my software work well. Do you know how to write a EXE file to execute 'copy COMCT232.ocx file to C:\windows\system32\, and execute C:\windows\system32\regsvr32 COMCT232.OCX under DOS' automatically?

Thanks
Regards,
May

Reply With Quote
  #6  
Old March 12th, 2006, 01:11 AM
Cirus Cirus is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Mar 2005
Posts: 296 Cirus User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 13 h 30 m 11 sec
Reputation Power: 14
For running an EXE in DOS environment, you can use ShellExexuteEX ( Extended version) that has more options.

If you need to run your exec through batch file using DOS shell there is a commad that at this moment i am not able to recall.I did similar thing in DOS shell.I 'll check up that command .

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingProgramming Tools > Run-time error 53


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap