Click here to Skip to main content
15,895,011 members
Home / Discussions / C#
   

C#

 
AnswerRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
Edwin Syarief29-Jul-07 19:12
Edwin Syarief29-Jul-07 19:12 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 20:39
jacklynn_mei29-Jul-07 20:39 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
Edwin Syarief29-Jul-07 21:20
Edwin Syarief29-Jul-07 21:20 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 21:45
jacklynn_mei29-Jul-07 21:45 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
Edwin Syarief29-Jul-07 22:04
Edwin Syarief29-Jul-07 22:04 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 22:20
jacklynn_mei29-Jul-07 22:20 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
Edwin Syarief29-Jul-07 22:26
Edwin Syarief29-Jul-07 22:26 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 22:40
jacklynn_mei29-Jul-07 22:40 
At first I do like This

=> using System;
using System.Collections.Generic;
using System.Text.RegularExpressions;
using Microsoft.CSharp;
using Microsoft.SqlServer.Server;
using System.Data;
using System.Data.SqlClient;


namespace AITania
{
class Program
{
//public static void InsertTrigger()
//{
// SqlTriggerContext triggerContext = SqlContext.GetTriggerContext();
// SqlPipe sqlPipe = SqlContext.GetPipe();
// SqlCommand command = SqlContext.GetCommand();
// if (triggerContext.TriggerAction == System.Data.Sql.TriggerAction.Insert)
// {

// command.CommandText = "SELECT * FROM INSERTED";
// sqlPipe.Execute(command);
// }
//}


static void Main(string[] args)
{
//---------------------------Database connection
SqlConnection conn = new SqlConnection("Data Source=DIMENSION3000\\SQLEXPRESS; Initial Catalog=AITania; User Id=sa; Password=123456");
DataSet AlertDataSet = new DataSet();
SqlDataAdapter da;
SqlCommandBuilder cmdBuilder;

//--------------------------Open Connection
conn.Open();
da = new SqlDataAdapter("SELECT * FROM AIEvent", conn);
cmdBuilder = new SqlCommandBuilder(da);
da.Fill(AlertDataSet, "AIEvent");


//-------------------------Displaying error
foreach (DataRow dr in AlertDataSet.Tables[0].Rows)
{
Console.WriteLine("EventID: {0}", dr["EventID"]);
Console.WriteLine("Time of Occur: {0}", dr["TimeOfOccur"]);
Console.WriteLine("Location: {0}", dr["LocationID"]);
Console.WriteLine("");
}
Console.ReadLine();

//--------------------------Close Connection
conn.Close();
//AIClass.AICheck.checkUserRole();

}
}
}

GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 22:43
jacklynn_mei29-Jul-07 22:43 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
Edwin Syarief29-Jul-07 22:53
Edwin Syarief29-Jul-07 22:53 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 23:09
jacklynn_mei29-Jul-07 23:09 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
Edwin Syarief29-Jul-07 23:17
Edwin Syarief29-Jul-07 23:17 
GeneralRe: how to do the sqlClr connection & deploy it in c# Express Edition? Pin
jacklynn_mei29-Jul-07 23:27
jacklynn_mei29-Jul-07 23:27 
QuestionConnecting password protected MS Access database from C# Pin
Nadia Monalisa29-Jul-07 15:30
Nadia Monalisa29-Jul-07 15:30 
AnswerRe: Connecting password protected MS Access database from C# Pin
Luis Alonso Ramos29-Jul-07 16:12
Luis Alonso Ramos29-Jul-07 16:12 
GeneralRe: Connecting password protected MS Access database from C# Pin
Nadia Monalisa29-Jul-07 16:17
Nadia Monalisa29-Jul-07 16:17 
AnswerRe: Connecting password protected MS Access database from C# Pin
Paul Conrad29-Jul-07 16:57
professionalPaul Conrad29-Jul-07 16:57 
QuestionC# console application Pin
Saamir29-Jul-07 13:26
Saamir29-Jul-07 13:26 
AnswerRe: C# console application Pin
Luc Pattyn29-Jul-07 13:43
sitebuilderLuc Pattyn29-Jul-07 13:43 
AnswerRe: C# console application Pin
Christian Graus29-Jul-07 13:44
protectorChristian Graus29-Jul-07 13:44 
AnswerRe: C# console application Pin
Paul Conrad29-Jul-07 17:12
professionalPaul Conrad29-Jul-07 17:12 
QuestionInteracting with Exchange Server 2003? Pin
wbjohnson29-Jul-07 13:12
wbjohnson29-Jul-07 13:12 
AnswerRe: Interacting with Exchange Server 2003? Pin
ekynox29-Jul-07 20:46
ekynox29-Jul-07 20:46 
QuestionSimulate Serial Port Pin
Erosares229-Jul-07 12:38
Erosares229-Jul-07 12:38 
AnswerRe: Simulate Serial Port Pin
Luc Pattyn29-Jul-07 13:00
sitebuilderLuc Pattyn29-Jul-07 13:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.