Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I pass a group when starting a new thread

Status
Not open for further replies.

ChrisH2

Programmer
Apr 18, 2002
44
GB
I am trying to pass a group of parameters when starting a new thread. eg: -

Calling Procedure: -

!Start thread, passing 1 parm
SaveThread2 = START(NewProc2,35000,Loc:GroupName)

Procedure Being Called: (NewProc2) -

Prototype: (Group)
Parameter: (MyGroup)


How do I specify the group in NewProc2?

It does not seem to like a Prototype of (Group)

I get the compile error "invalid data type for value parameter"

(*Group) doesnt seem to work either. I get the compile error "No matching prototype available" for the START command.

Has anyone managed to do this?

 
Hi,

START() can handle only string parameters. Look in the help on the TYPE attribute of groups.

In Global Data :

MyGroupType GROUP,TYPE
B1 byte
S2 string(20)
D3 decimal(10,2)
END

In calling procedure or frame :

PassedGroup GROUP(MyGroupType)
END

Called procedure :

START(MyProcedure, 25000, PassedGroup)

MyProcedure PROCEDURE(STRING PassedGroup)

MyGroup GROUP(MyGroupType)
END

CODE

MyGroup = PassedGroup

...

Regards

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top