I think I had that one before. Try this one:
How do get the address of a function in naked assembly code? void foo() { asm { naked; mov EAX, &foo; } } This doesn't work...