Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Recent
    • Tags
    • Users
    • Login

    brackets stay in path

    Scheduled Pinned Locked Moved SDK Help
    6 Posts 0 Posters 467 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 10/03/2009 at 11:42, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   10.1 
      Platform:   Windows  ;   
      Language(s) :   C.O.F.F.E.E  ;

      ---------
      i have a script that loads a texture into a material channel.
      i can get texture to load if the texture is in the same folder as project with filename as eg.. "texture.jpg".
      but if i try to load it from a different folder eg... "c:\Folder\subfolder exture.jpg"
      it loads the path as "c:Foldersubfoldertexture.jpg"

      does anyone know how to get the brackets to stay in the path?

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 10/03/2009 at 20:18, xxxxxxxx wrote:

        i dont know if this will make people understand more but i said the wrong name.
        its meant to be "back slash" \ (not bracket)

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 10/03/2009 at 20:56, xxxxxxxx wrote:

          never mind.
          i got it working.
          i had to add double back slash
          eg... change c:\folder\image.jpg to c:\\folder\\image.jpg
          (just incase someone has same problem)

          1 Reply Last reply Reply Quote 0
          • H Offline
            Helper
            last edited by

            THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

            On 11/03/2009 at 14:16, xxxxxxxx wrote:

            It is generally better to use AddLast(folder or file name) to construct the path instead of writing it directly. This also makes sure it is plattform independently generated I´d say.

            1 Reply Last reply Reply Quote 0
            • H Offline
              Helper
              last edited by

              THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

              On 11/03/2009 at 15:07, xxxxxxxx wrote:

              that wont work?
              because im using it to load a texture to a material (same material all the time)then apply it to an object.

              wouldnt "AddLast(folder or file name)" just use the last path a browsed to.
              which i dont wont because i could change the path, which would make the code not work anymore

              1 Reply Last reply Reply Quote 0
              • H Offline
                Helper
                last edited by

                THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                On 11/03/2009 at 16:15, xxxxxxxx wrote:

                What I mean is something like this:

                Filename fn = "C:";
                fn->AddLast("folder");
                fn->AddLast("image.jpg");

                You shouldn´t explicitly define the path as you did. It doesn´t matter how you use it, I am talking about the compatibility of the path construction if you know what I mean.

                1 Reply Last reply Reply Quote 0
                • First post
                  Last post