Posted By

volvis on 06/17/09


Tagged

project folder automatically maxscript projectfolder


Versions (?)


Advertising

Submit Site


Change Project Folder automatically if present


Published in: Maxscript 



Website Promotion
DIRECTORY
is a crucial factor for all websites that need to gain better organic search engine rankings and increase website traffic.
Submitting your website as part of your Web Promotion strategy to our SEO friendly and high traffic Business Directory for review is an excellent way to gain a valuable backlink and increase your websites visibility online.

Submit Site


URL: http://karkijoukkue.fi

When placed in startup scripts, this snippet activates every time user opens a file. It then traverses the directory path backwards and looks for user created project folders. If one is found, script offers to switch it on.

This is very useful when working with a number of projects at a time.

Expand | Embed | Plain Text
  1. callbacks.addScript #filePostOpen "phTraverseProjectPath()" id:("phTraverseProjectPath" as name)
  2.  
  3. fn phTraverseProjectPath = (
  4.  
  5. curPath = maxFilePath
  6. queryAnswer = false
  7.  
  8. for i = 1 to 15 do (
  9. if curPath == "" do continue;
  10. if pathConfig.isProjectFolder curPath then (
  11. if (pathConfig.getCurrentProjectFolder() != curPath) do (
  12. if (queryAnswer == false) do (
  13. if (queryBox ("Change Project Folder?\n" + (curPath as String))) do (
  14. pathConfig.setCurrentProjectFolder curPath
  15. )
  16. queryAnswer = true
  17. )
  18. )
  19. )
  20. curPath = pathConfig.removePathLeaf curPath
  21. )
  22.  
  23. )

Report this snippet 

You need to login to post a comment.

Download royalty free graphics