使用配置文件设置项目所需的帮助 [英] help needed for setup project with configuration files

查看:55
本文介绍了使用配置文件设置项目所需的帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嘿所有,


我有一个用c#编写的控制台应用程序,它从配置文件app.config读取输入和输出文件位置。我正在尝试为该应用程序构建安装程序安装程序。我无法找到如何在部署中包含该配置文件。

我想使用安装项目方法。


有没有人知道我需要如何将配置文件包含在安装程序中。


非常感谢...


softgelsin

hey all,

i have a console application written in c# which reads input and output file locations from a config file, app.config. i am trying to build a setup installer for that application. I couldnt find how to include that config file in the deployment.
I want to use the setup project method.

Is there anyone know how i need to include the configuration file to the installer.

Greatly appreciated...

softgelsin

推荐答案

嘿。


只需将配置文件添加到安装程序的Application文件夹中。
Hey.

Just add the config file into the Application folder in the installer.


我添加但是当我在不同的机器上安装程序时,它给出了未处理的错误。并且不要认为它从配置文件中读取。

I added but then when i install the program in a different machine, it gives a unhandled error. and dont think it reads from the config file.


嘿。


只需将配置文件添加到安装程序中的Application文件夹。
Hey.

Just add the config file into the Application folder in the installer.


您是否对app.config的路径进行了硬编码?
Have you hardcoded the path of app.config?


这篇关于使用配置文件设置项目所需的帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