Using UserDefaults to save a high score in swift

I"m trying to get a high score to save each time the player exits the app, but I'm struggling to get it to work and I'm confused as to where I'm making a mistake. var gameSettings = Settings.sharedInstance let HIGHSCORE = "HIGHSCORE" if gameSetting...
more »

2017-06-20 22:06 (2) Answers

Output process - save data in file

Briefly, I'm testing this code in python: My idea is to save solut = one + two in a file after inputting the values by keyboard, but now I have a problem. NO message error and nothing is written in file. python 2.7 I have changed and saved the cod...
more »

2017-06-20 05:06 (2) Answers

Swift 3 - Save image alternative

I need to found an alternative of this method to save images let save = UserDefaults.standard let imageData = UIImageJPEGRepresentation(Photo.image!, 1.0) save.set(imageData, forKey: "Image") save.synchronize() if let imgData = save.object(forKey: ...
more »

2017-06-19 23:06 (2) Answers

How can I auto save a captured image in a UWP app?

I have this code: CameraCaptureUI captureUI = new CameraCaptureUI(); captureUI.PhotoSettings.AllowCropping = false; StorageFile photo = await captureUI.CaptureFileAsync(CameraCaptureUIMode.Photo); How can I implement to auto save image option when...
more »

2017-06-19 13:06 (1) Answers

Saving and reading ArrayList

Saving method (save list is an Arraylist): public static void saveList(){ editor.putString("list", Calculate.saveList.toString()); } My reading method (probably where my problem is): public static void readList(){ String arrayString= pref...
more »

2017-06-18 16:06 (2) Answers

Saving several variable values in android

I have an app which has a few tab fragments. In each tab there are 15 variables. So totally I have more than 90 variables. Can I use SharedPreferences to save the variable values in each app session? And also I need to call a OnVariableChangeListen...
more »

2017-06-16 16:06 (0) Answers

How to fully save 1 web page fully to local

Sometimes i have small 1 page tasks for front end dev i am not regular with us. (he does not have access to git repo, nor fpt details) How can fully save all the files needed for that page? When i try to use FF/Chrome "save Page as, Web Page compet...
more »

2017-06-15 17:06 (0) Answers

Yii2: Problems with Yii2 DB save()

$model = new DBUsers(); $model->name = $this->name; $model->username = $this->username; $model->password = $this->password; $model->authKey = 'test100key'; $model->accessToken = '100-token'; $model->email = $this->...
more »

2017-06-15 13:06 (0) Answers

Java save simple Data

i need to save data from an java desktop application. The main part of the Data are the texts of around 50 labels. Which are spread over 5 Java GUI-classes. The Rest are some simple application settings. Now i am quit unsure about how to safe these...
more »

2017-06-13 19:06 (1) Answers

userDefaults saving level data as array not saving

I have a game and I have custom levels which is saved as an array. I use the function saveCustomLevels to save the value of the level data. Every time the level data is changed, I do saveCustomLevels(). Whenever I do saveCustomLevels() and close the ...
more »

2017-06-10 17:06 (0) Answers

Saving painting from a control not working?

So I'm making a paint app and I'm trying to save the paint on a Panel Control into a .Jpeg, however, my code doesn't work. It saves a .Jpeg image but it's just a full white image. My Code: SaveFileDialog dialog = new SaveFileDialog(); ...
more »

2017-06-09 20:06 (0) Answers