Click here to Skip to main content
15,922,584 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralHelp Recording Audio Pin
GeneArnold9-Feb-05 3:12
GeneArnold9-Feb-05 3:12 
GeneralRe: App.Path (vb.net) Pin
Just Greeky Creek9-Feb-05 0:16
Just Greeky Creek9-Feb-05 0:16 
GeneralRe: App.Path (vb.net) Pin
Ritesh12349-Feb-05 0:23
Ritesh12349-Feb-05 0:23 
GeneralCustom Shaped Window (form) Pin
Member 86210338-Feb-05 22:49
Member 86210338-Feb-05 22:49 
GeneralRe: Custom Shaped Window (form) Pin
Just Greeky Creek9-Feb-05 0:18
Just Greeky Creek9-Feb-05 0:18 
GeneralRe: Custom Shaped Window (form) Pin
Kumar saurabh9-Feb-05 20:16
Kumar saurabh9-Feb-05 20:16 
GeneralRe: Custom Shaped Window (form) Pin
Just Greeky Creek9-Feb-05 20:44
Just Greeky Creek9-Feb-05 20:44 
QuestionCan someone help with this one Pin
Delo8-Feb-05 19:58
Delo8-Feb-05 19:58 
Mad | :mad: I have been textbook programming out of a book called network programming in.net in the book instructs me to go to a couple of sites and download winpcap and rvpacket because we will need these two to build the next project well I did so I have completed the project everything looked good until I run the project I get the error "An unhandled exception of type 'System.NullReferenceException' occurred in WebInfo.exe Additional information: Object reference not set to an instance of anobject."
at the beginning of the project it did tell me to add a reference to Microsoft.visualbasic.compatibility I am at a complete loss could someone please help me the error is on the line below "packetquery = checkpacket query(adapter)"

-----------------------------------------------------------------------------
Option Strict Off
Public Class Form1
Inherits System.Windows.Forms.Form
Mad | :mad:

Private Sub btnstart_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnstart.Click
Dim Qid As Short
Dim PacketBuffer As String
Dim Adapters() As String
Dim openSuccess As Short
Dim PacketQueue As Short
Dim PacketLen As Short
Dim rawAdapterDetails As String
Dim posDefaultAdapter As Short
rawAdapterDetails = Space(MAX_ADAPTER_LEN)
getAdapterNames(rawAdapterDetails)
posDefaultAdapter = rawAdapterDetails.IndexOf(ADAPTER_DELIMITER)
Adapter = rawAdapterDetails.Substring(0, posDefaultAdapter)
openSuccess = openAdapter(Adapter)
If openSuccess <> ERR_SUCCESS Then
MsgBox("unable to start. check wincap is installer")
Exit Sub
End If
Do
PacketQueue = checkPacketQueue(Adapter)
For Qid = 1 To PacketQueue
PacketBuffer = Space(MAX_PACKET_SIZE)
PacketLen = getQueuedPacket(PacketBuffer)
PacketBuffer = PacketBuffer.Substring(0, PacketLen)
tbpackets.Text = tbpackets.Text & Replace(PacketBuffer, Chr(0), "")
tbpackets.SelectionStart = Len(tbpackets.Text)
System.Windows.Forms.Application.DoEvents()
Next
System.Windows.Forms.Application.DoEvents()
Loop
End Sub

Private Sub btnstop_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnstop.Click
closeAdapter(Adapter)
End Sub

Private Declare Function getAdapterNames Lib "rvpacket.dll" (ByVal s As String) As Short
Private Declare Function openAdapter Lib "rvpacket.dll" (ByVal Adapter As String) As Short
Private Declare Function checkPacketQueue Lib "rvpacket.dll" (ByVal Adapter As String) As Short
Private Declare Function getQueuedPacket Lib "rvpacket.dll" (ByVal s As String) As Short
Private Declare Sub closeAdapter Lib "rvpacket.dll" (ByVal Adapter As String)


Private Const SIMULTANEOUS_READS As Short = 10
Private Const MAX_ADAPTER_LEN As Short = 512
Private Const ADAPTER_DELIMITER As String = "|"
Private Const MAX_PACKET_SIZE As Short = 10000
Private Const ERR_SUCCESS As Short = 1
Private Const ERR_ADAPTER_ID As Short = 2
Private Const ERR_INVALID_HANDLE As Short = 3
Private Const ERR_INVALID_ADAPTER As Short = 4
Private Const ERR_ALLOCATE_PACKET As Short = 5
Public Adapter As String
End Class
AnswerRe: Can someone help with this one Pin
Dave Kreskowiak9-Feb-05 2:36
mveDave Kreskowiak9-Feb-05 2:36 
QuestionHow To Search in Database in Access Using Adodc Pin
Max's8-Feb-05 19:56
sussMax's8-Feb-05 19:56 
Generalget_URL Pin
students552 university8-Feb-05 19:44
students552 university8-Feb-05 19:44 
QuestionHow can I corrupt a folder or restrict the access to it? (VB 6) Pin
AngryC8-Feb-05 17:55
AngryC8-Feb-05 17:55 
AnswerRe: How can I corrupt a folder or restrict the access to it? (VB 6) Pin
Christian Graus9-Feb-05 10:05
protectorChristian Graus9-Feb-05 10:05 
AnswerRe: How can I corrupt a folder or restrict the access to it? (VB 6) Pin
Dave Kreskowiak9-Feb-05 10:14
mveDave Kreskowiak9-Feb-05 10:14 
QuestionHow can I change the file/folder index? (VB 6) Pin
AngryC8-Feb-05 17:54
AngryC8-Feb-05 17:54 
AnswerRe: How can I change the file/folder index? (VB 6) Pin
Dave Kreskowiak9-Feb-05 16:43
mveDave Kreskowiak9-Feb-05 16:43 
QuestionHow can I hide the size of a hidden folder? (VB 6) Pin
AngryC8-Feb-05 17:53
AngryC8-Feb-05 17:53 
AnswerRe: How can I hide the size of a hidden folder? (VB 6) Pin
Dave Kreskowiak9-Feb-05 16:46
mveDave Kreskowiak9-Feb-05 16:46 
QuestionHow can I encrypt a folder? (VB 6) Pin
AngryC8-Feb-05 17:52
AngryC8-Feb-05 17:52 
AnswerRe: How can I encrypt a folder? (VB 6) Pin
Dave Kreskowiak9-Feb-05 16:47
mveDave Kreskowiak9-Feb-05 16:47 
Questionhow to accesses linux registry using vb.net Pin
friendsyaadein8-Feb-05 17:28
friendsyaadein8-Feb-05 17:28 
AnswerRe: how to accesses linux registry using vb.net Pin
Dave Kreskowiak9-Feb-05 16:41
mveDave Kreskowiak9-Feb-05 16:41 
GeneralCryptography Pin
nitin_ion8-Feb-05 16:28
nitin_ion8-Feb-05 16:28 
GeneralRe: Cryptography Pin
Dave Kreskowiak9-Feb-05 16:39
mveDave Kreskowiak9-Feb-05 16:39 
GeneralProblem in Sql Command Pin
sriwirko8-Feb-05 15:58
sriwirko8-Feb-05 15:58 

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.