| 
| 
| 
| #193066 - 2009-03-23 02:35 PM  Help with DynaWrap/DynaCall... |  
| Viggen   Starting to like KiXtart
 
   Registered:  2002-03-22
 Posts: 110
 | 
Hi all!
 I have read the tutorials, on how to use DynaWrap/DynaCall, but I'm still lost on this one...
 
 I have include the dll I need to use, and I wonder if someone (Apronk?) could help me in the right direction on how to call it.
 
 I can get as far as creating the DynamicWrapper-object, but that's it
  
 T.I.A
 
 /Viggen
Attachments
 BCP5Control.zip  (1125 downloads)
 Description:
 
 
 
 
 |  
| Top |  |  |  |  
| 
| 
| #193105 - 2009-03-24 12:15 AM  Re: Help with DynaWrap/DynaCall...
[Re:  Shawn] |  
| Viggen   Starting to like KiXtart
 
   Registered:  2002-03-22
 Posts: 110
 | 
Umm... I might be missing something here...  but when I used the ocx, I didn't have a dll at all.
 
 and the "big" difference between the ocx and the dll is that the ocx used "DownloadData", while the dll uses "UploadRecords".
 (since this is waaaay out of my league, I don't know if it means anything)
  
 and about that "source code for the ocx... nope... they supplied a vb-file, so with that and typelib viewer I figured it out.
 
 Oh! and I forgot one thing... They sent a demo.exe which uses the dll, and that demo can get the data from the reader, into a textbox.
 
 /Viggen
 
 
 Edited by Viggen (2009-03-24 12:19 AM)
 |  
| Top |  |  |  |  
| 
| 
| #193107 - 2009-03-24 12:25 AM  Re: Help with DynaWrap/DynaCall...
[Re:  Shawn] |  
| Viggen   Starting to like KiXtart
 
   Registered:  2002-03-22
 Posts: 110
 | 
hmm... hang on... 
 I got this.
 
 (but, personally, since this is not my cup o' tea, I found out more, with the "Visual C++ express"-thingy)
Attachments
 BCP5000 SDK VS.NET2005.rar  (1103 downloads)
 Description:
 
 
 
 
 |  
| Top |  |  |  |  
| 
| 
| #193113 - 2009-03-24 06:58 AM  Re: Help with DynaWrap/DynaCall...
[Re:  Shawn] |  
| Viggen   Starting to like KiXtart
 
   Registered:  2002-03-22
 Posts: 110
 | 
Here's the ocx and the "sdk", that dosen't even work...
 I made a small test with the help from the vb-file, and from what I found in TypeLib Viewer.
 
 Perhaps I have missed something, since I can't get the data from it?
 
 Would KiXforms.NET work as a container?
 
 
 
 
 $Port = 12
$Pwd = "1234"
 
$bcreader = CreateObject("BCP5Ctrl.BCP5Controller")
?? @error
$open = $bcreader.OpenBCP($Pwd,$Port)
? $open
debug on
$text = $bcreader.DownloadData
; If $Port or $Pwd is wrong it displays "Device did not open", else it displays "Communication failed to establish."
 
$nul = $bcreader.EraseData
; Even though I get a "Communication failed...", (on the "DownloadData") it erases all data in the scanner.
; Which indicates that the comm. is in fact working?
 
$close = $bcreader.CloseBCP
 Attachments
 BCP5Ctrl.zip  (1012 downloads)
 Description:
 
 BCP5OCXDemo.zip  (1033 downloads)
 Description:
 
 
 
 
 Edited by Viggen (2009-03-24 07:06 AM)
 
 |  
| Top |  |  |  |  
| 
| 
| #193122 - 2009-03-24 02:50 PM  Re: Help with DynaWrap/DynaCall...
[Re:  Shawn] |  
| Shawn   Administrator
 
       
   Registered:  1999-08-13
 Posts: 8611
 | 
Does this vbscript version behave same (vbscript has better COM support) ... it appears to on my end ...
 
 
Dim bcReader 
Dim port
Dim password
Dim text
port = 12
password = "1234"
Set bcReader = CreateObject("BCP5Ctrl.BCP5Controller")
bcReader.OpenBCP password, port
WScript.Echo "Opened = " & bcReader.Opened
text = bcReader.DownloadData()
WScript.Echo "text = " & text
bcReader.CloseBCP
 |  
| Top |  |  |  |  
| 
| 
| #193126 - 2009-03-24 03:05 PM  Re: Help with DynaWrap/DynaCall...
[Re:  Shawn] |  
| Viggen   Starting to like KiXtart
 
   Registered:  2002-03-22
 Posts: 110
 | 
Yes, thats when I get the "Opened = False"    |  
| Top |  |  |  |  
 Moderator:  Shawn, ShaneEP, Ruud van Velsen, Arend_, Jochen, Radimus, Glenn Barnas, Allen, Mart
 
 | 
| 
 
| 0 registered
and 456 anonymous users online. 
 | 
 |  |