Cancel
Showing results for 
Search instead for 
Did you mean: 

Error to execute ".dll file

Creator
Creator

Halo semuanya...

 

Saya baru menggunakan NXOPEN dan menggunakan editor jurnal NX dan mencoba untuk belajar dari awal.

 

Saya mencoba membuat satu kode dari beberapa refrence dan mengkompilasi kode dengan "Visual Studio" ..

 

Ketika saya menjalankan file ".DLL", saya mendapatkan pesan kesalahan seperti ini ...

 

"Kesalahan di pustaka eksternal. Lihat log sistem untuk detail"

 

Capture1.JPG

 

dan saya melihat seperti ini di file log sistem

 

& MACRO FILE_BOX -2, @@@ C: \ Users \ Design03 \ source \ repos \ ClassLibrary4 \ ClassLibrary4 \ bin \ Debug \ ClassLibrary4.dll @@@ C: \ Users \ Design03 \ source \ repos \ ClassLibrary4 \ ClassLibrary4 \ bin \ Debug \ *. DLL @@@ 0! Jalankan Fungsi Pengguna 
Berhasil memuat modul dinamis C: \ Program Files \ Siemens \ NX 10.0 \ UGII \ nxclrldr.dll
Modul yang dimuat c: \ program files \ siemens \ nx 10.0 \ ugii \ nxclrldr.dll 7ffbaa110000 12000 a25063b2-49d18f64-c2f57fa2-f9e0e00b -1 = nxclrldr ___ 1416452452cyp version = 10.0.0.24
Loaded module c: \ program files \ common files \ microsoft shared \ ink \ tiptsf.dll 7ffb91150000 a3000 318f0f13-4fc9fc00-1b9e9aa1-f7226faf-1 versi = 10.0.10586.965
Modul yang dimuat c: \ windows \ system32 \ globinputhost.dll 7ffbaa180000 30000 c4cb6b06-47f0d926-af42dda2-35b6b77-1 version = 10.0.10586.0
Modul yang dimuat c: \ windows \ system32 \ bcp47langs.dll 7ffbbf800000 67000 de9634e4-4088a320-97c178a4-98a939e8-1 versi = 10.0.10586.589
Modul yang dimuat c: \ windows \ system32 \ windows.globalization.dll 7ffb73b90000 185000 b1a6f40-43e62e44-7e8cb8c- 29767373-1 versi = 10.0.10586.672
Modul yang dimuat c: \ file program \ autodesk \ autodesk sync \ realdwg \ acsigncore16.dll 7ffb82bd0000 9b000 8bdb170e-4fb06d2b-60738e8d-b7a8790a-1 versi = 19.1.14.0
Modul yang dimuat c: \ windows \ system32 \ cscui.dll 7ffbaae50000 c6000 f6c47065-4424c2e4-b6b6e92-5b3c1786-1 version = 10.0.10586.839
Modul yang dimuat c: \ windows \ system32 \ ehstorshell.dll 7ffb91110000 37000 7fb1b522-45d87b21-ab9a0aa6-128dd5ea-1 versi = 10.0.10586.0
Modul yang dimuat c: \ windows \ system32 \ acsignicon.dll 7ffbbd070000 f000 35070ca0-462a8b53-302a259c-a171256d-1 versi = 20.0.51.0
Modul yang dimuat c: \ program files \ microsoft office 15 \ root \ vfs \ programfilesx64 \ microsoft office \ office15 \ 1033 \ grooveintlresource.dll 18040000 87d000 b434eb9-48007c77-b1f56388-9fccc6fe-1 versi = 15.0.4907.1000
Modul yang dimuat c: \ windows \ system32 \ msi.dll 7ffbb7220000 33a000 1931d40a-43a0f64f-1bf12ba1-629a0e03-1 versi = 5.0.10586.713
Modul yang dimuat c: \ windows \ system32 \ mssprxy.dll 7ffba9d10000 23000 97b6bebd-49205287-c5bb5397-bb2f085c-1 versi = 7.0.10586.1176
Modul yang dimuat c: \ program files \ microsoft office 15 \ root \ vfs \ programfilesx64 \ microsoft office \ office15 \ atl100.dll 71e40000 2b000 73033918-47b6b8c8-803baf99-611556be-3 = atl100.amd64 versi = 10.0.40219.325
Modul yang dimuat c: \ program files \ microsoft office 15 \ root \ vfs \ programfilesx64 \ microsoft office \ office15 \ msvcp100.dll 6f1c0000 98000 32f89d1b-421b58a0-bca62394-974a3d4c-1 = msvcp100.amd64 versi = 10.0.40219.325
Modul yang dimuat c: \ program files \ microsoft office 15 \ root \ vfs \ programfilesx64 \ microsoft office \ office15 \ grooveex.dll 7ffb83eb0000 23e000 6eee171e-4c5daa38-84673384-5cc19c63-2 version = 15.0.5023.1000
Modul yang dimuat c: \ windows \ system32 \ photometadatahandler.dll 7ffbad580000 6d000 e6268b8e-4309635c-604d35bf-fa0a43b6-1 version = 10.0.10586.0
Modul yang dimuat c: \ program file (x86) \ dropbox \ client \ dropboxext64.22.0.dll 7ffbaa000000 5c000 d97a096a-42b9f0f6-4c923d86-8c32bfa-1 versi = 1.0 .22.0
Modul yang dimuat c: \ Program file (x86) \ Internet download manager \ idmshellext64.dll 7ffbaa060000 9000 c72201c7-49da676c-8be20e92-361b98d9-1 versi = 6.28.14.20
Modul yang dimuat c: \ windows \ system32 \ apphelp.dll 7ffbc2a40000 79000 698f059f- 42936789-d756e4bc-52779f13-1 version = 10.0.10586.589
Modul yang dimuat c: \ windows \ system32 \ windows.storage.search.dll 7ffb91000000 cc000 24f60b69-463e1a4f-e78a48a0-443bacfe-1 versi = 10.0.10586.839
Modul yang dimuat c: \ windows \ system32 \ thumbcache.dll 7ffbaa440000 4d000 c4d14af0-46089878-e5e47da2-597c3c86-1 version = 10.0.10586.839
Modul yang dimuat c: \ windows \ system32 \ structuredquery.dll 7ffb85c10000 ac000 7ef56d36-4e5708c0-4b703d85-8278b00d-1 versi = 7.0.10586.420
Modul yang dimuat c: \ windows \ system32 \ cscapi.dll 7ffbb5500000 12000 e89c26ff-4314eed6-322eb991-5ea327d0-1 versi = 10.0.10586.0
Modul yang dimuat c: \ windows \ system32 \ srvcli.dll 7ffbb7e20000 26000 1421db1c-4ad3c6d3-7c5aa6b5-b1712a9f- 1 versi = 10.0.10586.212
Modul yang dimuat c: \ windows \ system32 \ ntshrui.dll 7ffbaa5b0000 db000 4b5cbc5c-475f9680-c9e88092-465f9cd0-1 versi = 10.0.10586.839
Modul yang dimuat c: \ windows \ system32 \ msvcp110_win.dll 7ffbbc640000 92000 b31d46cd- 4487da9c-152a9cb5-b0d69fe8-1 versi = 10.0.10586.0
Modul yang dimuat c: \ windows \ system32 \ policymanager.dll 7ffbbc890000 55000 fa3a8f21-4fe961a1-b1479bb6-97a5c47f-1 versi = 10.0.10586.212
Modul yang dimuat c: \ windows \ system32 \ msftedit .dll 7ffb864a0000 339000 55cf22f0-458fff50-4bd147b1-60de47d7-1 versi = 10.0.10586.1106
Menggunakan C: \ Program Files \ Siemens \ NX 10.0 \ ugii \ managed \ ManagedLoader.dll untuk memuat dikelola DLL
Mencoba memuat C: \ Program Files \ Siemens \ NX 10.0 \ ugii \ managed \ ManagedLoader.dll
ManagedLoader.Load: C: \ Users \ Design03 \ source \ repos \ ClassLibrary4 \ ClassLibrary4 \ bin \ Debug \ ClassLibrary4.dll Nama: ClassLibrary4.dll
Tidak ada kebijakan konteks.

