background preloader

Volte

Facebook Twitter

Custom Action to place [TargetDir] in a text file. Hi Scott_54935, The second thing you need to know is add code in the Commit method since you put the custom action under the Commit node.

Custom Action to place [TargetDir] in a text file

Here is the C# code, you can translate it to VB.NET if you have difficulty in understanding it. [RunInstaller(true)] public partial class MyCustomAction : Installer { public MyCustomAction() { InitializeComponent(); } public override void Install(IDictionary stateSaver) { base.Install(stateSaver); } public override void Commit(IDictionary savedState) { base.Commit(savedState); string targetPath=base.Context.Parameters["name"].ToString()+"aa.txt"; if (! String.IsNullOrEmpty(targetPath)) { using (FileStream fs = new FileStream(targetPath, FileMode.CreateNew, FileAccess.ReadWrite)) { StreamWriter sr = new StreamWriter(fs); sr.WriteLine("test succeed"); sr.Close(); } } } } From the code, you can also get to know how to get the TAGETDIR programmatically. Best regards, Bruce Zhou Please mark the replies as answers if they help and unmark if they don't. How to read the values using CustomActionData property from MSI Installer.

C# - How to make a System.Configuration.Install.Installer to get a variable from the Setup project. Updateremote. WPF Localization - On-the-fly Language Selection - Essential WPF and Young Brothers. Download code ver 1.3 from here. Many of my customers asked me: How WPF supports localization and globalization? Is there any built-in mechanism for choosing a language on-the-fly, at runtime and without closing any window? How do I translate formatted text with parameters? Well…, you know the story,… aren’t you!? As you can see, there is more than one solution. I decided to share another mechanism for localizing WPF applications. Download the code from here. Why did I bother to invent another solution, and why would you want to use my solution It provides an option for replacing languages at runtime, on-the-fly It performs better than a lame XML, XPath based binding solution It can be used via Styles, Control Templates and Data Templates It translates a formatted text with parameters, using default and custom formatters It provides a Translate custom markup-extension to write an elegant XAML I will start by discussing the markup snippet bellow: Well, this is the magic of my solution.

SO_PORT_SCALABILITY. How to enable the port scalability feature for RPC proxies and for applications in Windows Server 2008. Windows Server 2008 provides support for more than 64,000 wildcard ports. To support this number of ports, multiple IP addresses are employed. Additionally, a special socket option is passed to enable the same wildcard port to be used across multiple IP addresses. Up to 60,000 dynamic ports may be used per IP address. For more information about this port scalability feature, visit the following Microsoft Web site: The remote procedure call (RPC) process uses this feature to let RPC proxies take advantage of port scalability on servers that are running Windows Server 2008. This article describes how to enable the port scalability feature for RPC proxies and for applications in Windows Server 2008. Incoming connections to the RPC proxy occur over HTTP.

Outgoing connections to the RPC server occur over TCP. When you enable the port scalability feature, the RPC proxy uses multiple IP addresses in the same interface to try to connect to the RPC server. HOWTO: Maximize the Number of Concurrent Connections to IIS6 - David Wang. Question: I'm considering building a realtime ASP.NET application on IIS6, that'll need to support about 3,000 simultaneous users on a server, each with a keep-alive HTTP connection for "server push.

HOWTO: Maximize the Number of Concurrent Connections to IIS6 - David Wang

" The HTTP connection will need to stay open for the duration of the user's session, to allow updates to be pushed to the browser in near real time. My question is, is this technically feasible on IIS6, particularly with the large number of connections? If it's possible, are there any special considerations to get it to work? Thanks in advance. Answer: Yup, IIS6 can easily handle 3,000 concurrent keep-alive connections, assuming you: Have sufficient HW resources (like RAM) on the system Reconfigure the system (i.e. tweak any applicable limits) Run scalable user software that handles the user load (i.e. uses asynchronous IO, not necessarily multi-threaded, has appropriate caches, etc) In your situation, there are a couple of non-obvious limits: