immediate-window

Why: A first chance exception of type 'System.ArgumentException' occurred in System.Windows.Forms.dll?

半世苍凉 提交于 2019-12-11 15:34:36
问题 I get this in the immediate window while debuging: A first chance exception of type 'System.ArgumentException' occurred in System.Windows.Forms.dll Okay So I created a version checker to check if the version is correct else update. It is not working. It thinks the version is the same and doesn't update. It was working early and now it's randomly broken.. Private Sub Form1_Shown(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Shown '*update process Dim request As System.Net

Visual Studio 2010: suddently Locals, Immediate Window and Watches don't work

只愿长相守 提交于 2019-12-07 04:20:45
问题 I have this problem that a week ago, when debugging, suddently the "Locals" window is blank, the "Immediate Window" and Watches don't work and all return "Unable to evaluate the expression." Also the standard debugger display stopped giving me any info when I break the execution to check out stuff :-( I have played around with all the debugger settings, but none of them seems to have any effect what so ever on my problem. I did install the MVC3 RC1 and the Nupack just before my problem

How to execute LINQ and/or foreach in Immediate Window in VS 2013?

无人久伴 提交于 2019-12-03 22:35:27
Immediate Window is fantastically useful tools when probing the current state during debugging process. I learned that by using the question mark, one can do a bit more in there as shown in this post . However, I still don't know how to execute LINQ queries there ( including lambda expressions). I've also failed to execute a foreach statement. When executing the following statements: ?(things.Select(thing=>thing.Id);) ?(foreach(var thing in things);) I'm getting these errors: Expression cannot contain lambda expressions Invalid expression term 'foreach' (How) can I execute these in the

Visual Studio Immediate Window - Lambda Expressions Aren't Allowed - Is there a Work-around or Alternative? [closed]

耗尽温柔 提交于 2019-12-03 04:42:42
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 5 years ago . I'm debugging some tricky generic List-based code in VS 2010 - lots of hierarchy-processing etc.. Of course lambda expressions and anonymous methods aren't permitted within the immediates window and I can't be doing with stepping thru the code in the usual way as I'm still trying to get my head around the

Use VBA to Clear Immediate Window?

巧了我就是萌 提交于 2019-12-03 02:27:16
问题 Does anyone know how to clear the immediate window using VBA? While I can always clear it myself manually, I am curious if there is a way to do this programmatically. 回答1: Below is a solution from here Sub stance() Dim x As Long For x = 1 To 10 Debug.Print x Next Debug.Print Now Application.SendKeys "^g ^a {DEL}" End Sub 回答2: Much harder to do that I'd envisaged. I found an version here by keepitcool that avoids the dreaded Sendkeys Run this from a regular module. Updated as initial post

Immediate Window for Eclipse

拈花ヽ惹草 提交于 2019-12-02 16:02:39
Does Eclipse have an analog to Visual Studio's "Immediate Window", a window where I can evaluate statements while in the debugger? Eclipse has a really cool concept call Scrapbook Pages where you can evaluate statements even when you're not debugging. However, if you want to eval code using values from the current program, go to Window->Show View->Expressions. There you can put in any expression you want and track it as your program executes. Yes. The view name is "Display". Window->Show View->Other It is under the Debug folder. Once in there you evaluate statements while in the debugger.

Newlines in the Immediate Window

◇◆丶佛笑我妖孽 提交于 2019-12-02 15:46:18
Using Visual Studio 2010 Professional, I have a ToString() method that looks like this: public override string ToString() { return "something" + "\n" + "something"; } Because there are several " something "'s and each is long, I'd like to see something something Sadly, I'm seeing "something\nsomething" Is there a way to get what I want? davesem Actually there is a way. You can use format specifiers in the immediate window to change the format of the display. If you have a string with carriage returns and linefeeds in it ("\r\n") you can follow the print request with the 'no quotes' format

Use VBA to Clear Immediate Window?

牧云@^-^@ 提交于 2019-12-02 14:22:00
Does anyone know how to clear the immediate window using VBA? While I can always clear it myself manually, I am curious if there is a way to do this programmatically. Blaz Brencic Below is a solution from here Sub stance() Dim x As Long For x = 1 To 10 Debug.Print x Next Debug.Print Now Application.SendKeys "^g ^a {DEL}" End Sub Much harder to do that I'd envisaged. I found an version here by keepitcool that avoids the dreaded Sendkeys Run this from a regular module. Updated as initial post missed the Private Function Declarations - poor copy and paste job by yours truly Private Declare

Write SqlDataReader to immediate window c#

旧时模样 提交于 2019-12-01 21:05:42
I am trying to debug a SQL response which is throwing an error: Conversion failed when converting the varchar value '0.01' to data type bit. That does not make a lot of sense as object does not have any bools. Code: using (var connection = _connectionProvider.GetDbConnection()) { connection.Open(); return connection.Query<Rate>(query, parameters); } SQL that gets executed (I manually added parameters): select * from (select top 1 BuildNumber, RateVersion, SampleId, Tariff, TariffStepName, Factor1, Result1 from dbo.Rates where Tariff = 'Default' and TariffStepName = 'I_P' and (RateVersion <= 1)

How to print two dimensional array in Immediate window in VBA?

不想你离开。 提交于 2019-11-30 12:20:30
How to print two dimensional array in Immediate window in VBA ? Does it exist any generic method for doing this ? Some method for ploting one row of array per line in Immediate window could solve this problem, because then only thing to do is to loop this code for each line of array. I made a simple loop to do this for anybody's reference: Sub WriteArrayToImmediateWindow(arrSubA As Variant) Dim rowString As String Dim iSubA As Long Dim jSubA As Long rowString = "" Debug.Print Debug.Print Debug.Print "The array is: " For iSubA = 1 To UBound(arrSubA, 1) rowString = arrSubA(iSubA, 1) For jSubA =