×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

How to fix the journal execution error.

How to fix the journal execution error.

How to fix the journal execution error.

(OP)
I use NX7.5.2.5 with TEAMCENTER at work.

3 errors occured when I played NX Journal.

First, "Microsoft Resource File To COFF Object Conversion Utility has stopped working"
Second, "Visual C# Command Line Compiler has stopped working"
Last, "Journal execution error" as attached screenshot.

I tried some ways to fix it but no result.
(sfc /scannow, registry cleaning, NX re-installing, delete anti-virus, etc)

It seems to me that NX can't load journal.dll(is compiled file) but don't know why.

Here's full log as below.

Please help me.

--------------------------------------------------------------------------------------------------
&MACRO EVENT ACTIVATE -30 5708, 11, 0, 0, 0! Play
&MACRO ASK_ITEM 13 (1 MTXT 5708) = 100
&MACRO LINE (1) "/*============================================================================="
&MACRO LINE (1) ""
&MACRO LINE (1) " Copyright (c) 2004 UGS PLM Solutions"
&MACRO LINE (1) " Unpublished - All rights reserved"
&MACRO LINE (1) ""
&MACRO LINE (1) "==============================================================================="
&MACRO LINE (1) "File description: Example for Wrapped UFUNC (NXOpen.NET)"
&MACRO LINE (1) "/* */"
&MACRO LINE (1) ""
&MACRO LINE (1) "using System;"
&MACRO LINE (1) "using System.IO;"
&MACRO LINE (1) "using NXOpen;"
&MACRO LINE (1) "using NXOpen.UF;"
&MACRO LINE (1) ""
&MACRO LINE (1) "namespace NetExample"
&MACRO LINE (1) "{"
&MACRO LINE (1) " /// <summary>"
&MACRO LINE (1) " /// Summary description for EX_Curve_CreateArc."
&MACRO LINE (1) " /// </summary>"
&MACRO LINE (1) " public class EX_Curve_CreateArc"
&MACRO LINE (1) " {"
&MACRO LINE (1) " private static FileStream fs; "
&MACRO LINE (1) " private static StreamWriter w;"
&MACRO LINE (1) " private static UFSession theUfSession;"
&MACRO LINE (1) " private static Session theSession;"
&MACRO LINE (1) ""
&MACRO LINE (1) " public int Execute()"
&MACRO LINE (1) " {"
&MACRO LINE (1) " Tag UFPart;"
&MACRO LINE (1) " string part_name = "EX_Curve_CreateArc";"
&MACRO LINE (1) " int units =2; "
&MACRO LINE (1) " string name;"
&MACRO LINE (1) " "
&MACRO LINE (1) " theUfSession.Part.New(part_name, units, out UFPart);"
&MACRO LINE (1) " theUfSession.Part.AskPartName(UFPart, out name);"
&MACRO LINE (1) " w.WriteLine("Loaded: " + name);"
&MACRO LINE (1) " "
&MACRO LINE (1) " Tag arc, wcs;"
&MACRO LINE (1) " UFCurve.Arc arc_coords = new UFCurve.Arc(); "
&MACRO LINE (1) " "
&MACRO LINE (1) " /* Fill out the data structure */"
&MACRO LINE (1) " arc_coords.start_angle = 0.0;"
&MACRO LINE (1) " arc_coords.end_angle = 3.0;"
&MACRO LINE (1) " arc_coords.arc_center=new double[3];"
&MACRO LINE (1) " arc_coords.arc_center[0] = 0.0;"
&MACRO LINE (1) " arc_coords.arc_center[1] = 0.0;"
&MACRO LINE (1) " arc_coords.arc_center[2] = 1.0;"
&MACRO LINE (1) " arc_coords.radius = 2.0;"
&MACRO LINE (1) " "
&MACRO LINE (1) " theUfSession.Csys.AskWcs(out wcs);"
&MACRO LINE (1) " theUfSession.Csys.AskMatrixOfObject(wcs,out arc_coords.matrix_tag);"
&MACRO LINE (1) " theUfSession.Curve.CreateArc(ref arc_coords,out arc);"
&MACRO LINE (1) " theUfSession.Part.Save();"
&MACRO LINE (1) " return 0;"
&MACRO LINE (1) " }"
&MACRO LINE (1) " public static void Main(string[] args)"
&MACRO LINE (1) " {"
&MACRO LINE (1) " theSession=Session.GetSession();"
&MACRO LINE (1) " theUfSession= UFSession.GetUFSession();"
&MACRO LINE (1) ""
&MACRO LINE (1) " fs = new FileStream("EX_Curve_CreateArc.log", FileMode.Create, FileAccess.Write);"
&MACRO LINE (1) " w = new StreamWriter(fs); // create a stream writer "
&MACRO LINE (1) " w.Write("Log Entry : \r\n");"
&MACRO LINE (1) " w.WriteLine("--Log entry goes here--"); "
&MACRO LINE (1) " w.Flush(); // update underlying file"
&MACRO LINE (1) ""
&MACRO LINE (1) " if ( File.Exists("EX_Curve_CreateArc.prt") ) "
&MACRO LINE (1) " {"
&MACRO LINE (1) " w.WriteLine("Remove EX_Curve_CreateArc.prt file from <Project Folder>\\bin\\Debug !!");"
&MACRO LINE (1) " w.WriteLine("EX_Curve_CreateArc.prt already exists. !!");"
&MACRO LINE (1) " w.Close();"
&MACRO LINE (1) " return;"
&MACRO LINE (1) " }"
&MACRO LINE (1) ""
&MACRO LINE (1) " try"
&MACRO LINE (1) " {"
&MACRO LINE (1) " EX_Curve_CreateArc curveTest1 = new EX_Curve_CreateArc();"
&MACRO LINE (1) " if (curveTest1.Execute()==0)"
&MACRO LINE (1) " {"
&MACRO LINE (1) " w.WriteLine("Successful");"
&MACRO LINE (1) " }"
&MACRO LINE (1) " else"
&MACRO LINE (1) " {"
&MACRO LINE (1) " w.WriteLine("Failed");"
&MACRO LINE (1) " }"
&MACRO LINE (1) " }"
&MACRO LINE (1) " catch(NXException e)"
&MACRO LINE (1) " { "
&MACRO LINE (1) " w.WriteLine("Exception is: {0}", e.Message);"
&MACRO LINE (1) " }"
&MACRO LINE (1) " w.WriteLine("End of Log File");"
&MACRO LINE (1) " w.Close();"
&MACRO LINE (1) " }"
&MACRO LINE (1) " public static int GetUnloadOption(string dummy) "
&MACRO LINE (1) " {"
&MACRO LINE (1) " return UFConstants.UF_UNLOAD_IMMEDIATELY;"
&MACRO LINE (1) " }"
&MACRO LINE (1) " }"
&MACRO LINE (1) "}"
&MACRO LINE (1) ""
Using D:\Siemens\NX75\ugii\managed\ManagedLoader.dll to load managed DLL
Trying to load D:\Siemens\NX75\ugii\managed\ManagedLoader.dll
ManagedLoader.Load: D:\Siemens\NX75\ugii\managed\NXOpen.Utilities.dll 이름:ctx://Journal6b92e452

컨텍스트 정책이 없습니다.


AppBase: D:\Siemens\NX75\ugii\managed\
Loaded assembly: NXOpen.Utilities, Version=4.0.0.0, Culture=neutral, PublicKeyToken=null from C:\Users\user\AppData\Local\assembly\dl3\561TTDC4.QQY\A3M443Y9.NHP\e46bccc1\00485f0d_ee58cb01\NXOpen.Utilities.DLL
Loaded assembly: System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 from C:\Windows\assembly\GAC_MSIL\System.Windows.Forms\2.0.0.0__b77a5c561934e089\System.Windows.Forms.dll
Loaded assembly: System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a from C:\Windows\assembly\GAC_MSIL\System.Drawing\2.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll
Adding D:\Siemens\NX75\ugii\managed\\NXOpen.Utilities.dll as a reference item
Adding D:\Siemens\NX75\ugii\managed\\NXOpen.dll as a reference item
Adding D:\Siemens\NX75\ugii\managed\\NXOpen.UF.dll as a reference item
Adding D:\Siemens\NX75\ugii\managed\\NXOpenUI.dll as a reference item


Journal execution results for D:\Siemens\NX75\UGOPEN\SampleNXOpenApplications\.NET\NXOpenExamples\EX_Curve_CreateArc.cs...
Runtime error:
SCRIPT_INVOKE
System.IO.FileNotFoundException: 파일이나 어셈블리 'file:///c:\Temp\ugs\NXJournals21712\journal.dll' 또는 여기에 종속되어 있는 파일이나 어셈블리 중 하나를 로드할 수 없습니다. 지정된 파일을 찾을 수 없습니다. /* <--- Korean sentence means "file or assembly can't be loaded, can't find the file." */
위치: System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
위치: System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
위치: System.Reflection.Assembly.Load(AssemblyName assemblyRef, Evidence assemblySecurity)
위치: System.CodeDom.Compiler.CompilerResults.get_CompiledAssembly()
위치: NXOpen.Utilities.CodeDomCompiler.get_Assembly()
위치: NXOpen.Utilities.ScriptHost.Run(String[] args, Boolean withUI)


&MACRO MESSAGE_BOX -2 SCRIPT_INVOKE
&MACRO MESSAGE_TEXT System.IO.FileNotFoundException: 파일이나 어셈블리 'file:///c:\Temp\ugs\NXJournals2171
&MACRO MESSAGE_TEXT 2\journal.dll' 또는 여기에 종속되어 있는 파일이나 어셈블리 중 하나를 로드할 수 없습니다. 지정된 파일
&MACRO MESSAGE_TEXT 을 찾을 수 없습니다.
&MACRO MESSAGE_TEXT 위치: System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBa
&MACRO MESSAGE_TEXT se, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFile
&MACRO MESSAGE_TEXT NotFound, Boolean forIntrospection)
&MACRO MESSAGE_TEXT 위치: System.Reflection.Assembly.InternalLoad(AssemblyName as
&MACRO MESSAGE_TEXT semblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
&MACRO MESSAGE_TEXT 위치:
&MACRO MESSAGE_TEXT System.Reflection.Assembly.Load(AssemblyName assemblyRef, Evidence assemblySecurity)
&MACRO MESSAGE_TEXT 위치: System
&MACRO MESSAGE_TEXT .CodeDom.Compiler.CompilerResults.get_CompiledAssembly()
&MACRO MESSAGE_TEXT 위치: NXOpen.Utilities.CodeDomCompiler.g
&MACRO MESSAGE_TEXT et_Assembly()
&MACRO MESSAGE_TEXT 위치: NXOpen.Utilities.ScriptHost.Run(String[] args, Boolean withUI)
&MACRO MESSAGE_TEXT

RE: How to fix the journal execution error.

For as far as I know (with my limited knowledge):
  • file:/// indicates a url so all slashes should be forward slahes,
    like this:

    CODE -->

    file:///c:/Temp/ugs/NXJournals21712/journal.dll 
    or the file part should be dropped:

    CODE -->

    c:\Temp\ugs\NXJournals21712\journal.dll 
  • for compiling outside of NX, a license is needed, otherwise it will not run, I think it's NX30104 or NX30106
    First, you need to compile the file, then sign it with a tool

Using NX 8.5 and 9.0 on Windows 7 (64)

RE: How to fix the journal execution error.

It appears that you are trying to replay one of the sample journals that ships with NX.

Quote (logfile)

Journal execution results for D:\Siemens\NX75\UGOPEN\SampleNXOpenApplications\.NET\NXOpenExamples\EX_Curve_CreateArc.cs...

It returns the error that the "journal.dll" file cannot be found. I'd guess the JIT compiler didn't create the file. Check to see that you have the .net framework installed on your computer (the same version that NX 7.5 needs - V2, if I remember correctly). Also install the .net framework service pack, it can be found here:
http://www.microsoft.com/en-us/download/details.as...

www.nxjournaling.com

RE: How to fix the journal execution error.

(OP)
Wouter79, Thank you but journal.dll file is automatically loaded by NX.
So I can't edit file path.

cowski, You're right! I think this problem is related with compiler.
Actually I tried to remove and re-install .NET Framework but it is not allowed under Windows 7.

I don't really wanna re-install OS and programs.... T.T

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources