Basic

  • abbasi
  • Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
15 years 6 months ago #4114 by abbasi
Basic was created by abbasi
Dear Friends,

I am new in InfoBasic/jBase please guide me in my following Questions:

1. How to create directory in my Subroutine
2. How to check my directory exist in my Subroutine
3. How to Delete Specific file in my created directory

Best Regards,
Abbasi

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #4118 by kees
Replied by kees on topic Re:Basic
To create a directory:

Y.DIR.NAME = "TEST.DIR"
Y.SEQ.FILE.NAME = 'MY.txt'

OPENSEQ Y.DIR.NAME,Y.SEQ.FILE.NAME TO Y.SEQ.FILE ELSE
EXECUTE 'CREATE.FILE TEST.DIR TYPE=UD'
CRT "CREATED DIRECTORY"
END





To check if directory is existing:

Y.DIR.NAME = "TEST.DIR"
Y.SEQ.FILE.NAME = 'MY.txt'

OPENSEQ Y.DIR.NAME,Y.SEQ.FILE.NAME TO Y.SEQ.FILE THEN
CRT "Directory TEST.DIR already exists"
END





To delete a specific file in directory:

Y.DIR.NAME = "TEST.DIR"
Y.SEQ.FILE.NAME = 'MY.txt'

EXECUTE "DELETE ":Y.DIR.NAME:' ':Y.SEQ.FILE.NAME

Please Log in or Create an account to join the conversation.

  • abbasi
  • Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
15 years 6 months ago #4126 by abbasi
Replied by abbasi on topic Re:Basic
Kees, Thanks alot

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #4135 by kees
Replied by kees on topic Re:Basic
you are welcome...

Please Log in or Create an account to join the conversation.

Time to create page: 0.037 seconds