- Регистрация
- 15.05.2017
- Сообщения
- 436
- Благодарностей
- 104
- Баллы
- 43
Hello, I am sure it can be done easier, and my code just always get's very complicated and hard to work with,
for example in this code I have 3 exactly same blocks that get's data from database, and let's say my database address changes, or some field changes, I have to change it in all the 3 blocks.
So the question is - how to create 1 block of data (like a function?) that I could use in all other C# blocks, thank you!
for example in this code I have 3 exactly same blocks that get's data from database, and let's say my database address changes, or some field changes, I have to change it in all the 3 blocks.
So the question is - how to create 1 block of data (like a function?) that I could use in all other C# blocks, thank you!