473,396 Members | 1,866 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Function pointers in .NET?

Hi,

Can anyone tell me if there's any easy way to set up a function pointer in
VB.NET?

Thanks
Nov 20 '05 #1
4 821
See Delegate.

"Scott Kilbourn" <sk*******@nospamplease.appliedsystems.com> wrote in
message news:e4*************@TK2MSFTNGP09.phx.gbl...
Hi,

Can anyone tell me if there's any easy way to set up a function pointer in
VB.NET?

Thanks

Nov 20 '05 #2
Thanks!

I never realized that delegates could do so much... :)

"CJ Taylor" <no****@blowgoats.com> wrote in message
news:10*************@corp.supernews.com...
See Delegate.

"Scott Kilbourn" <sk*******@nospamplease.appliedsystems.com> wrote in
message news:e4*************@TK2MSFTNGP09.phx.gbl...
Hi,

Can anyone tell me if there's any easy way to set up a function pointer in VB.NET?

Thanks


Nov 20 '05 #3
Neither did I... they are fun. =)
"Scott Kilbourn" <sk*******@nospamplease.appliedsystems.com> wrote in
message news:un*************@TK2MSFTNGP09.phx.gbl...
Thanks!

I never realized that delegates could do so much... :)

"CJ Taylor" <no****@blowgoats.com> wrote in message
news:10*************@corp.supernews.com...
See Delegate.

"Scott Kilbourn" <sk*******@nospamplease.appliedsystems.com> wrote in
message news:e4*************@TK2MSFTNGP09.phx.gbl...
Hi,

Can anyone tell me if there's any easy way to set up a function
pointer
in VB.NET?

Thanks



Nov 20 '05 #4
* "Scott Kilbourn" <sk*******@nospamplease.appliedsystems.com> scripsit:
Can anyone tell me if there's any easy way to set up a function pointer in
VB.NET?


Delegates (type-safe function pointers). When working with the Win32
API, you may want to have a look at
'<MarshalAs(UnmanagedType.FunctionPtr)>' too.

--
Herfried K. Wagner [MVP]
<http://dotnet.mvps.org/>
Nov 20 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Markus Dehmann | last post by:
I have a class "Data" and I store Data pointers in an STL set. But I have millions of inserts and many more lookups, and my profiler found that they cost a lot of runtime. Therefore, I want to...
89
by: Sweety | last post by:
hi, Is main function address is 657. its show in all compiler. try it & say why? bye,
3
by: Dennis Chang | last post by:
Hi all, I was reading about function pointers and came across something which intrigued me. K&R2 calls qsort (pg.119) within main as so: qsort( (void **) lineptr, 0, nlines-1, (int (*) (void...
41
by: Alexei A. Frounze | last post by:
Seems like, to make sure that a pointer doesn't point to an object/function, NULL (or simply 0) is good enough for both kind of pointers, data pointers and function pointers as per 6.3.2.3: 3 An...
12
by: Bill Pursell | last post by:
The following code generates a compiler warning when compiled with gcc -pedantic: typedef (*FUNC)(int); FUNC f; void * get_f(void) { return &f;
57
by: Robert Seacord | last post by:
i am trying to print the address of a function without getting a compiler warning (i am compiling with gcc with alot of flags). if i try this: printf("%p", f); i get: warning: format %p...
54
by: John | last post by:
Is the following program print the address of the function? void hello() { printf("hello\n"); } void main() { printf("hello function=%d\n", hello); }
4
by: Christian Maier | last post by:
Hi After surfing a while I have still trouble with this array thing. I have the following function and recive a Segmentation fault, how must I code this right?? Thanks Christian Maier
4
by: Josefo | last post by:
Hello, is someone so kind to tell me why I am getting the following errors ? vector_static_function.c:20: error: expected constructor, destructor, or type conversion before '.' token...
32
by: copx | last post by:
Why doesn't the C standard include generic function pointers? I use function pointers a lot and the lack of generic ones is not so cool. There is a common compiler extension (supported by GCC...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.