Click here to Skip to main content
15,920,468 members
Home / Discussions / C#
   

C#

 
QuestionChanging all cursor types on a form Pin
fracalifa15-Dec-05 2:51
fracalifa15-Dec-05 2:51 
AnswerRe: Changing all cursor types on a form Pin
Polis Pilavas15-Dec-05 3:41
Polis Pilavas15-Dec-05 3:41 
GeneralRe: Changing all cursor types on a form Pin
fracalifa15-Dec-05 5:50
fracalifa15-Dec-05 5:50 
QuestionExtend NumericUpDown Pin
yala15-Dec-05 1:43
yala15-Dec-05 1:43 
QuestionDatabase migration tool Pin
AnonymousTwo15-Dec-05 1:34
AnonymousTwo15-Dec-05 1:34 
QuestionPreprocessKEy message DATAGRID column Pin
Greeky15-Dec-05 0:40
Greeky15-Dec-05 0:40 
QuestionExcel in C# Pin
Mahi.Ragava15-Dec-05 0:27
Mahi.Ragava15-Dec-05 0:27 
Questionevent handling Pin
Ankit Aneja14-Dec-05 23:34
Ankit Aneja14-Dec-05 23:34 
i am using com dll in my project which fires up event

code in vb is like this
Option Explicit
Dim WithEvents p As CLAMXLib.ClamEngine
Dim mresult As ClamResult

Private Sub p_OnScanComplete(ByVal result As CLAMXLib.IClamResult)
Set mresult = result
End Sub



in c#

CLAMXLib.ClamEngine p;
ClamResult mResult;

//now how will i catch events


code of class where i have to catch up event
public class clamresults
{
CLAMXLib.ClamEngine p;
ClamResult mResult;
public clamresults()
{
//
// TODO: Add constructor logic here
//
p=new ClamEngineClass();
p.Database.Path="E:\\projects backup\\ankitclam backup\\Clamtest\\database\\";

}
public string loadDatabase(string command,string dirpath)
{

if(command=="SCAN")
{
mResult=scanfile(dirpath);
}
else if(command=="RAWSCAN")
{
mResult=scanBuffer(dirpath);
}
else if(command=="CONTSCAN")
{
mResult=scandir(dirpath);
}

return mResult.Summary;

}
public ClamResult scandir(string dirpath)
{
p.Settings.ScanSupport=ClamSupport.Scan_Standard;
mResult= p.ScanDirectory(dirpath,0,ClamBoolType.False ,ClamBoolType.True);
return mResult;

}
public ClamResult scanfile(string dirpath)
{
p.Settings.ScanSupport=ClamSupport.Scan_Standard;
mResult=p.ScanFile(dirpath,ClamBoolType.True);
return mResult;

}
public ClamResult scanBuffer(string dirpath)
{
mResult=p.ScanBuffer(dirpath,ClamBoolType.False);
return mResult;
}



}

now how and where i will catch up events which will be generated from com dll



Ankit Aneja
"Nothing is impossible. The word itself says - I M possible"


-- modified at 6:23 Thursday 15th December, 2005
QuestionObject pooling in C# Pin
rana7414-Dec-05 23:07
rana7414-Dec-05 23:07 
AnswerRe: Object pooling in C# Pin
S. Senthil Kumar15-Dec-05 4:50
S. Senthil Kumar15-Dec-05 4:50 
QuestionTime out exception Pin
manojk_batra14-Dec-05 22:51
manojk_batra14-Dec-05 22:51 
AnswerRe: Time out exception Pin
Guffa15-Dec-05 1:27
Guffa15-Dec-05 1:27 
GeneralRe: Time out exception Pin
manojk_batra15-Dec-05 1:50
manojk_batra15-Dec-05 1:50 
AnswerRe: Time out exception Pin
Guffa18-Dec-05 1:29
Guffa18-Dec-05 1:29 
GeneralRe: Time out exception Pin
manojk_batra18-Dec-05 17:42
manojk_batra18-Dec-05 17:42 
Questionquestion Pin
eyalso14-Dec-05 22:45
eyalso14-Dec-05 22:45 
AnswerRe: question Pin
albCode14-Dec-05 22:50
albCode14-Dec-05 22:50 
GeneralRe: question Pin
J4amieC15-Dec-05 0:28
J4amieC15-Dec-05 0:28 
AnswerRe: question Pin
Gilad Kapelushnik17-Dec-05 23:35
Gilad Kapelushnik17-Dec-05 23:35 
QuestionDatatypes in Excel Sheet Pin
Mahi.Ragava14-Dec-05 22:41
Mahi.Ragava14-Dec-05 22:41 
Questioninstalling application to a server Pin
bwagz14-Dec-05 22:40
bwagz14-Dec-05 22:40 
Questiondate validity Pin
fmardani14-Dec-05 22:38
fmardani14-Dec-05 22:38 
AnswerRe: date validity Pin
tatchung14-Dec-05 23:12
tatchung14-Dec-05 23:12 
AnswerRe: date validity Pin
Polis Pilavas15-Dec-05 2:17
Polis Pilavas15-Dec-05 2:17 
QuestionHow to add a TextBox control into a ToolBar? Pin
Andrew010514-Dec-05 22:22
Andrew010514-Dec-05 22:22 

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.