<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2802" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT size=2>Hi Ashish,</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>regarding the remote-ext.h file, you should *not* include that
file explicitely, instead you should define the preprocessor directives WPCAP
and HAVE_REMOTE in order to have that file automatically included by pcap.h.
Including remote-ext.h directly can cause linking problems.</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>Regarding the typeLoadException, this is generated by the CLR
(Common Language Runtime) of .NET. More details on it can be found
here:</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2><A
href="http://www.mail-archive.com/winpcap-users@winpcap.polito.it/msg02138.html">http://www.mail-archive.com/winpcap-users@winpcap.polito.it/msg02138.html</A></FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>Have a nice day</FONT></DIV>
<DIV><FONT size=2>GV</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2></FONT> </DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=ashish_frnds@yahoo.co.in
href="mailto:ashish_frnds@yahoo.co.in">ashish yadav</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=winpcap-users@winpcap.org
href="mailto:winpcap-users@winpcap.org">winpcap-users@winpcap.org</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Monday, February 06, 2006 9:22
PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [Winpcap-users] error while
compiling programmes in visualstudio.net</DIV>
<DIV><BR></DIV>
<DIV>hi Gianluca..</DIV>
<DIV>sorry for replying soo late..had exams..</DIV>
<DIV>so the code i was using was actually the example given in documentation
of winpcap.</DIV>
<DIV>and also the problems regarding pcap_if_src_string not identified and
others like this were solved when i used remote-ext.h header file...</DIV>
<DIV>anyway there was a runtime exception....which i couldn't understand hope
u can help..</DIV>
<DIV>here is the code i was using..>>></DIV>
<DIV> </DIV>
<DIV><SPAN class=preprocessor>#include "pcap.h"</SPAN><BR>#include
<remote-ext.h><BR>main()<BR>{<BR> <A class=code
href="http://www.winpcap.org/docs/docs32a1/html/structpcap__if.html">pcap_if_t</A>
*alldevs;<BR> <A class=code
href="http://www.winpcap.org/docs/docs32a1/html/structpcap__if.html">pcap_if_t</A>
*d;<BR> <SPAN class=keywordtype>int</SPAN>
i=0;<BR> <SPAN class=keywordtype>char</SPAN> errbuf[<A
class=!
href="http://www.winpcap.org/docs/docs32a1/html/group__wpcap__def.html#ga8"
code>PCAP_ERRBUF_SIZE</A>];<BR> <BR> <SPAN
class=comment>/* Retrieve the device list from the local machine
*/</SPAN><BR> <SPAN class=keywordflow>if</SPAN> (<A
class=code
href="http://www.winpcap.org/docs/docs32a1/html/group__wpcapfunc.html#ga55">pcap_findalldevs_ex</A>(PCAP_SRC_IF_STRING,
NULL <SPAN class=comment>/* auth is not needed */</SPAN>, &alldevs,
errbuf) == -1)<BR>
{<BR> fprintf(stderr,<SPAN
class=stringliteral>"Error in pcap_findalldevs_ex: %s\n"</SPAN>,
errbuf);<BR>
exit(1);<BR> }<BR> <BR>
<SPAN class=comment>/* Print the list */</SPAN><BR> <SPAN
class=keywordflow>for</SPAN>(d= alldevs; d != NULL; d= d-><A class=code
href="http://www.winpcap.org/docs/docs32a1/html/structpcap__if.html#o0">next</A>)<BR>
{<BR> printf(<SPAN
class=stringliteral>"%d. %s"</SPAN>, ++i, d-><A class=code
href="http://www.winpcap.org/docs/docs32a1/html/structpcap__if.html#o1">name</A>);<BR>
<SPAN class=keywordflow>if</SPAN> (d-><A class=code
href="http://www.winpcap.org/docs/docs32a1/html/structpcap__if.html#o2">description</A>)<BR>
printf(<SPAN class=stringliteral>" (%s)\n"</SPAN>, d-><A class=code
href="http://www.winpcap.org/docs/docs32a1/html/structpcap__if.html#o2">description</A>);<BR>
<SPAN
class=keywordflow>else</SPAN><BR>
printf(<SPAN class=stringliteral>" (No description
available)\n"</SPAN>);<BR> }<BR>
<BR> <SPAN class=keywordflow>if</SPAN> (i ==
0)<BR> {<BR>
printf(<SPAN class=stringliteral>"\nNo interfaces found! Make sure WinPcap is
installed.\n"</SPAN>);<BR> <SPAN
class=keywordflow>return</SPAN>;<BR>
}<BR><BR> <SPAN class=comment>/* We don't need any more the
device list. Free it */</SPAN><BR> <A class=code
href="http://www.winpcap.org/docs/docs32a1/html/group__wpcapfunc.html#ga8">pcap_freealldevs</A>(alldevs);<BR>}<BR></DIV>
<DIV> </DIV>
<DIV>and the error i got was..</DIV>
<DIV>typeload.exception..</DIV>
<DIV>could not load pcap assembly from netmonui(that's the name of my
project)..</DIV>
<DIV>if u need any more details jus tell me,,...</DIV>
<DIV>take care..</DIV>
<DIV>ashish</DIV>
<P>
<HR SIZE=1>
Jiyo cricket on <A
href="http://us.rd.yahoo.com/mail/in/mailcricket/*http://in.sports.yahoo.com/cricket/">Yahoo!
India cricket</A>
<P>
<HR>
<P></P>_______________________________________________<BR>Winpcap-users
mailing
list<BR>Winpcap-users@winpcap.org<BR>https://www.winpcap.org/mailman/listinfo/winpcap-users<BR></BLOCKQUOTE></BODY></HTML>