0

In an iPhone application, I have some plain C functions. Is it possible to access UI elements (declared on viewcontroller) in these functions?

Thanks.

paul simmons
  • 5,568
  • 13
  • 51
  • 78
  • Do you want to access a variable declared one view in another view? – Warrior Feb 25 '10 at 10:57
  • Well, in fact I have C functions not declared inside .h file, but directly implemented in .m file. I can call them inside view's methods, however inside those C functions I can't access UI elements – paul simmons Feb 25 '10 at 11:11
  • Yes, is possible. Is't it easier to write the function in OBjective-C? – mxg Feb 25 '10 at 13:31

1 Answers1

0

Paul, hopefully you will find this thread helpful: Unable to call an Objective C method from a C function

Community
  • 1
  • 1
davecom
  • 1,499
  • 10
  • 30