Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Need help with windows batch scripting to create game for blind child

13 Feb 2013   #1

windows 7
 
 
Need help with windows batch scripting to create game for blind child

Hi I'm new to windows batch scripting and am in the process of trying to create a game for a blind child.
But there are a few things i don't know how to do.
and in order to learn how to do them if you could help me
with the code in the following batch file



@echo off
echo please enter name
set /p name-field=
echo please enter address
set /p address-field=
echo please enter city
set /p city-field=
echo please enter state
set /p state-field=
echo please enter zip code
set /p zip field=

What I need to know is what to add to this batch file
that will do the following:

1. Create a comma delimited text file called address-book.txt
which will contain the values entered in the batch file
with all the fields on one line separated by commas.
2. And then i will need to know how to read that
comma delimited file into another program that will
extract the fields from the file and place them into
variables, without the commas.

Anyone who can help me with this, i would appreciate it very much. Thanks.
Ed

My System SpecsSystem Spec
.

13 Feb 2013   #2

Windows 7 Professional 32bit
 
 

Try using python instead.
Pretty simple language and a lot more powerful than batch.

A great learning website is www.codeacademy.com

Also this program that you're importing the CSV file in to, which program is it?
My System SpecsSystem Spec
13 Feb 2013   #3

windows 7
 
 
python?

I don't have the time to learn another language with interpreters and all that. I know batch scripting enough to do most of what i want to do. it's just that i need to learn a few more things that i don't know how to do.
My System SpecsSystem Spec
.


13 Feb 2013   #4

Windows 7 Professional 32bit
 
 

Okay, but so far all you've shown me is that you know how to print to the terminal. Seriously, batch is one of the worst languages for doing this kind of thing.


Still, what do you mean by the second question? Is this a program your building yourself? Is it one that's already made?
My System SpecsSystem Spec
14 Feb 2013   #5

windows 7
 
 
python

Okay, i took some time and watched a tutorial on python. It seems to be quite similar to batch script, so ill take your word for it that it's more powerful. So then tell me how you would do what i want to do in python please.

That is, how do I create the comma delimited file for the example i gave.

and to answer your second question, i will be building a program to read in the comma delimited file and want to know how to extract the data from the file to variables in the second program without the commas.

And btw thank you very much for the quick responses
My System SpecsSystem Spec
14 Feb 2013   #6

windows 7
 
 
codeacademy

I tried to vie the site you recommended and it'd down for maintenance. When was the last time you used that site ?
My System SpecsSystem Spec
Reply

 Need help with windows batch scripting to create game for blind child




Thread Tools




Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 05:31 AM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33