forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Passing Strings From Visual Basic to Fortran

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> KBase
View previous topic :: View next topic  
Author Message
silverfrost
Site Admin


Joined: 29 Nov 2006
Posts: 191
Location: Manchester

PostPosted: Tue Sep 07, 2004 9:48 pm    Post subject: Passing Strings From Visual Basic to Fortran Reply with quote

When passing strings from VB into Fortran the following should be done:

* The string should be passed ByVal from Visual Basic, the callee can still alter this string.
* If the string length is known then it should be declared as such in the Fortran and this length string should be passed from the VB.
* If the string length is unknown then it should be declared as character (*) in the Fortran and some extra arguments need to be passed from the VB. These arguments are the string lengths. The string lengths should be passed on the end of the argument list, in the order in which any strings in the list appear. They should be passed by value as 4 byte integers.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> KBase All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group