Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Is there any way to use Dir.Change to enter a folder and then go to a folder that's connected by the root?
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
MEINsweeze




PostPosted: Fri Feb 01, 2019 8:29 pm   Post subject: Is there any way to use Dir.Change to enter a folder and then go to a folder that's connected by the root?

What is it you are trying to achieve?
I'm trying to enter a directory for music files and then change the directory to a different one from the same root folder.

What is the problem you are having?
I can't figure out how to change directories to a different folder. For clarity, the folders I'm trying to swap between are as such:
C:\Users\meins\Desktop\beeHive\music
C:\Users\meins\Desktop\beeHive\partystats

(The .T file itself is in beeHive)

Describe what you have tried to solve this problem
Dir.Change doesn't work and Dir.Close doesn't seem to have the right parameters with what I want, since there isn't a stream number in use.
I'm inexperienced with Turing so I don't have any idea of what else to try and I'm not sure if what I'm doing is anywhere near correct.


Post any relevant code (You may choose to attach the file instead of posting the code if it is too long)

Turing:

var musicFile : string := "itsHip.mid"
Dir.Change ("music")
Music.PlayFileStop
Music.PlayFile(musicFile)
Dir.Change ("partystats")


Please specify what version of Turing you are using
4.1.2
Sponsor
Sponsor
Sponsor
sponsor
Insectoid




PostPosted: Sat Feb 02, 2019 11:16 am   Post subject: RE:Is there any way to use Dir.Change to enter a folder and then go to a folder that\'s connected by the root?

I'm just guessing here, but try '..\music'.

../ on Linux means 'go up one directory'. It *might* work on Windows.

You can also use error.lastmsg as shown in the dir.change documentation.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 2 Posts ]
Jump to:   


Style:  
Search: