Search Results

Search found 10508 results on 421 pages for 'config'.

Page 6/421 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • Advanced tasks using Web.Config transformation

    - by dcadenas
    Does anyone know if there is a way to "transform" specific sections of values instead of replacing the whole value or an attribute? For example, I've got several appSettings entries that specify the Urls for different webservices. These entries are slightly different in the dev environment than the production environment. Some are less trivial than others <!-- DEV ENTRY --> <appSettings> <add key="serviceName1_WebsService_Url" value="http://wsServiceName1.dev.domain.com/v1.2.3.4/entryPoint.asmx" /> <add key="serviceName2_WebsService_Url" value="http://ma1-lab.lab1.domain.com/v1.2.3.4/entryPoint.asmx" /> </appSettings> <!-- PROD ENTRY --> <appSettings> <add key="serviceName1_WebsService_Url" value="http://wsServiceName1.prod.domain.com/v1.2.3.4/entryPoint.asmx" /> <add key="serviceName2_WebsService_Url" value="http://ws.ServiceName2.domain.com/v1.2.3.4/entryPoint.asmx" /> </appSettings> So far, I know I can do something like this in the Web.Release.Config: <add xdt:Locator="Match(key)" xdt:Transform="SetAttributes(value)" key="serviceName1_WebsService_Url" value="http://wsServiceName1.prod.domain.com/v1.2.3.4/entryPoint.asmx" /> <add xdt:Locator="Match(key)" xdt:Transform="SetAttributes(value)" key="serviceName2_WebsService_Url" value="http://ws.ServiceName2.domain.com/v1.2.3.4/entryPoint.asmx" /> However, everytime the Version for that webservice is updated, I would have to update the Web.Release.Config as well, which defeats the purpose of simplfying my web.config updates. I know I could also split that URL into different sections and update them independently, but I rather have it all in one key. I've looked through the available web.config Transforms but nothings seems to be geared towars what I am trying to accomplish. These are the websites I am using as a reference: Vishal Joshi's blog, MSDN Help, and Channel9 video Any help would be much appreciated! -D

    Read the article

  • PowerPoint PlugIn does not read defaults from .dll.config file

    - by Nick T
    I'm working on a very simple PowerPoint plugin, and I'm quite a bit stumped. In my settings.settings file, I have configured a setting "StartPath", which references where the PowerPoint plugin will navigate to using a Browser component. After I compile the application, and run the installer generated by the Setup project, the application is installed and uses the default value in the settings file. However, if I edit the application.dll.config file, the plugin still uses the old values. How can I set things up such that the plugin references the .dll.config file and not its default settings? The code to access the settings is listed below, including the other variants I have tried: //Attempt 1 string location = MyApplication.Properties.Settings.Default.StartPath; //Attempt 2 string location = ConfigurationManager.AppSettings["StartPath"]; //Attempt 3: Configuration element is inaccessible due to its protection level string applicationName = Environment.GetCommandLineArgs()[0] + ".exe"; string exePath = System.IO.Path.Combine(Environment.CurrentDirectory, applicationName); Configuration config = ConfigurationManager.OpenExeConfiguration(exePath); string location = config.AppSettings["StartPath"];

    Read the article

  • Castle Windsor Project Includes in Config

    - by Michael Edwards
    I want the properties section of the Castle config to be included from another file. I.e: <castle> <include uri="file://properties.config" /> </castle> The properties.config would then look like: <properties> <smtp>10.10.10.10</smtp> <username>john</username> </properties> I can get the include to work for components but not for properties. If I try to do this with properties I get an exception thrown. Is this a limitation of Castle?

    Read the article

  • Escaping Hyphens with pkg-config through qmake

    - by Nexus
    I am trying to compile an application using qmake that is using pkg-config to bring in yaml-cpp. Unlike using pkg-config through the terminal qmake which is formatted like: pkg-config --libs --cflags yaml-cpp qmake actually spits out the include paths inside the make command like this: -I/usr/local/include/yaml-cpp This include path breaks subsequent includes which I've set in my qmake file. It's not possible for me to rearrange these includes due the order in which qmake parses its variables. Is it possible using qmake to escape the quote somehow or to make it use the first quoted configuration?

    Read the article

  • Get the file path of the current app

    - by dummy
    The reason I asked this question is that I wanted to create a helper class for Remoting instantiation, and wanted to pass the appropriate app.exe.config (or web.config) file path to the RemotingConfiguration.Configure method, depending on the caller. Is there a way I could get the name of the config file for both Win and Web apps without checking if the application is Web or WinForms?

    Read the article

  • Where are config files for class libraries physically located?

    - by BadNinja
    My guess is that this question will fall under the category of "duh", but, nevertheless, I'm confused. When using config files in, for example, a Windows Forms Application, the config file can be found in C:\Program files\CompanyName\ProductName\Application.exe.config. However, with the class library I'm developing I do not see a "ClassLibrary.dll.config" file in the install folder after installing it (in tandem with another project) from Visual Studio. Even though I do not see the file anywhere, retrieving data from it works correctly. Plus, running the following code from a method within the class library returns the path you would expect: C:\Program files\CompanyName\ProductName\ClassLibrary.dll.config. If someone could shed some light on what I'm missing here, that would be really awesome. public static string MyMethod() { Assembly assem = Assembly.GetExecutingAssembly(); Configuration config = ConfigurationManager.OpenExeConfiguration(assem.Location); return "The assembly location was: " + assem.Location + Environment.NewLine + "The config file path was: " + config.FilePath; // Gives me "C:\Program files\CompanyName\ProductName\ClassLibrary.dll.config" }

    Read the article

  • Is it possible to configure a location in Web.config to only allow local connections

    - by gatapia
    Hi All, I've got a page in an ASP.Net app (its Mvc actually but not important) and I would like to only allow connections to this page from the local machine. I would love to do something like this in Web.config: <location path="resources"><system.web><authorization><allow ips="local"/></authorization></system.web></location> I know this is possible with a simple check in the page code behind (or controller) and its even possible just with IIS configuration but I would love a Web.config config as this would be the most elegant solution in my opinion. Anyone know if this is possible? Thanks Guido

    Read the article

  • Split user.config into different files for faster saving

    - by HorstWalter
    In my c# Windows Forms application (.net 3.5 / VS 2008) I have 2 settings files resulting in one user.config file. One setting file consists of larger data, but is rarely changed. The frequently changed data are very few. However, since the saving of the settings is always writing the whole (XML) file it is always "slow". SettingsSmall.Default.Save(); // slow, even if SettingsSmall consists of little data Could I configure the settings somehow to result in two files, resulting in: SettingsSmall.Default.Save(); // should be fast SettingsBig.Default.Save(); // could be slow, is seldom saved I have seen that I can use the SecionInformation class for further customizing, however what would be the easiest approach for me? Is this possible by just changing the app.config (config.sections)?

    Read the article

  • extra AuthorizationRule in web.config AuthorizationSection

    - by H07R0D
    I'm trying to modify the list of allowed users in web.config from a codebehind. <authorization> <allow users="alice, bob"/> <deny users="*"/> </authorization> I successfully retrieve the section I need config = WebConfigurationManager.OpenWebConfiguration("~"); authSection = (AuthorizationSection)config.GetSection("system.web/authorization"); When I iterate looking for the allow rule, I get two of them. foreach (AuthorizationRule rule in authSection.Rules) { if (rule.Action == AuthorizationRuleAction.Allow) { // manage the Users StringCollection } } The first item I get has 'alice' and 'bob' in the Users collection. The SECOND item I get has * Where is this second entry coming from? This is an Allow Rule, not a Deny rule. I could understand the * from a Deny rule. Is there some extra inheritance I'm not aware of?

    Read the article

  • Write permission for a specific folder in web.config

    - by Simon Dugré
    My question is preaty simple. Is there any way to give current user (IIS User, in this case, ASP NET USER) permission to write to a specific folder location (folder inside our web application) using web.config? Because, it's getting boring to ask to the web hoster to gain access to a specific folder each time we want to do a file uploader on a website. I know it's maybe preaty simple to find an answer using google, but it keeps returning me how to write INTO web.config instead of permission to write into web.config FOR a specific folder. In addition, I'm french so my english is not at the top.

    Read the article

  • Use HTML markup into web.config file

    - by stighy
    Hi, i've to display a messagge in my homepage (default.aspx) different for each "installation" of my web app. i would like to avoid to make a call to database to show this message.. so i've thougth to use web.config to store something like this <add key="WelcomeString" value="lorem ipsus <b>doloret sit amen</b>" /> But i've noticed i can't use html markup into web.config ... Is there a better approach ? Or is there a way to insert html markup into web.config ? Thank you again stack overflow guru's... i'm learning from you a lot of things !

    Read the article

  • app.config and 64-bit machines

    - by Dale Lutes
    I have an app that works fine on 32-bit systems, but fails on XP 64 bit systems. I've tracked it down to the connection string defined in my app.config thus: <connectionStrings> <clear/> <add name="IFDSConnectionString" connectionString="Data Source=fdsdata;Initial Catalog=IFDS; Trusted_Connection=true;Connect Timeout=0" providerName="System.Data.SqlClient" /> </connectionStrings> When I try to reference it in code, I find that the ConfigurationManager.ConnectionStrings collection only contains the LocalSqlServer connection string from the machine.config file and not my custom string. Another oddity is that it works fine when I run the app out of Visual Studio. It is only when I run out of the release folder that the connection string does not get defined. The application's .exe.config file is there in the release folder along with the .exe file and is up to date.

    Read the article

  • How do I send the ckeditor config using jQuery service?

    - by syn4k
    My service is built and it is sending the config variable to my js file: [['SpellChecker','-','Undo','Redo','-','Bold','Italic','Underline','NumberedList','BulletedList']] The above is assigned to my javascript like so: var config = "<?= stripslashes($_REQUEST['config']) ?>"; I can alert out the config just fine: console.log(config) does send back the correct data... However, I get an error thrown in my console!: v is undefined [Break On This Error] var u=n.toolbox.toolbars,v=n.config.to...aximize','ShowBlocks','-','About']]; If I comment out the config: //CKEDITOR.config.toolbar = config; everything works fine but the configuration doesn't exist, of course...

    Read the article

  • How is Magento using the module_name tag elements in the module config file

    - by zokibtmkd
    I found here that Magento is using these tags as custom config variables, but I still cannot understand where are they used and how. For example the Wishlist module has wishlist (same name as the module) xml tag in the config.xml file in which it defines: <item> <product_attributes> <visibility/> <url_path/> <url_key/> </product_attributes> </item> Where is this module using these configurations? Also if I was to build payment method, I have to add in my custom module config.xml a tag for sales and then for quote and so on... I also found other related questions, but most of the answers were that these tags can be anything, but I need to know how they are used by the system. Thank you in advance

    Read the article

  • Where is my app.config for SSIS?

    Sometimes when working with SSIS you need to add or change settings in the .NET application configuration file, which can be a bit confusing when you are building a SSIS package not an application. First of all lets review a couple of examples where you may need to do this. You are using referencing an assembly in a Script Task that uses Enterprise Library (aka EntLib), so you need to add the relevant configuration sections and settings, perhaps for the logging application block. You are using using Enterprise Library in a custom task or component, and again you need to add the relevant configuration sections and settings. You are using a web service with Microsoft Web Services Enhancements (WSE) 3.0 and hosting the proxy in SSIS, in an assembly used by your package, and need to add the configuration sections and settings. You need to change behaviours of the .NET framework which can be influenced by a configuration file, such as the System.Net.Mail default SMTP settings. Perhaps you wish to configure System.Net and the httpWebRequest header for parsing unsafe header (useUnsafeHeaderParsing), which will change the way the HTTP Connection manager behaves. You are consuming a WCF service and wish to specify the endpoint in configuration. There are no doubt plenty more examples but each of these requires us to identify the correct configuration file and and make the relevant changes. There are actually several configuration files, each used by a different execution host depending on how you are working with the SSIS package. The folders we need to look in will actually vary depending on the version of SQL Server as well as the processor architecture, but most are all what we can call the Binn folder. The SQL Server 2005 Binn folder is at C:\Program Files\Microsoft SQL Server\90\DTS\Binn\, compared to C:\Program Files\Microsoft SQL Server\100\DTS\Binn\ for SQL Server 2008. If you are on a 64-bit machine then you will see C:\Program Files (x86)\Microsoft SQL Server\90\DTS\Binn\ for the 32-bit executables and C:\Program Files\Microsoft SQL Server\90\DTS\Binn\ for 64-bit, so be sure to check all relevant locations. Of course SQL Server 2008 may have a C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\ on a 64-bit machine too. To recap, the version of SQL Server determines if you look in the 90 or 100 sub-folder under SQL Server in Program Files (C:\Program Files\Microsoft SQL Server\nn\) . If you are running a 64-bit operating system then you will have two instances program files, C:\Program Files (x86)\ for 32-bit and  C:\Program Files\ for 64-bit. You may wish to check both depending on what you are doing, but this is covered more under each section below. There are a total of five specific configuration files that you may need to change, each one is detailed below: DTExec.exe.config DTExec.exe is the standalone command line tool used for executing SSIS packages, and therefore it is an execution host with an app.config file. e.g. C:\Program Files\Microsoft SQL Server\90\DTS\Binn\DTExec.exe.config The file can be found in both the 32-bit and 64-bit Binn folders. DtsDebugHost.exe.config DtsDebugHost.exe is the execution host used by Business Intelligence Development Studio (BIDS) / Visual Studio when executing a package from the designer in debug mode, which is the default behaviour. e.g. C:\Program Files\Microsoft SQL Server\90\DTS\Binn\DtsDebugHost.exe.config The file can be found in both the 32-bit and 64-bit Binn folders. This may surprise some people as Visual Studio is only 32-bit, but thankfully the debugger supports both. This can be set in the project properties, see the Run64BitRuntime property (true or false) in the Debugging pane of the Project Properties. dtshost.exe.config dtshost.exe is the execution host used by what I think of as the built-in features of SQL Server such as SQL Server Agent e.g. C:\Program Files\Microsoft SQL Server\90\DTS\Binn\dtshost.exe.config This file can be found in both the 32-bit and 64-bit Binn folders devenv.exe.config Something slightly different is devenv.exe which is Visual Studio. This configuration file may also need changing if you need a feature at design-time such as in a Task Editor or Connection Manager editor. Visual Studio 2005 for SQL Server 2005  - C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\devenv.exe.config Visual Studio 2008 for SQL Server 2008  - C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe.config Visual Studio is only available for 32-bit so on a 64-bit machine you will have to look in C:\Program Files (x86)\ only. DTExecUI.exe.config The DTExec UI tool can also have a configuration file and these cab be found under the Tools folders for SQL Sever as shown below. C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\DTExecUI.exe C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\DTExecUI.exe A configuration file may not exist, but if you can find the matching executable you know you are in the right place so can go ahead and add a new file yourself. In summary we have covered the assembly configuration files for all of the standard methods of building and running a SSIS package, but obviously if you are working programmatically you will need to make the relevant modifications to your program’s app.config as well.

    Read the article

  • Where is my app.config for SSIS?

    Sometimes when working with SSIS you need to add or change settings in the .NET application configuration file, which can be a bit confusing when you are building a SSIS package not an application. First of all lets review a couple of examples where you may need to do this. You are using referencing an assembly in a Script Task that uses Enterprise Library (aka EntLib), so you need to add the relevant configuration sections and settings, perhaps for the logging application block. You are using using Enterprise Library in a custom task or component, and again you need to add the relevant configuration sections and settings. You are using a web service with Microsoft Web Services Enhancements (WSE) 3.0 and hosting the proxy in SSIS, in an assembly used by your package, and need to add the configuration sections and settings. You need to change behaviours of the .NET framework which can be influenced by a configuration file, such as the System.Net.Mail default SMTP settings. Perhaps you wish to configure System.Net and the httpWebRequest header for parsing unsafe header (useUnsafeHeaderParsing), which will change the way the HTTP Connection manager behaves. You are consuming a WCF service and wish to specify the endpoint in configuration. There are no doubt plenty more examples but each of these requires us to identify the correct configuration file and and make the relevant changes. There are actually several configuration files, each used by a different execution host depending on how you are working with the SSIS package. The folders we need to look in will actually vary depending on the version of SQL Server as well as the processor architecture, but most are all what we can call the Binn folder. The SQL Server 2005 Binn folder is at C:\Program Files\Microsoft SQL Server\90\DTS\Binn\, compared to C:\Program Files\Microsoft SQL Server\100\DTS\Binn\ for SQL Server 2008. If you are on a 64-bit machine then you will see C:\Program Files (x86)\Microsoft SQL Server\90\DTS\Binn\ for the 32-bit executables and C:\Program Files\Microsoft SQL Server\90\DTS\Binn\ for 64-bit, so be sure to check all relevant locations. Of course SQL Server 2008 may have a C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\ on a 64-bit machine too. To recap, the version of SQL Server determines if you look in the 90 or 100 sub-folder under SQL Server in Program Files (C:\Program Files\Microsoft SQL Server\nn\) . If you are running a 64-bit operating system then you will have two instances program files, C:\Program Files (x86)\ for 32-bit and  C:\Program Files\ for 64-bit. You may wish to check both depending on what you are doing, but this is covered more under each section below. There are a total of five specific configuration files that you may need to change, each one is detailed below: DTExec.exe.config DTExec.exe is the standalone command line tool used for executing SSIS packages, and therefore it is an execution host with an app.config file. e.g. C:\Program Files\Microsoft SQL Server\90\DTS\Binn\DTExec.exe.config The file can be found in both the 32-bit and 64-bit Binn folders. DtsDebugHost.exe.config DtsDebugHost.exe is the execution host used by Business Intelligence Development Studio (BIDS) / Visual Studio when executing a package from the designer in debug mode, which is the default behaviour. e.g. C:\Program Files\Microsoft SQL Server\90\DTS\Binn\DtsDebugHost.exe.config The file can be found in both the 32-bit and 64-bit Binn folders. This may surprise some people as Visual Studio is only 32-bit, but thankfully the debugger supports both. This can be set in the project properties, see the Run64BitRuntime property (true or false) in the Debugging pane of the Project Properties. dtshost.exe.config dtshost.exe is the execution host used by what I think of as the built-in features of SQL Server such as SQL Server Agent e.g. C:\Program Files\Microsoft SQL Server\90\DTS\Binn\dtshost.exe.config This file can be found in both the 32-bit and 64-bit Binn folders devenv.exe.config Something slightly different is devenv.exe which is Visual Studio. This configuration file may also need changing if you need a feature at design-time such as in a Task Editor or Connection Manager editor. Visual Studio 2005 for SQL Server 2005  - C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\devenv.exe.config Visual Studio 2008 for SQL Server 2008  - C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe.config Visual Studio is only available for 32-bit so on a 64-bit machine you will have to look in C:\Program Files (x86)\ only. DTExecUI.exe.config The DTExec UI tool can also have a configuration file and these cab be found under the Tools folders for SQL Sever as shown below. C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\DTExecUI.exe C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\DTExecUI.exe A configuration file may not exist, but if you can find the matching executable you know you are in the right place so can go ahead and add a new file yourself. In summary we have covered the assembly configuration files for all of the standard methods of building and running a SSIS package, but obviously if you are working programmatically you will need to make the relevant modifications to your program’s app.config as well.

    Read the article

  • ASP.NET - Dynamically register an HttpHandler in code (not in web.config)

    - by Sunday Ironfoot
    Is there a way I can dynamically register an IHttpHandler in C# code, instead of having to manually add it to the system.web/httpHandlers section in the web.config. This may sound crazy, but I have good reason for doing this. I'm building a WidgetLibrary that a website owner can use just by dropping a .dll file into their bin directory, and want to support this with minimal configuration to the web.config.

    Read the article

  • Cannot access app.config or settings.settings data

    - by J Carron
    I have 3.5 application needed to load a string from settings.settings or app.config. I made sure have reference to ConfigurationManager but very simple call from form load value returns null here is code. void LoadSettings() { // I expect to get from my app.config or settings.settings // Settings file set to application, public m_connStr = System.Configuration.ConfigurationManager.AppSettings["somestring"]; // m_connStr is getting Null. I tried .ToString(); That throws a null exception. }

    Read the article

  • .NET: understanding web.config in asp.net

    - by mark smith
    Hi there, Does anyone know of a good link to explain how to use the web.config...... For example, i am using forms authentication... and i notice there is a system.web and then it closed /system.web and then below configuration there are additional location tags here is an example, if you ntoice there is an authentication mode=forms with authorization i presume this is the ROOT....... It is also self contained within a system.web .... Below this there are more location= with system.web tags.... I have never really understand what i am actually doing.. I have tried checkign the MSDN documentation but still i don't fully understand up.... Can anyone help? If you notice with my example.... everything is stored in 1 web.config... i thought the standard waas create a standard web.config and then create another web.config in the directory where i wish to protect it..??? <configuration> <system.web> <compilation debug="true" strict="false" explicit="true" targetFramework="4.0" /> <authentication mode="Forms"> <forms loginUrl="Login.aspx" defaultUrl="Login.aspx" cookieless="UseCookies" timeout="60"/> </authentication> <authorization> <allow users="*"/> </authorization> </system.web> <location path="Forms"> <system.web> <authorization> <deny users="?"/> <allow users="*"/> </authorization> </system.web> </location> <location path="Forms/Seguridad"> <system.web> <authorization> <allow roles="Administrador"/> <deny users="?"/> </authorization> </system.web> </location>

    Read the article

  • Reading and writing to app.config file in C#

    - by Indigo Praveen
    I have some of the values saved in app.config file, I want to create a WinForms application which shows all the AppSettings values in a Form. In the form user can change the settings values, after making changes the user can press the Save button and on this I want to save all the values back to the app.config file. Is there any way to do that in C#?

    Read the article

  • WebService doesn't read web.config

    - by phenevo
    Hi, I've got 3 connectionstrings in web.config, and I used theirs like this: using (SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["SomeName"].ConnectionString)) Every metgod is called by winforms application. One of webmethods doesn't work properly because it reads only one connectionString: data source=.\\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true It's not a connectionString from my web.config . I invoke every method in the same way. How it's impossible ??

    Read the article

  • Auto Encryption of web.config connection string

    - by Klaas Jan
    I want to encrypt the connection string in web.config, the problem is each time a developer changes the connection string in web.config and publishes, it needs to be encrypted every time in the web server. Is there any way that the connection string can encrypted automatically every time someone publishes it? Note :- All of us work on our local machines other than the server. So encryption using local machine key is not an option.

    Read the article

  • C# Dll config file

    - by MegaByte
    Hi Im trying to add a app.config file to my dll, but all attempts have failed. According to MusicGenesis in 'Putting configuration information in a DLL' this should not be a problem. So obviously im doing something wrong... The following code should return my connectionstring from my dll : return ConfigurationManager.AppSettings["ConnectionString"]; However, when I copy the app.config file to my console application, it works fine. Any ideas?

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >