- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am having a problem when defining a string "put" property in a COM Server created with Compaq FORTRAN. The corresponding "get" works correctly when I call it from VB; when I attempt to "put" a value by assigning a VB string to it, I get an Access Violation (address = 0xC000005).
Any help would be greatly appreciated
Any help would be greatly appreciated
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It should work (it worked for me).
Post some code, and someone can take a look.
hth,
John
Post some code, and someone can take a look.
hth,
John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I did some further checking on the problem. I find that I can assign a string VARIABLE to the property in VB like this:
dim s as string, obj as Fortran.COMObject
set obj = new COMObject
s = "Some String Data"
obj.stringproperty = s
If I try this, it generates the error:
obj.stringproperty = "Some String Data"
Also, If i declare s as a string constant, it blows up.
dim s as string, obj as Fortran.COMObject
set obj = new COMObject
s = "Some String Data"
obj.stringproperty = s
If I try this, it generates the error:
obj.stringproperty = "Some String Data"
Also, If i declare s as a string constant, it blows up.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Again, both string literals and string constants work for me.
-John
-John
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page