.net-1.1

Finding out Windows service's running process name .NET 1.1

我的未来我决定 提交于 2019-12-30 03:25:09
问题 We are using a badly written windows service, which will hang when we are trying to Stop it from code. So we need to find which process is related to that service and kill it. Any suggestions? 回答1: WMI has this information: the Win32_Service class. A WQL query like SELECT ProcessId FROM Win32_Service WHERE Name='MyServiceName' using System.Management should do the trick. From a quick look see: taskllist.exe /svc and other tools from the command line. 回答2: You can use System.Management

How to remove closing tag of an XmlDocument in C#, .NET 1.1?

ぃ、小莉子 提交于 2019-12-25 06:40:28
问题 How can I remove the closing tag of element c in a XML document? The converted XML will go through a schema validation and it is rejected because it has a whitespace within. I'm using C#, .NET 1.1 (I'm updating a legacy application :-( ). Note : I must not resort to string manipulation to convert the XML document. Current: <main> <a> <b /> <c> </c> </a> </main> Final: <main> <a> <b /> <c /> </a> </main> Update 1 : for additional details, the final XML document is saved as file, and then

SqlDataReader: In this scenario, will the reader get closed?

僤鯓⒐⒋嵵緔 提交于 2019-12-24 03:48:15
问题 I am cleaning up the DataReaders in an old .NET 1.1 project that I inherited. The previous developer coded the data-access-layer in such a way that most of the DAL methods returned SqlDataReaders (thus leaving it up to the caller to properly call the .Close() or .Dispose() methods). I have come across a situation, though, where a caller is not catching the returned SqlDataReader (and therefore is not disposing of it properly). See the code below: Data Access Method: Public Shared Function

How do I connect an autocomplete to a textbox?

霸气de小男生 提交于 2019-12-24 02:25:07
问题 Related to this: jquery doesnt go to error or success I've got an old 1.1 asp.net/vb.net project that I need to add autocomplete to a textbox. I wrote a .asmx (the web service file) as such: <WebMethod()> _ Public Function GetTags() As String() Dim arr() As String = BindTags() Return arr End Function Private Function BindTags() As String() Dim cmdSelect As SqlCommand Dim conMyData As SqlConnection Dim reader As SqlDataReader Dim myList As New ArrayList 'try and make a connection Try conMyData

Why can't my .NET CF application find a DLL In the same directory as the executable?

泪湿孤枕 提交于 2019-12-23 03:14:11
问题 I have a .NET CF 1.1 application that has been running perfectly fine for years. Occasionally, I get a help desk ticket with the following error message (generic): Method not found: MethodName AssemblyNamespace.Class The DLL is there, and it's the same version as my other devices. What could change that would make it not find the method. Does this error imply that the assembly was loaded, or did it break before that even happened? Does it matter how I added the reference in Visual Studio

How will .NET 3.5 SP1 impact my .NET 1.1 applications?

夙愿已清 提交于 2019-12-22 08:38:05
问题 If I have a number of existing applications written and deployed w/ .NET 1.1, is there any risk to installing .NET 3.5 SP1 on the servers? My understanding is that .NET 3.5 SP1 only works with the .NET 2.0 codebase, so it will not touch or affect my .NET 1.1 applications. Can you also point me to any pertinent MSDN documentation? I've searched but can't find anything. Thanks! 回答1: I have .NET 3.5 SP1 installed on a server with some existing .NET 1.1 applications and haven't noticed any

What is the best approach for (client-side) disabling of a submit button?

自古美人都是妖i 提交于 2019-12-20 12:38:08
问题 Details: Only disable after user clicks the submit button, but before the posting back to the server ASP.NET Webforms (.NET 1.1) Prefer jQuery (if any library at all) Must be enabled if form reloads (i.e. credit card failed) This isn't a necessity that I do this, but if there is a simple way to do it without having to change too much, I'll do it. (i.e. if there isn't a simple solution, I probably won't do it, so don't worry about digging too deep) 回答1: For all submit buttons, via JQuery, it'd

.NET Framework 1.1 on IIS 7

放肆的年华 提交于 2019-12-19 18:59:08
问题 I have inherited a .NET Framework 1.1 web site that I must host with IIS 7 on Windows Server 2008. I'm having some trouble. 1. Installation I installed .NET Framework 1.1 following these instructions. The installation automatically created a new Application Pool "ASP.NET 1.1". I use that. 2. Trouble When I launch the web site I see web.config runtime errors: The tag contains an invalid value for the 'culture' attribute. I fix that one and then see: Child nodes are not allowed. I don't want to

Assignment “=” operator in VB.NET 1.1

℡╲_俬逩灬. 提交于 2019-12-19 11:40:36
问题 I'm "cloning" objects in my code. For instance: objClone = objOriginal My question is: Does the assignment operator in VB.NET 1.1 do a member-by-member copy of the objOriginal to objClone or does objClone simply point as a reference to memory referenced by objOriginal? 回答1: It's a reference copy, if the type is a reference type (ie: classes). If it's a value type (Structure), it will do a member by member copy. 回答2: What happens with the code that you show depends on what type objOriginal is:

ComboBox Text Align Vertically Center

*爱你&永不变心* 提交于 2019-12-19 11:38:10
问题 I created the custom combobox on .net framework 1.1, i can custom draw dropdown items, but i can't set or draw the combobox text on Middle Left , combobox text always render top left , but i need text should be render on middle left. [ToolboxBitmap(typeof(ComboBox))] public class MenComboBox :ComboBox { private Image _image = Image.FromFile("Expand.png"); public MenComboBox() { this.DrawMode = DrawMode.OwnerDrawFixed; this.BackColor = Color.White; this.ItemHeight = 18; this.Font = new Font(