修改Emdeded字符串在C#编译的exe [英] Modify Emdeded String in C# compiled exe

查看:217
本文介绍了修改Emdeded字符串在C#编译的exe的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有,我需要能够有一个编译的exe(.NET 3.5 C#),我会做的分配,将需要发送出来的EXE前更改的关键,例如副本的问题。

I have an issue where I need to be able to have a compiled exe ( .net 3.5 c# ) that I will make copies of to distribute that will need to change a key for example before the exe is sent out.

我不能每次需要一个新的EXE时间编译。这是一个薄的客户端,将被用来作为注册过程的一部分。

I cannot compile each time a new exe is needed. This is a thin client that will be used as part of a registration process.

是否可以添加到一个资源文件中的条目以空值那么​​当一个请求进来有其他应用程序抢空白默认瘦客户端,复制,填充所需的数据空白值。

Is it possible to add a entry to a resource file with a blank value then when a request comes in have another application grab the blank default thin client, copy it, populate the blank value with the data needed.

如果是如何?如果没有,你有什么想法?我一直在抓我的头,现在几天的限制,由于界限,我需要工作。

If yes how? If no do you have any ideas? I have been scratching my head for a few days now and the limitation as due to the boundaries I am required to work in.

其他的想法,我已经是价值注入的方法,我不知道我怎么会甚至企图的。

The other idea I has was to inject the value into a method, which I have no idea how I would even attempt that.

感谢。

推荐答案

转换大会IL,做一个文本搜索和替换,再重新编译IL到装配。使用从标准工具.NET SDK

Convert the assembly to IL, do a textual search and replace, recompile the IL to an assembly again. Use the standard tools from the .NET SDK.

这篇关于修改Emdeded字符串在C#编译的exe的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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