Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Trouble streaming objects to file  RSS feed

 
Jason Rod
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to stream an arrayList from another class and write it to file. The code has no errors but nothing is being written to the file either. The file name is "Accounts.txt". Here is the code:



I don't know if that code is even right, but any help would be greatly appreciated. Thanks in advance.
 
Bauke Scholtz
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is the file actually created and empty? Or won't it even just be created? Do you also know where the file actually would be written? (the system path).
 
Jason Rod
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Problem solved, found out that my problem was with the .txt file I was trying to write to, Thanks for the response though.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!