c# - How to properly embed settings file -


i have settings.settings file contains number of different endpoints in it. want embed file .dll file users cannot view or modify endpoints.

under build action option settings.settings file see embedded resource. read through msdn page here, i'm still not entirely sure option want.

can confirm want to, , if not, option should select?

i use embedded build action storing word doc template, don't see why couldn't use else such xml file contains settings. set build action embedded , can reference such:

var template = "filename.xml" // <-- file mark embedded assembly loader = assembly.getexecutingassembly(); var rawstream = loader.getmanifestresourcestream(template); byte[] bytearray = rawstream.readtoend(); 

you need using statement:

using system.reflection; 

Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -