Hi! i have successfully implemented the paint module onto my app. But is it possible to save the image into parse when i click the save button?
This is my current code.
var saveBtn = Ti.UI.createButton({ bottom:170, right:100, width:100, height:30, title:'Save' }); saveBtn.addEventListener('click', function() { var filename = "sample.png"; var file = Titanium.Filesystem.getFile(Titanium.Filesystem.applicationDataDirectory, filename); /*if (file.exists()) { file.deleteFile(); } */ file.write(paintView.toImage()); var path = file.nativePath; Ti.API.info('path of image' + path); //alert('Image Save'); }); win.add(saveBtn); //win.open(); };