👨🏼💻개발/C#
C# - 설정 값 배열(array) 형태로 저장하고 불러오기
Janger
2023. 2. 1. 22:41
728x90
저장하기
string value = String.Join(",", intArray.Select(i => i.ToString()).ToArray());
Properties.Settings.Default.option_array = value;
Properties.Settings.Default.Save();
불러오기
int[] arr = Properties.Settings.Default.option_array.Split(',').Select(s => Int32.Parse(s)).ToArray();
출처:
https://stackoverflow.com/questions/1766610/how-to-store-int-array-in-application-settings
How to store int[] array in application Settings
I'm creating a simple windows Forms application using C# express 2008. I'm an experienced C++ developer, but I am pretty much brand new to C# and .NET. I'm currently storing some of my simple
stackoverflow.com
728x90