AppBase: C: \ Users \ Design03 \ source \ repos \ ClassLibrary4 \ ClassLibrary4 \ bin \ Debug \
Loaded assembly: ClassLibrary4, Versi = 1.0.0.0, Culture = neutral, PublicKeyToken = 00fd9a5486b96be8 dari C: \ Users \ Design03 \ source \ repos \ ClassLibrary4 \ ClassLibrary4 \ bin \ Debug \ ClassLibrary4.dll
Loaded assembly: Microsoft.VisualBasic, Version = 10.0.0.0, Culture = neutral, PublicKeyToken = b03f5f7f11d50a3a dari C: \ WINDOWS \ Microsoft.Net \ assembly \ GAC_MSIL \ Microsoft.VisualBasic \ v4.0_10.0.0.0__b03f5f7f11d50a3a \ Microsoft.VisualBasic. dll
Tertangkap kecuali saat menjalankan: Main
System.IO.FileLoadException: Tidak dapat memuat file atau perakitan 'NXOpen.Utilities, Versi = 4.0.0.0, Budaya = netral, PublicKeyToken = null' atau salah satu dependensinya. Diperlukan perakitan yang dinamai kuat. (Pengecualian dari HRESULT: 0x80131044)
Nama file: 'NXOpen.Utilities, Versi = 4.0.0.0, Budaya = netral, PublicKeyToken = null'
di ClassLibrary4.NXJournal.Main ()


