kmaster1 Posted September 16, 2008 Report Share Posted September 16, 2008 Okay. I have an online school and I want to enroll all my students. So I have to fill out a web form for each student. About 15 pieces of info per student. This will take a long time for 150 students. So I want a macro that will open a .csv file and count the number of rows in my excel file, then repeat filling out the form that many times. I know I need the ASCII Begin and End which will go to the next row, but the problem is I need it to pull the information out, then fill out the form, save the form, then start all over. What can I do? Quote Link to comment Share on other sites More sharing options...
stan Posted September 16, 2008 Report Share Posted September 16, 2008 The ASCII File Begin Process command will do this for you. It reads the first line of the .csv file and saves each record (cell) to individual text string variables. You can then have the macro enter each variable into the appropriate field on the form and save it. After these steps insert the ASCII File End Process command. The macro starts over again with the second line of the .csv file, repeating the steps. When finished it starts with line 3 and so on until every line in the file has been processed. Quote Link to comment Share on other sites More sharing options...
kmaster1 Posted September 17, 2008 Author Report Share Posted September 17, 2008 The ASCII File Begin Process command will do this for you. It reads the first line of the .csv file and saves each record (cell) to individual text string variables. You can then have the macro enter each variable into the appropriate field on the form and save it. After these steps insert the ASCII File End Process command. The macro starts over again with the second line of the .csv file, repeating the steps. When finished it starts with line 3 and so on until every line in the file has been processed. Okay, but now the problem. The macro needs to start over again. HOW! And I want this to be done in 1 macro that is the confusing part. Do I use a repeat, but then how to tell when it is finished? Please help Quote Link to comment Share on other sites More sharing options...
stan Posted September 17, 2008 Report Share Posted September 17, 2008 I guess I don't understand. The macro I described will process all 150 lines of the .csv file. After it has finished, do you want the macro to repeat the exact same steps for all 150 lines? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.