Converting jcharArray to const char*
843829Mar 4 2003 — edited Mar 11 2003Hello everyone.
This is my first time posting a problem, and I hope you can help me out. I have a JNI function that takes as an argument a Java character array (expressed as a jcharArray in the JNI function argument list). What I am trying to do is convert that array into a const char* pointer for use with some existing C++ code. I've been trying lots of different JNI function combinations (GetCharArrayElements, GetCharArrayRegion, etc.), but have not come up with a winning combination yet. Any suggestions? Thanks.