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
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    File Access Problems

    Scheduled Pinned Locked Moved SDK Help
    2 Posts 0 Posters 200 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 24/03/2006 at 15:51, xxxxxxxx wrote:

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

      ---------
      Hi there guy's

      Im quite new to playing with c.o.f.f.e.e. - hopefully you can help

      1...
      im trying to read from a file.
      nothing complex.
      Ive got a c.o.f.f.e.e. node in an xpresso tag...
      in it it includes the lines of...

      ...
      var srcfile = new(BaseFile);
      srcfile->Open(filename, GE_READ);
      var myreal = srcfile->ReadReal();
      ...

      filename contains the path\filename to a file. (hardcoded at the moment 🙂

      Does absolutely bugger all. Doesnt even seem to try to open the file.

      Now would I be right in saying that you cant use file operations from c.o.f.f.e.e. nodes in xpresso tags? Im sure i remember reading that somewhere - cant see it in the sdk I downloaded though!

      If that is the case, can I just stick it in a propper c.o.f.f.e.e. tag instead and it should work? (I have no idea how to create simple input/output ports that i can attatch to other stuff on a c.o.f.f.e.e. tag, like you can with an xpresso tag - so dont really know how to go down this route yet)

      2...
      Is there a coffee instruction to return the path of the current document, i can only seem to find an instruction to return the current c4d install path.
      If all that makes sense!

      Many thanks in advance

      martin!

      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 31/03/2006 at 11:07, xxxxxxxx wrote:

        1. It seems to work here. Perhaps the filename is wrong? I don't know how you're creating the filename, but an easy way is to use a filename port as input for the C.O.F.F.E.E. node. (I have exactly the same code as you!)
        2. BaseDocument::GetFilename()

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