Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Basic Tutorial for Writing Files in Gideros? — Gideros Forum

Basic Tutorial for Writing Files in Gideros?

NoctisNoctis Member
edited September 2016 in General questions
Hi,
i want to learn more about writing files in Gideros. My goal is to make a 3D Modeling App with a OBJ (wavefront) export function. I wrote a small 3D App, and now i want to have more knowledge about this commands. I've watched the documentation, but i do not see a good description to understand this. Can someone help me please with links to tutorials, an explanation or maybe with a code?
Thanks in Advance :)

Comments

  • n1cken1cke Maintainer
    edited September 2016
    -- get file descriptor
    -- 'w' means "write" access, 'b' means "binary" to write any data
    local file, err = io.open("D:/text.txt", "wb")
    print(file, err)
     
    -- write string(s) to file
    local ok, err = file:write("test")
    print(ok, err)
     
    -- close file if it's done 
    file:close()
    Also read this chapter: http://docs.giderosmobile.com/file_system.html
  • NoctisNoctis Member
    edited September 2016
    Hi n1cke and thanks for the code, i will try to write an obj file with this documentation. When i'm getting something done, i will post it :)
Sign In or Register to comment.