Hello!!
I compile this piece of code succesfully, but when I call it, nothing appears:
[red]
#include <stdio.h>
#include "HelloWorld.h" // this header file was generated by javah
void function(char *infile) {
printf("\n%s\n",infile);
}
JNIEXPORT void JNICALL Java_HelloWorld_displayMessage(JNIEnv *env, jobject obj) {
function("Hello World!"
;
}
[/red]
On the other hand, "Hello World" appears with this other:
[red]
#include <stdio.h>
#include "HelloWorld.h" // this header file was generated by javah
JNIEXPORT void JNICALL Java_HelloWorld_displayMessage(JNIEnv *env, jobject obj) {
printf("\nHello World!\n"
;
}
[/red]
Any suggestion?
I compile this piece of code succesfully, but when I call it, nothing appears:
[red]
#include <stdio.h>
#include "HelloWorld.h" // this header file was generated by javah
void function(char *infile) {
printf("\n%s\n",infile);
}
JNIEXPORT void JNICALL Java_HelloWorld_displayMessage(JNIEnv *env, jobject obj) {
function("Hello World!"
}
[/red]
On the other hand, "Hello World" appears with this other:
[red]
#include <stdio.h>
#include "HelloWorld.h" // this header file was generated by javah
JNIEXPORT void JNICALL Java_HelloWorld_displayMessage(JNIEnv *env, jobject obj) {
printf("\nHello World!\n"
}
[/red]
Any suggestion?