![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
C#/ASP.NET
lk5423968
Everything will be better, and better, just clam down do my best to accumulate
展开
-
use notifyicon to minimize the image onto the toolbar
/// /// When minisize the m_form. /// /// /// private void Form1_SizeChanged(object sender, System.EventArgs e) { //hide the m_form and show the icon when the Form is minisized. if (this原创 2010-01-25 17:37:00 · 518 阅读 · 0 评论 -
md5 arithmetic
using System;using System.IO;using System.Data;using System.Text;using System.Diagnostics;using System.Security;using System.Security.Cryptography;using System.Windows.Forms;using System.Windows;using原创 2010-01-25 17:44:00 · 610 阅读 · 0 评论 -
operation database in the transaction object
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Data;using System.Data.SqlClient;namespace dbtest{ class Program { static void Main(string原创 2010-03-19 17:49:00 · 473 阅读 · 0 评论 -
Examples to create your Conferencing System in .NET, C# VOIP & Video Conferencing Systems using H.323 and TAPI 3
NOTE:SOURCE : http://www.codeproject.com/KB/IP/Video_Voice_Conferencing.aspx IntroductionI noticed that there are many members who want to know how to create an Audio/Video Conferencing System u原创 2010-04-19 21:13:00 · 1073 阅读 · 0 评论 -
Get parameters from Url
<br />using System.Collections.Specialized;<br /> <br />int user;<br />int projid;<br /> <br />NameValueCollection para = Request.QueryString;<br /> if(para["user"]!=null)<br /> {<br /> int.TryParse(para["user"].ToString(), out use原创 2010-06-30 16:26:00 · 629 阅读 · 0 评论 -
VB.NET/C# and JavaScript communication
IntroductionThis article is about passing data between VB.NET/C# WinForms and JavaScript.Before reading further, let me warn you that this article is not about ASP.NET. Concepts covered in the art原创 2010-05-17 10:45:00 · 1012 阅读 · 0 评论 -
how to create dynamically crystal roporter with C# code
<br />This is based on window application<br />1. Add new windows form that is "Crystal reporter" in the "Reporing" label<br />2.Add the user control "CrystalreporterView"<br /> <br />Below is the code detail:<br /> <br />using System;<br />using System.原创 2010-06-04 16:25:00 · 583 阅读 · 0 评论 -
How to create WCF
1. Create New Project, and select WCF Service Library2. Delete the two sample, "Service1.cs","IService1.cs"3. Creat three new items, relatively named "Eval.cs","EvalService.cs","IEval.cs". the code is below://Eval.csusing System;using System.Collections.Ge原创 2010-08-12 17:30:00 · 741 阅读 · 0 评论 -
The controller for path '/favicon.ico' could not be found or it does not implement the IController interface./r/nParameter name:
<br />The Routing system no longer special-cases the period character. Take a look at the Global.asax provided with the April codeplex templates:<br />1 routes.MapRoute(<br />2 "Default",原创 2010-08-24 15:08:00 · 3898 阅读 · 0 评论 -
A simple C# Wave editor, part 1: Background and analysis
A simple C# Wave editor, part 1: Background and analysisBy Jonathan Kade | 6 Aug 2004 The first phase of a RIFF/Wave editing "swiss army knife", in which we'll learn how to extract all the data present in common Wave files and store it in an XML转载 2010-08-30 16:50:00 · 936 阅读 · 0 评论 -
Master Pages and JavaScript document.getElementById
<br />Whenever a control is inside a Master Page, the client ID of the control would get appended with its content placeholder ID. So, for an element with an ID “txtTest”, the new client ID would look something like “ctl00_ContentPlaceHolder1_ txtTes原创 2010-09-20 10:55:00 · 477 阅读 · 0 评论 -
Reading binary data in C#
Reading binary data in C#<br /> In the C# newsgroup, I've seen quite a lot of code for reading in data from a file like this: // Bad code! Do not use!FileStream fs = File.OpenRead(filename);byte[] data = newbyte[fs.Length];fs.Read (原创 2010-09-20 15:25:00 · 474 阅读 · 0 评论 -
WCF vs ASP.NET Web services
<br />Introduction<br />In this post I will explain the Difference between ASP.NET web service and programming WCF services like ASP.NET web services. It also discusses how we use the both technologies for developing the web services.<br />The develo原创 2010-09-27 15:18:00 · 687 阅读 · 0 评论 -
How to use the UTF8Encoding class to encode and decode a text?
<br />The steps to use the UTF8Encoding class to encode and decode a text data are as follows:Implement the following namespace:<br /> <br />using System.Text; Create a UTF8Encoding class object as follows:<br />UTF8Encoding utf8 = new UTF8Encoding();C原创 2010-10-09 14:50:00 · 738 阅读 · 0 评论 -
Server Error in '/folder' Application ... A potentially dangerous Request.Form value was detected ...
Symptom:<br />When entering a value with angled brackets into a text box on a .NET application the following error is generated in the browser:<br />Server Error in '/folder' Application.<br />A potentially dangerous Request.Form value was detected from th转载 2010-10-12 16:36:00 · 1383 阅读 · 0 评论 -
Custom DialogBox Control Component For ASP.net
<br />1.Create a .cs class file and append the code as below<br />2.Build the solution and add the custom control into the tool box<br />3.You can find drag the control to where you want in the page from the tool box<br /> <br /> <br /><br /> <br />using原创 2010-12-08 12:55:00 · 492 阅读 · 0 评论 -
how to send email
<br /> public static void MailErrorMessageToDevTeam(Exception ex, String loginUserId,<br /> String[] additionalInfo)<br /> {<br /> try<br /> {<br /> //////////////////////////////////////////////////////////////原创 2010-10-20 15:30:00 · 739 阅读 · 0 评论 -
How to bound the javascript to buttonfleid
<br />1. in the button fleid, you must to set the CausesValidation as "true", or the javascript will block the button event which should be triggered in the sever side, below is a example<br /> <asp:ButtonField ButtonType="Button" Text="copy" CommandName=原创 2010-12-14 15:21:00 · 495 阅读 · 0 评论 -
Set the directory permission
<br />I find there is very little code about this topic, so I research it and excute , below is the code, what I demonstrate is that the NTAccount must be correct, otherwise , you can't add the Accessrule into the DirectorySecurity.<br /> <br />原创 2010-11-23 16:20:00 · 564 阅读 · 0 评论 -
How to Paging and sorting the gridview
Girdview set in the ui page as below:below is the GridView_Data_PageIndexChanging protected void GridView_Data_PageIndexChanging(object sender, GridViewPageEventArgs e) { Button1_Click(sender,e);//used to select data from database原创 2010-11-25 16:05:00 · 477 阅读 · 0 评论 -
log4net.config
<br /><?xmlversion="1.0"encoding="utf-8"?><configuration><log4net><appendername="ExampleAppender"type="log4net.Appender.RollingFileAppender"><filevalue="C:/Log4NetExamples/Example.log"/><appendToFilevalue="false"/><rollingStylevalue="Size"/><maxSizeRollBac原创 2011-03-30 11:43:00 · 474 阅读 · 0 评论 -
How to change the menu item font color individually
<br />Sever side:<br /> public Color GetItemColor(MenuItemTemplateContainer container)<br /> {<br /> MenuItem item = (MenuItem)container.DataItem;<br /> //identify based value<br /> if (item.Value == "value 2")<br /> retu原创 2011-04-11 14:22:00 · 749 阅读 · 0 评论 -
DataSet hell - "Failed to enable constraints. One or more rows contain values...."
Important note: Hi folks. This post was written in 2004. Yes, people have been getting this for over 6 years. It’s 2011 now, and here you ar转载 2011-08-24 16:55:31 · 1442 阅读 · 0 评论 -
Modify Web.config
private voidChangeAppSettings(string key,stringNewValue) { Configuration cfg; cfg = System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration("~"); KeyV原创 2011-11-14 16:05:44 · 479 阅读 · 0 评论 -
The Best Way to Learn ASP.NET
You’re looking to learn ASP.NET? I can’t blame you. Not only is it an extremely flexible platform, but .NET developers are in high demand and will continue to be. Unfortunately, it can be an intimida转载 2011-11-17 13:40:22 · 881 阅读 · 0 评论 -
6 important .NET concepts: - Stack, heap, Value types, reference types, boxing and Unboxing.
Introduction This article will explain 6 important concepts Stack , heap , value types , reference types , boxing and unboxing. This article starts first explaining what happens internally when转载 2011-12-31 12:15:12 · 596 阅读 · 0 评论 -
.NET 3.5 Keyword Description
iddasm view assembly lutz reoeder's reflector struct: can't inherit and instantiatedclass: can do bothvalue type: store on stackreference type:store on garbage collected/manage heapover原创 2012-03-06 11:55:17 · 544 阅读 · 0 评论 -
Acitve Directoy Management
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.DirectoryServices;//you must add this reference into this solution firstlynamespace ADTest{原创 2012-03-08 00:16:05 · 986 阅读 · 0 评论 -
Asynchronous programming in C# 5
One of the more radical design decisions in the forthcoming Windows Runtime is that no API may, even potentially, take more than 50 milliseconds to complete. Operations that could take longer than th转载 2012-03-27 11:12:48 · 658 阅读 · 0 评论 -
What else is new in C# 5?
The big new feature in C# 5 is asynchronous programming support, which I wrote about last week. However, the C# folks have also slipped in a couple of smaller features and I thought I’d round thing转载 2012-03-27 11:13:47 · 693 阅读 · 0 评论 -
How to attach to Browser Helper Object (BHO) with C# in two minutes
Download source code - 3.83 KBIntroductionMicrosoft has provided the Browser Helper Object (BHO) to let developers "drive" Internet Explorer. The first BHO was introduced in 1997 with IE 4.0. I ha原创 2012-03-29 23:33:12 · 1723 阅读 · 0 评论 -
Build a Managed BHO and Plug into the Browser
With the amount of time we spend touring the Internet for information, enhancing the browsing experience has never been more important. Internet Explorer has an extensibility model supporting a variet原创 2012-03-29 17:20:11 · 1090 阅读 · 0 评论 -
MSHTML Event DispInterfaces(For Hosting or Automation IE)
You can receive notifications fired by various HTML elements on a page using the links to connection points articles in this section.DispInterfacesHTMLAnchorEventsThis dispinterface prov原创 2012-03-30 16:45:22 · 922 阅读 · 0 评论 -
Reflection in .NET
ContentsIntroductionWhat is.NET Reflection?Road MapThe System.Reflection NamespaceThe System.Type ClassUsing System.Object.GetType()Using System.Type.GetType()Using the typeof () C# Operator转载 2012-03-18 01:40:08 · 864 阅读 · 0 评论 -
10 SEO tips for your ASP.NET website
IntroductionHere are 10 tips on SEO for your ASP.NET website. I'm sorry that some of the screenshots contain German language text, but I hope you'll get my point despite that :)1. Avoid duplicate原创 2012-04-20 21:49:56 · 1403 阅读 · 0 评论 -
Step by Step SharePoint Server 2010 Installation Guide
IntroductionThis article provides a step by step Installation and Prerequisites Software requirement forSharePoint server 2010 beta installation. Finally! My long awaited SharePoint Server 201转载 2012-06-07 14:24:56 · 908 阅读 · 0 评论 -
Resource Editor Won't Work In Visual Studio
This happened to me and opening in notepad then closing didn't work. Here are the steps I took that resolved the problem. I don't know if all are needed as I did all at once.1) right click on reso原创 2012-11-16 15:06:17 · 448 阅读 · 0 评论 -
HttpUtility does not exist in the current context
Project -> Properties -> Application -> Target Framework -> select ".Net Framework 4"the project will then save and reload.原创 2012-12-24 21:47:04 · 1404 阅读 · 0 评论 -
Send Meeting Request With C#
private void SendMeetingRequest() { SmtpClient sc = new SmtpClient("[smtp server address]"); MailMessage msg = new MailMessage(); msg.IsBodyHtml = true;原创 2013-07-10 23:43:21 · 1484 阅读 · 0 评论 -
简单实用的C#分词源代码(含词库素材下载)
一、词库 词库大概有5万多词语(Google能搜到,类似的词库都能用),我摘要如下: 地区 82 重要 81 新华社 80 技术 80 会议 80 自己 79 干部 78 职工 78 群众 77 没有 77 今天 76 同志 76 部门 75 加强 75 组织 75 点击下面链接下载中文词库素材(纯文本文件) http://w原创 2013-06-28 11:49:02 · 1297 阅读 · 0 评论