Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

C#ÖÐʹÓÃDataTableÏÔʾAccessÊý¾Ý¿âÖÐÎļþÁбí


private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
             this.comboBox2.Items.Clear();
            switch(this.comboBox1.SelectedIndex)
            {
             case 0:
                  try
                    {
                        OleDbConnection conn = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;User ID=admin;Data Source=C:\tmpAccess\DataBase1.mdb");
                        conn.Open();
                        if(conn.State == System.Data.ConnectionState.Open){
                            Console.WriteLine("Success");
                        }
                        DataTable test = conn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, new Object[] { null, null, null, "Table" });
                        this.dataGridView1.DataSource =test;
                        int tableIndex = test.Columns.IndexOf("TABLE_NAME");
                        foreach (DataRow row in test.Rows)
                            comboBox2.Items.Add(row[tableIndex].ToString());
     &nb


Ïà¹ØÎĵµ£º

access ÖеÄÎı¾µ½Êý¾ÝÀàÐ͵Äת»»

ÓÃCdbl()ÊÔÊÔ
CDbl(str)   -->   Ë«¾«¶È
CInt(str)   -->   ÕûÐÍ
CLng(str)   -->   ³¤ÕûÐÍ
CSng(str)   -->   µ¥¾«¶È
CDate(str)   -->   ÈÕÆÚÐÍ ......

MD5¼ÓÃܵÄÒ»°ã·½·¨(ASP.NET / C#2005)

  /// <summary>
/// ·½·¨Ò»:ͨ¹ýʹÓà new ÔËËã·û´´½¨¶ÔÏó
/// </summary>
/// <param name="strSource">ÐèÒª¼ÓÃܵÄÃ÷ÎÄ</param>
/// <returns>·µ»Ø16λ¼ÓÃܽá¹û£¬¸Ã½á¹ûÈ¡32λ¼ÓÃܽá¹ûµÄµÚ9λµ½25λ</returns>
public string Get_MD5_Method1(strin ......

C#´¦Àíoracle lobµÄÀý×Ó

  protected void BindData1()
    {
        OracleConnection orcn = new OracleConnection("User ID=wesoftwcp; Password=wesoft; Data Source=oradb");
        orcn.Open();
      &nb ......

C#ÖжÔXML½Úµã½øÐÐÔöɾ¸Ä²é

ºÅ³ÆxmlhelperµÄÒ»¸öÀà
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Xml;
namespace WebApplication2
{
/// <summary>
/// XMLHelper XMLÎĵµ²Ù×÷¹ÜÀíÆ÷
/// </summary>
public class XMLHelper
{
public X ......

ÈçºÎ¼ÆËãMS SQLÓï¾äÖ´ÐеÄʱ¼ä»¹ÓÐc#


MSSQL:
declare @begin datetime
declare @End datetime
set @begin=getdate()
   --Ö´ÐеÄÓï¾äдÔÚÕâÀï
set @End=getdate()
select datediff(millisecond,@begin,@End) as Ö´ÐеÄʱ¼ä
--millisecond±íʾºÁÃë Èç¹û¿´Ãë¿ÉÒÔʹÓÃss
C#:
ºÜ¶àʱº ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