- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
This is probably a stupid question, but I just can't get it working.
I'm trying to place a view label and fill out 4 Prompted Entries with information gathered from various sources.
Dim vNum As Integer Dim sdNum As String Dim fName As String Dim oMaterial As String 'Dim sPromptString(3) As String Dim sPromptString(0) As String 'Dim sPromptString As String()
'oSketchedSymbolDef = oDrawDoc.SketchedSymbolDefinitions.Item("Label - View - v2") oSketchedSymbolDef = oDrawDoc.SketchedSymbolDefinitions.Item("Label - Door/Window") 'sPromptString = {vNum, sdNum, fName, oMaterial} sPromptString = {"A"} 'MsgBox(sPromptString(0) & " - " & sPromptString(1) & " - " & sPromptString(2) & " - " & sPromptString(3), okay, "Debug") MsgBox(sPromptString(0), okay, "Debug") oSketchedSymbol = oSheet.SketchedSymbols.Add(oSketchedSymbolDef, oPoint2, 0, 1, sPromptString)
I dropped it back to another label that has only one Prompted Entry to test, and it still won't fill it out. If I pick a symbol with no Prompted Entries, and change it to Nothing, it works fine, but no matter what I try I keep getting an error:
System.ArgumentException: The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
at Microsoft.VisualBasic.CompilerServices.LateBinding.LateGet(Object o, Type objType, String name, Object[] args, String[] paramnames, Boolean[] CopyBack)
at Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateGet(Object Instance, Type Type, String MemberName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack)
at LmiRuleScript.Main()
at Autodesk.iLogic.Exec.AppDomExec.ExecRuleInAssembly(Assembly assem)
at iLogic.RuleEvalContainer.ExecRuleEval(String execRule)
In both cases the Message Box shows all the information I want as expected, the first symbol "Label - View - v2" has 4 entries and the second "Label - Door/Window" has 1.
Solved! Go to Solution.