Click here to Skip to main content
15,917,005 members
Home / Discussions / C#
   

C#

 
AnswerRe: .parse vs casting Pin
Guffa11-Jan-06 11:17
Guffa11-Jan-06 11:17 
QuestionHow to get the IP address of the current host? Pin
bouli11-Jan-06 1:13
bouli11-Jan-06 1:13 
AnswerRe: How to get the IP address of the current host? Pin
mikailcetinkaya11-Jan-06 9:09
mikailcetinkaya11-Jan-06 9:09 
GeneralRe: How to get the IP address of the current host? Pin
Dave Kreskowiak11-Jan-06 9:34
mveDave Kreskowiak11-Jan-06 9:34 
AnswerRe: How to get the IP address of the current host? Pin
Dave Kreskowiak11-Jan-06 9:32
mveDave Kreskowiak11-Jan-06 9:32 
GeneralRe: How to get the IP address of the current host? Pin
bouli11-Jan-06 10:15
bouli11-Jan-06 10:15 
GeneralRe: How to get the IP address of the current host? Pin
Dave Kreskowiak11-Jan-06 10:53
mveDave Kreskowiak11-Jan-06 10:53 
QuestionFinger print scanner Access in C# Pin
Ckhurana11-Jan-06 0:51
Ckhurana11-Jan-06 0:51 
Hello,

I am trying to develop a simple application in dot net for the use of FUS-200N finger print scanner. I had downloaded quite a few samples but they fail to detect the scanner! I am writing code in C#. The earlier sample code is in VB6.0 and it runs fine. but due to incompatiblility I am not able to use those vb6 dll's as such in dot net.

Since I am developing this application for local use, i cannot afford the aid SDK's.

The VB6 application of mine is able to read from this scanner but I am unable to do this in the dot net (C#) environment.

I have to convert this funtion of vb6 to c#

Declare Function VFPSinit Lib "VFPSImg.dll" _
(ByVal sensorID As Long, _
ByRef numRows As Long, _
ByRef numCols As Long, _
ByRef mode As Long, _
ByVal configFile As Any, _
ByVal flags As Long, _
usrBkgndImage As Any, _
callBackFcn As Any _
) As Long


Question#1>>>>>
In C#, what is the meaning substitute of 'any' ??

also, it is being called like

"sensorHandle = VFPSinit(sensorID, numRows, numCols, 0&, 0&, flags, 0&, 0&)"

Question#2>>>>> What is 0& ? in vb6, how do i convert it to C# code ?


Following is my C# code...

Since I cannot call this dll directly as the IDE doesn't let me add it as a reference, I am using the P/Invoke.

// 1., To call the dll, following is the code

[ DllImport( "VFPSimg.dll")]
//Function #2
public static extern int VFPSinit(object sensorID, object numRows,
object numCols, object mode, object configFile,
long flags,object usrBkgndImage,object callBackFcn);

// 2., To call the function, following is the code

sensorHandle = ComFunc.VFPSinit(sensorID, numRows, numCols, 0, 0, flags, 0, 0);

After the above call, in the original VB6 code, I would succesfully get the numrows and numcols updated as they are sent via refernce, and the scanner sensorHandle would also be updated. I have even tried converting all the VB 6.0 long to integers in C# but to no avail.

If anyone ahs any idea about this sort of a thing in C#, and without usinffcommercial products, kindly get back!!

help me.. I am practically at my wits end!!

C.K.
AnswerRe: Finger print scanner Access in C# Pin
Dave Kreskowiak11-Jan-06 5:45
mveDave Kreskowiak11-Jan-06 5:45 
Questionobject initialization Pin
bidisha_tina11-Jan-06 0:06
bidisha_tina11-Jan-06 0:06 
AnswerRe: object initialization Pin
Colin Angus Mackay11-Jan-06 0:13
Colin Angus Mackay11-Jan-06 0:13 
GeneralRe: object initialization Pin
bidisha_tina11-Jan-06 0:29
bidisha_tina11-Jan-06 0:29 
GeneralRe: object initialization Pin
Colin Angus Mackay11-Jan-06 0:40
Colin Angus Mackay11-Jan-06 0:40 
GeneralRe: object initialization Pin
bidisha_tina11-Jan-06 0:51
bidisha_tina11-Jan-06 0:51 
QuestionEventHandling for Controls inserted(OLE way) in a RichTextBox Pin
Linda Thomas10-Jan-06 23:36
Linda Thomas10-Jan-06 23:36 
QuestionFlicker Free Drawing in C# Pin
AB777110-Jan-06 23:11
AB777110-Jan-06 23:11 
AnswerRe: Flicker Free Drawing in C# Pin
[Marc]11-Jan-06 1:44
[Marc]11-Jan-06 1:44 
GeneralRe: Flicker Free Drawing in C# Pin
AB777111-Jan-06 2:00
AB777111-Jan-06 2:00 
GeneralRe: Flicker Free Drawing in C# Pin
J4amieC11-Jan-06 2:29
J4amieC11-Jan-06 2:29 
GeneralRe: Flicker Free Drawing in C# Pin
[Marc]11-Jan-06 16:55
[Marc]11-Jan-06 16:55 
GeneralRe: Flicker Free Drawing in C# Pin
AB777111-Jan-06 17:23
AB777111-Jan-06 17:23 
GeneralRe: Flicker Free Drawing in C# Pin
AB777111-Jan-06 17:24
AB777111-Jan-06 17:24 
GeneralRe: Flicker Free Drawing in C# Pin
AB777111-Jan-06 18:20
AB777111-Jan-06 18:20 
GeneralRe: Flicker Free Drawing in C# Pin
[Marc]11-Jan-06 22:24
[Marc]11-Jan-06 22:24 
GeneralRe: Flicker Free Drawing in C# Pin
AB777111-Jan-06 23:50
AB777111-Jan-06 23:50 

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.