|
|
|
![]() |
|
Strumenti |
![]() |
#1 |
Senior Member
Iscritto dal: Mar 2003
Città: Salerno
Messaggi: 2006
|
[activeX] Importare una dll e lib
Salve, premetto che questa è stata la prima volta che ho usato visual studio.
Ho i sorgenti di un activex e dovrei includere una file xxx.h xxx.lib e xxx.dll? Come devo fare? Ho provato in vari modi per quel poco che ne so, ma nella compilazione mi da errore sull'uso del metodo scritto nel file .h. L'errore è Error error LNK2019: unresolved external symbol
__________________
MSI B550 Mortar Wi-fi, Ryzen 7 5900x, Scythe Fuma 2 + Arctic MX-5, 2x16GB Corsair 3600Mhz, MSI GTX 1050Ti 4GB, Seasonic S12 600W, WD SN850 Black 1TB, Kingston KC2500 1TB, Samsung 850 EVO 500GB, 2TB WD Green, 2 Thermalright TY-140, Benq 24" G2420HD, Edifier HCS2330 |
![]() |
![]() |
![]() |
#2 |
Senior Member
Iscritto dal: Oct 2007
Città: Padova
Messaggi: 4131
|
MSDN|VisualC++|Errore degli strumenti del Linker
Probabilmente hai incluso l'header file nei tuoi sorgenti e non hai specificato per niente (o non hai specificato correttamente) la libreria da linkare contenente la definizione della funzione. Nota che nel caso del file .lib devi passare questo file come argomento al compilatore; invece per il file .dll non serve linkare tramite compilatore: è una libreria dinamica che deve venire caricata a runtime, quindi direttamente da codice tramite apposita chiamata di sistema: ti consiglio di leggerti qualche guida in proposito.
__________________
As long as you are basically literate in programming, you should be able to express any logical relationship you understand. If you don’t understand a logical relationship, you can use the attempt to program it as a means to learn about it. (Chris Crawford) |
![]() |
![]() |
![]() |
#3 |
Senior Member
Iscritto dal: Mar 2003
Città: Salerno
Messaggi: 2006
|
Grazie x la veloce risposta.
Ho seguito questa guida: http://www.flipcode.com/archives/Cre...ing_DLLs.shtml Il file lib l'ho cercato di includere con project property->Linker->General->Additional Library Directories = C:\XXX\xxx.lib
__________________
MSI B550 Mortar Wi-fi, Ryzen 7 5900x, Scythe Fuma 2 + Arctic MX-5, 2x16GB Corsair 3600Mhz, MSI GTX 1050Ti 4GB, Seasonic S12 600W, WD SN850 Black 1TB, Kingston KC2500 1TB, Samsung 850 EVO 500GB, 2TB WD Green, 2 Thermalright TY-140, Benq 24" G2420HD, Edifier HCS2330 |
![]() |
![]() |
![]() |
#4 |
Senior Member
Iscritto dal: Oct 2007
Città: Padova
Messaggi: 4131
|
Ed è andato tutto bene?
__________________
As long as you are basically literate in programming, you should be able to express any logical relationship you understand. If you don’t understand a logical relationship, you can use the attempt to program it as a means to learn about it. (Chris Crawford) |
![]() |
![]() |
![]() |
#5 |
Senior Member
Iscritto dal: Mar 2003
Città: Salerno
Messaggi: 2006
|
no, questo l'ho provato ieri
__________________
MSI B550 Mortar Wi-fi, Ryzen 7 5900x, Scythe Fuma 2 + Arctic MX-5, 2x16GB Corsair 3600Mhz, MSI GTX 1050Ti 4GB, Seasonic S12 600W, WD SN850 Black 1TB, Kingston KC2500 1TB, Samsung 850 EVO 500GB, 2TB WD Green, 2 Thermalright TY-140, Benq 24" G2420HD, Edifier HCS2330 |
![]() |
![]() |
![]() |
#6 |
Senior Member
Iscritto dal: Oct 2007
Città: Padova
Messaggi: 4131
|
Scusa?
Volevo sapere se alla fine eri riuscito a compilare... forse non ho capito la risposta ![]()
__________________
As long as you are basically literate in programming, you should be able to express any logical relationship you understand. If you don’t understand a logical relationship, you can use the attempt to program it as a means to learn about it. (Chris Crawford) |
![]() |
![]() |
![]() |
Strumenti | |
|
|
Tutti gli orari sono GMT +1. Ora sono le: 01:48.