Click here to Skip to main content
15,897,226 members
Home / Discussions / C#
   

C#

 
AnswerRe: WeakReferences and the background garbage collector Pin
Guffa16-May-06 12:34
Guffa16-May-06 12:34 
QuestionXML and sorting Pin
donkaiser16-May-06 8:44
donkaiser16-May-06 8:44 
AnswerRe: XML and sorting Pin
Rei Miyasaka16-May-06 11:30
Rei Miyasaka16-May-06 11:30 
GeneralRe: XML and sorting Pin
donkaiser17-May-06 18:50
donkaiser17-May-06 18:50 
GeneralRe: XML and sorting Pin
Rei Miyasaka18-May-06 7:08
Rei Miyasaka18-May-06 7:08 
GeneralRe: XML and sorting Pin
donkaiser19-May-06 10:41
donkaiser19-May-06 10:41 
GeneralRe: XML and sorting [modifed] Pin
Rei Miyasaka19-May-06 13:54
Rei Miyasaka19-May-06 13:54 
QuestionJNI_CreateJavaVM Pin
pwimmers16-May-06 8:29
pwimmers16-May-06 8:29 
I am writing some code in C# and have the need to call a third party java api. I am attempting to write a C++ dll that can be called from
C# -> C++ -> Java -> Java API.

Everytime I make a call to JNI_CreateJavaVM from Java I get a JNI_ERR or -1

I do have a java class file in the same directory.
I also have the location of jvm.dll in the system path variable.
Also, if I run the C++ code as a stand-alone executable instead of a DLL it works.

Any Help would be appreciated.

Thanks


JNIEnv *env;
JavaVM *jvm;
jint res;
JavaVMInitArgs vm_args;
avaVMOption options[1];

options[0].optionString = "-Djava.class.path=C: \\CsstProductInterface.jar";
vm_args.version = JNI_VERSION_1_2;
vm_args.options = options;
vm_args.nOptions = 1;
vm_args.ignoreUnrecognized = JNI_TRUE;

res = JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args);

if(res < 0)
{
AddToLog("UNABLE to start JVM\n\n");
}




Pat
QuestionCollection was modified; Enumeration Operation may not execute Pin
Vijju200616-May-06 6:50
Vijju200616-May-06 6:50 
AnswerRe: Collection was modified; Enumeration Operation may not execute Pin
carlop()16-May-06 6:55
carlop()16-May-06 6:55 
GeneralRe: Collection was modified; Enumeration Operation may not execute Pin
Vijju200616-May-06 7:13
Vijju200616-May-06 7:13 
GeneralRe: Collection was modified; Enumeration Operation may not execute Pin
carlop()16-May-06 21:15
carlop()16-May-06 21:15 
QuestionA beginnering question Pin
mehrdadc4816-May-06 6:13
mehrdadc4816-May-06 6:13 
AnswerRe: A beginnering question Pin
Vikram A Punathambekar16-May-06 6:26
Vikram A Punathambekar16-May-06 6:26 
AnswerRe: A beginnering question Pin
coolvinx16-May-06 11:23
coolvinx16-May-06 11:23 
QuestionXML Remove Node Problem Pin
Phoen2516-May-06 6:07
Phoen2516-May-06 6:07 
AnswerRe: XML Remove Node Problem Pin
Phoen2516-May-06 6:40
Phoen2516-May-06 6:40 
QuestionRight click on flash player Pin
mehrdadc4816-May-06 5:58
mehrdadc4816-May-06 5:58 
Questionbuild vs rebuild Pin
mehrdadc4816-May-06 5:56
mehrdadc4816-May-06 5:56 
AnswerRe: build vs rebuild Pin
Rob Philpott16-May-06 5:59
Rob Philpott16-May-06 5:59 
AnswerRe: build vs rebuild Pin
Guffa16-May-06 7:09
Guffa16-May-06 7:09 
GeneralRe: build vs rebuild Pin
Robert Rohde16-May-06 8:17
Robert Rohde16-May-06 8:17 
QuestionDraw in web Pin
papa198016-May-06 5:39
papa198016-May-06 5:39 
AnswerRe: Draw in web Pin
MoustafaS16-May-06 8:02
MoustafaS16-May-06 8:02 
AnswerRe: Draw in web Pin
Jakob Farian Krarup16-May-06 8:20
Jakob Farian Krarup16-May-06 8:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.