Exception:解析表达式出错。 内部错误:正在分析“)”- ) 过多。 原始表达式:string[] lines = Regex.Split({input},"\r\n?|\n"); var headers=Regex.Split(lines.First().TrimStart('#'),{sep}); int ncol = lines.Select(x=>Regex.Split(x,{sep})).Max(x=>x.Count()); Enumerable.Range(1,ncol).Select((x,i)=>({useheader}?headers.ElementAtOrDefault(i)??"(列"+x+")":"列"+x)+"|"+(i+1));

报错信息

Exception: 解析表达式出错。
内部错误:正在分析“)”- ) 过多。
原始表达式:string[] lines = Regex.Split({input},"\r\n?|\n");
var headers=Regex.Split(lines.First().TrimStart('#'),{sep});
int ncol = lines.Select(x=>Regex.Split(x,{sep})).Max(x=>x.Count());
Enumerable.Range(1,ncol).Select((x,i)=>({useheader}?headers.ElementAtOrDefault(i)??"(列"+x+")":"列"+x)+"|"+(i+1));
StackTrace:
   在 Quicker.Domain.Actions.X.XActionHelper.GetValueFromExpression2(String expression, ActionExecuteContext context)
   在 Quicker.Domain.Actions.X.XActionHelper.InterpolateOrEvalToString(ActionExecuteContext context, String data)
   在 Quicker.View.Forms.Controls.FormDropdownControl.Update(IVariableContext context)
   在 Quicker.View.Forms.Controls.FormFieldWrapper.Update(IVariableContext context)
   在 Quicker.View.Forms.FormWindow.etCVkW9yPMU(String  )
   在 Quicker.View.Forms.FormWindow.AJwVki1NV8g(Object  , FormField  )
   在 Quicker.View.Forms.Controls.BaseFormFieldControl.TriggerValueChange(FormField field)
   在 Quicker.View.Forms.Controls.FormFieldWrapper.HxWVnljGj83(Object  , FormField  )
   在 Quicker.View.Forms.Controls.BaseFormFieldControl.TriggerValueChange(FormField field)
   在 Quicker.View.Forms.Controls.FormTextBoxControl.GIvVnFQaG3y(Object  , TextChangedEventArgs  )
   在 System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   在 System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   在 System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   在 System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   在 System.Windows.Controls.Primitives.TextBoxBase.OnTextContainerChanged(Object sender, TextContainerChangedEventArgs e)
   在 System.Windows.Controls.TextBox.OnTextContainerChanged(Object sender, TextContainerChangedEventArgs e)
   在 System.Windows.Documents.TextContainerChangedEventHandler.Invoke(Object sender, TextContainerChangedEventArgs e)
   在 System.Windows.Documents.TextContainer.EndChange(Boolean skipEvents)
   在 System.Windows.Documents.TextRangeBase.EndChange(ITextRange thisRange, Boolean disableScroll, Boolean skipEvents)
   在 System.Windows.Documents.TextRange.ChangeBlock.System.IDisposable.Dispose()
   在 System.Windows.Documents.TextEditorTyping.DoTextInput(TextEditor This, String textData, Boolean isInsertKeyToggled, Boolean acceptControlCharacters)
   在 System.Windows.Documents.TextEditorTyping.OnTextInput(Object sender, TextCompositionEventArgs e)
   在 System.Windows.Controls.Primitives.TextBoxBase.OnTextInput(TextCompositionEventArgs e)
   在 System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   在 System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   在 System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   在 System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   在 System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   在 System.Windows.Input.InputManager.ProcessStagingArea()
   在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   在 System.Windows.Input.TextCompositionManager.PostProcessInput(Object sender, ProcessInputEventArgs e)
   在 System.Windows.Input.InputManager.RaiseProcessInputEventHandlers(ProcessInputEventHandler postProcessInput, ProcessInputEventArgs processInputEventArgs)
   在 System.Windows.Input.InputManager.ProcessStagingArea()
   在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   在 System.Windows.Input.TextCompositionManager.PostProcessInput(Object sender, ProcessInputEventArgs e)
   在 System.Windows.Input.InputManager.RaiseProcessInputEventHandlers(ProcessInputEventHandler postProcessInput, ProcessInputEventArgs processInputEventArgs)
   在 System.Windows.Input.InputManager.ProcessStagingArea()
   在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   在 System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
   在 System.Windows.Interop.HwndKeyboardInputProvider.ProcessTextInputAction(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 System.Windows.Interop.HwndSource.OnPreprocessMessage(Object param)
   在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

 

解决方法

暂无解决方案。

相关信息
1 查看
4天18小时前
Quicker版本
版本 反馈次数
1.45.5 1