Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hey I got a comm object for a Valentina DB. I don't have the library header files and so I can't import the dll into ASP.Net. I got around that by calling server.createobject. Below is a snippet of code I am having trouble with.

 

For intCounter = 1 to vCursor.RecordCount

vField = vCursor.Field( intCounter )

strReturn = strReturn & vField.Value & "<br>"

vCursor.NextRecord()

 

Next

 

The big problem is I cannot assign a dynamic value to the Object vCursor.Field(). It keeps kicking out the error (System.Runtime.InteropServices.COMException: Field not found). Could this be an issue involving the order of processing? Its almost as if the object is being executed before a value is being assigned to intCounter, but I thought it executed line by line. I am totally stumped, I am hoping someone who has more experience using comm objects inside of asp.net will have a better idea. Also as a side note, this object was actually written for PHP.

  • Administrators
Posted (edited)
If the Dll is a COM dll then you shouldn't need the header files to use it with ASP.Net, simply add a reference, select the COM Tab and browse to the DLL. Visual Studio should take care of wrapping the DLL for you. Edited by PlausiblyDamp

Posting Guidelines FAQ Post Formatting

 

Intellectuals solve problems; geniuses prevent them.

-- Albert Einstein

Posted
I apologize for being such a newb, I am not very familiar with Visual Studio.Net yet. So if I did something wrong let me know. I went into VS and opened up the OLE/COM Object Viewer and tried to bind the dll file. I recieved the following error, Bad Extension for File MK_E_INVALIDEXTENSION($800401E6). What am I doing wrong? Am I even close to what you suggested?
Posted
I am having another problem. After referencing the .dll I just noticed that I lost a class. For some reason it sees all the classes except one. I am not sure if it renamed the class or what, but I can't register the new .dll and I haven't been able to figure out how I can view it in order to find out what happened to this class, any ideas?
Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...