www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - reading files from a directory

reply miriac <1234go1 gmail.com> writes:
I'm trying to get my program to read all the files in a directory.
dmd gives an errer that theis imports dont exist:
 tango.io.FileSystem,
 tango.io.FileRoots,
Can someone please help me and tell me what i use to do so?
thanxs
M
Nov 24 2009
next sibling parent jcc7 <jccalvarese gmail.com> writes:
== Quote from miriac (1234go1 gmail.com)'s article
 I'm trying to get my program to read all the files in a directory.
 dmd gives an errer that theis imports dont exist:
  tango.io.FileSystem,
  tango.io.FileRoots,
 Can someone please help me and tell me what i use to do so?
 thanxs
 M
Did you install Tango? It sounds like you're trying to use Tango, an alternative runtime library for D. If you're open to a non-Tango example, you might try: http://www.dsource.org/projects/tutorials/wiki/ListDirExample jcc7
Nov 24 2009
prev sibling parent reply Jesse Phillips <jessekphillips+D gmail.com> writes:
miriac Wrote:

 I'm trying to get my program to read all the files in a directory.
 dmd gives an errer that theis imports dont exist:
  tango.io.FileSystem,
  tango.io.FileRoots,
 Can someone please help me and tell me what i use to do so?
 thanxs
 M
As jcc7 mentioned it sounds like you're using a Tango example without installing Tango first. For more details about starting with D: http://www.prowiki.org/wiki4d/wiki.cgi?D__Tutorial/StartingWithD
Nov 24 2009
parent reply miriac <1234go1 gmail.com> writes:
Jesse Phillips Wrote:

 miriac Wrote:
 
 I'm trying to get my program to read all the files in a directory.
 dmd gives an errer that theis imports dont exist:
  tango.io.FileSystem,
  tango.io.FileRoots,
 Can someone please help me and tell me what i use to do so?
 thanxs
 M
As jcc7 mentioned it sounds like you're using a Tango example without installing Tango first. For more details about starting with D: http://www.prowiki.org/wiki4d/wiki.cgi?D__Tutorial/StartingWithD
I really do want to stick to tongo, i instaled it with the instructions in the tongo book but i can try downlding it again and see if it works thanks
Nov 24 2009
next sibling parent Rory McGuire <rjmcguire gmail.com> writes:
miriac <1234go1 gmail.com> wrote:
 
 Jesse Phillips Wrote:
 
 miriac Wrote:
 
 I'm trying to get my program to read all the files in a directory.
 dmd gives an errer that theis imports dont exist:
  tango.io.FileSystem,
  tango.io.FileRoots,
 Can someone please help me and tell me what i use to do so?
 thanxs
 M
As jcc7 mentioned it sounds like you're using a Tango example without
installing Tango first. For more details about starting with D:
 
 http://www.prowiki.org/wiki4d/wiki.cgi?D__Tutorial/StartingWithD
I really do want to stick to tongo, i instaled it with the instructions in the
tongo book but i can try downlding it again and see if it works
 thanks
 
My reply before checking the docs: if its not working after installation then the import paths are incorrect. you could start by checking that. and also note that tango trunk and the latest tango release are somewhat different. also it looks like you should be using trunk because the next release is due out shortly. My reply after checking the api docs: I don't see tango.io.FileRoots anywhere, check the version of tango you are trying to use.
Nov 25 2009
prev sibling parent Sam Hu <samhu.samhu nospam.com> writes:
miriac Wrote:

 I really do want to stick to tongo, i instaled it with the instructions in the
tongo book but i can try downlding it again and see if it works
 thanks
Below link contains information on how to setup Tango workspace: http://www.dsource.org/projects/tango/forums/topic/827 Hope this helps. Btw,if you want dwt build,please let me know through samhu.samhu gmail.com.The prebuilt package can not provide to you right here is because it is from another forum which need login. Regards, Sam
Nov 27 2009