02-27-2006 08:14 AM
Hi jingwei,
Yes, it is excellent advice, but that it not how Nishant wants to do this. 🙂
Nishant,
The vi already takes care of deleting the file before re-creating it (saving it with a previously existing filename).
I am in the middle of a course, so I will re-read you post soon. Got to get back to the class.... 😉
Thanks,
Ray
02-28-2006 03:11 AM
Hiii, Ray
As we are using the file named filenames.lst to maintain the file no, so isnt it possible to create it also, coz if it is not existed in the folder, the vi gives an error, we should check it whether that file exist in the folder or not, if yes then ignore it, else to create the file with that name in that folder, will it be the perfect logic, or it might create some problems?
Thanks,
Nishant
02-28-2006 11:36 AM
Hi Nishant,
Now I understand what you are saying.
Yes, it is possible to create it. What I suggest is to create a copy in each of the folders where the files reside.
This is simple to do. 😉
Ray
02-28-2006 09:48 PM
03-01-2006 08:03 AM
Hi Nishant,
I am glad that you found the solution :D.
Did you implement the file creation routine in the vi?
😄
03-01-2006 10:04 PM
Hiii, Ray
Ya man i have implementd the file creation routine in the vi, at the path selected by the user, as user selects the path and selects the OK button, at a time vi will create the filenames.lst, which maintain the file tracking.
Thanks,
Nishant
03-02-2006 07:02 AM - edited 03-02-2006 07:02 AM
Hi Nishant,
Congratulations.. Job well done! 😄
Now, what you can do is wrap it in a case statement which creates it only if it does not exist. To prevent loosing your previous info., and also may help performance.
In other words, list the directory and see if there is a match for the filename.lst file in that directory. If it exists, do nothing, else create a blank file.
You are doing a lot of learning, which is good! Almost 200 posts..
Ray
😄
Message Edited by JoeLabView on 03-02-2006 08:03 AM
03-02-2006 10:06 PM - edited 03-02-2006 10:06 PM
Hiii, Ray
So now i am dam sure that i ve learnt something from you in this period, bcos i already have done the same thing as you suggest about checking the file from diorectore through listing and putting a case structure, that if the file exists then wont do anything else create the file of that name, and same thing i also have done in the vi, create file header.vi, coz in that vi, the write char to file was askking for the user prompt, if we select the append file option false, else it was appending the header in the existing file, if the append file option is true, so what i ve done is just checking the files from the path through listing directory.vi and del it if it already exists and then create it, else just creating it, which works well for me. here with this i am attaching that modified vi, thanks very much Ray.
And about learning i should say that, this forum has done a lot for me, i ve learnt very much from the forum in just three months, and i am also trying to answer of the question, if it is possible for me, which help the user and tests my knowledge.
Thanks,
Nishant
Message Edited by Nishant on 03-02-2006 10:10 PM
Message Edited by Nishant on 03-02-2006 10:14 PM
03-03-2006 05:05 AM
Hiii, Ray
Do you know anything about the timed loop? anybody havent solved my problem and i am in to hurry..., I am facing the problem for synchronising the timed loop, actually, i want one loop to generate the data and another timed loop to used that generated data to make a buffer of type fifo, but when i run these two loops, it hangs, what happens is upto 200 records, it runs good, but after that both the loop gets hanged, instead i want both to run synchronously without hanged, here with this i am attaching my vi and in the vi i have given some description, and i am also attaching drivers, which are in the vi, which help you to run it.
Thanks,
Nishant
03-04-2006 08:47 PM