![]() |
VBE question
I know you can do:
strProcName = .ProcOfLine(lCodeLine, lProcType) and the variable lProcType will tell you then if the procedure is a Sub/Function or a Property Get or Property Let or Property Set, with the values 0 to 3. It won't differentiate though between a Sub or a Function. I can do this, but it gets a bit messy. What is the simplest way to do this? RBS |
VBE question
Bart,
The only way I have found to do it is to parse the procedure declaration looking for Sub/Function, which is probably what you are doing. -- HTH Bob Phillips (remove nothere from email address if mailing direct) "RB Smissaert" wrote in message ... I know you can do: strProcName = .ProcOfLine(lCodeLine, lProcType) and the variable lProcType will tell you then if the procedure is a Sub/Function or a Property Get or Property Let or Property Set, with the values 0 to 3. It won't differentiate though between a Sub or a Function. I can do this, but it gets a bit messy. What is the simplest way to do this? RBS |
VBE question
Hi Bob,
Yes, that is what I do, although I thought it was a bit simpler to look at End Sub etc. Shame they didn't differentiate this in ProcType. RBS "Bob Phillips" wrote in message ... Bart, The only way I have found to do it is to parse the procedure declaration looking for Sub/Function, which is probably what you are doing. -- HTH Bob Phillips (remove nothere from email address if mailing direct) "RB Smissaert" wrote in message ... I know you can do: strProcName = .ProcOfLine(lCodeLine, lProcType) and the variable lProcType will tell you then if the procedure is a Sub/Function or a Property Get or Property Let or Property Set, with the values 0 to 3. It won't differentiate though between a Sub or a Function. I can do this, but it gets a bit messy. What is the simplest way to do this? RBS |
All times are GMT +1. The time now is 03:37 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com