& PERUBAHAN FOKUS MACRO DALAM 1
& MACRO MESSAGE_BOX -2 Kesalahan di pustaka eksternal . Lihat log sistem untuk detail
&
& MACRO MESSAGE_TEXT Nama file: C: \ Users \ Design03 \ source \ repos \ ClassLibrary4 \ ClassLibrary4 \ bin \ Debug \ ClassLibrary4.dll
& MACRO MESSAGE_TEXT
& MAKRO MESSAGE_TEXT Nama fungsi: Utama
& MACRO MESSAGE_TEXT

apakah ada orang yang dapat membantu saya untuk memecahkan masalah ini ....

Silakan lihat lampiran dari file '.dll

 

 

Terima kasih

5 REPLIES

Re: Error to execute ".dll file

Siemens Phenom Siemens Phenom
Siemens Phenom

I tried to run your .DLL, and the error I got was that it could not be loaded, because either the program or one of its dependencies could not be loaded.  Did you build the .DLL with the 2012 version of Visual Studio?  Did you create your project with the NX Open Wizard?  I did that, and used your code, and I was able to run the resulting program.

 

Re: Error to execute ".dll file

Creator
Creator

what dependencies can not be loaded? i made '.dll by using visual studio 2017 .... I do not use NXOPEN WIZARD, I do not know how to use NXOPEN WIZARD ... then what is the solution for my problem ..?

Highlighted

Re: Error to execute ".dll file

Siemens Phenom Siemens Phenom
Siemens Phenom

Here is a link to a helpful article that explains this:

 

https://solutions.industrysoftware.automation.siemens.com/view.php?sort=desc&p=1&q=nxopen+%22getting...

 

Note that the article linked above has a link to another article to show you what version of the Studio you need for each release of NX, and a link to another article about how to use the Wizards.

 

 

Re: Error to execute ".dll file

Creator
Creator
I'm not understand about it....

"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
Note: Steps 1 - 3 below are important to ensure that you are using the VS from
a shell environment which is properly initialized for NX. You should be able
to start NX from the NX Command Prompt window using the command "ugii".

If desired you can replace them with a .bat file that looks like this:
set MSVCDir=<as appropriate (see below)>
call "%UGII_BASE_DIR%\UGII\ugiicmd.bat" "%UGII_BASE_DIR%" AUTO
devenv

If you only have one NX version installed on your machine, you can use the environment
variable UGII_BASE_DIR as shown above. If you are working with multiple NX versions make
separate .bat files to start the VS for each one and include the correct full path to the
NX base folder. For example, for a typical NX8.5 install it would look like this:
set MSVCDir=C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC
call "C:\Program Files\Siemens\NX 8.5\UGII\ugiicmd.bat" "C:\Program Files\Siemens\NX 8.5" AUTO
devenv
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""

can you explain it., and on my computer there is no "NX Command promp"

Re: Error to execute ".dll file

Siemens Phenom Siemens Phenom
Siemens Phenom

Are you on Windows 10?

 

Beginning with Windows 8, Microsoft no longer recognizes the NX Command prompt
as a shortcut in the start menu.  

However, you can still use this item either by first opening a standard DOS window and executing %UGII_ROOT_DIR%\ugiicmd.bat, or you can right-click on the task bar and select
TOOLBARS > NEW TOOLBAR:
 
And set the "select folder" so that it reads:

<C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Siemens NX 10.0

You should end up with a toolbar on the Windows task bar that reads Siemens NX10.

From here you can select the standard NX Command Prompt from the NX Tools menu.