Message 1 of 6
ilogic Functions &/Or Sub Routines Passing Arguments Back To Main Code
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello All,
I'm struggling to understand Functions &/Or Sub Routines in ilogic.
In effect I am trying to have a function/sub routine within my code that stores a list of integers.
Then I want return some of those integers (with some if else statements) to my called function/sub routine so Ican use these values elsewhere. I have a rough idea of how functions work in VBA but that doesn't seem to translate to ilogic, unless I am missing something. Here is what I have so far
Sub Main Call SplitPinCalc((BoltSize), Split_Pin, Split_Pin_Hole, Split_Pin_Dist) 'These values above don't update with function values below End Sub Function SplitPinCalc(BoltSize As Integer, Split_Pin As Integer, Split_Pin_Hole As Integer, Split_Pin_Dist As Integer) If BoltSize = "12" Then Split_Pin = 3 Split_Pin_Hole = 4 Split_Pin_Dist = BoltSize*2 Else If 'Blah Blah Blah End If Return SplitPinCalc End Function
My code so far enters into the function and works as intended, but those values are not passed back up to the called function arguments.
Any help & instruction would be much appreciated.
Kind Regards
Tim