« first day (1861 days earlier)      last day (1319 days later) » 
00:00 - 23:0023:00 - 00:00

12:01 AM
RELOAD!
[rubberduck-vba/Rubberduck] 5 issue comments.
[Minesweeper] Games Played: 88, Bombs Used: 64, Moves Performed: 13150, New Users: 13
 
 
1 hour later…
1:25 AM
@KySoto Attaboy. Defend ducky!
 
2:11 AM
> you are doing that too much. try again in 7 minutes.
wow reddit
 
2:33 AM
You can only correct so many people in a given time Mug.
 
3:10 AM
ooh, a reply!
yay, a reddit fight over line numbers!
 
where's the reply, did I miss it?
 
gloves off :)
 
I have to admit "Java and C# have line numbers" was a nice try
 
3:25 AM
ah gee I love reddit, I should be on more often. Thanks to @KySoto for pointing the thread out.
 
/*making* the thread
 
oh yeah good point
lol it's late
#BrainDead
 
aye, heading to bed soon here as well :)
 
0
Q: Optimization Of Code To Auto-Email Past Due Accounts

user2676140I am using this syntax to query a table and return a record set and if the number of times total the customer has been emailed is less than 5, send an email with a canned response. If the number of times emailed is >= 6 then the draft is saved with bold text so the user knows to review this (cas...

 
4:21 AM
> How about working hard to continually improve over 24 months? Well, now you're starting to get somewhere...
Be the worst? Did that. Still doing it.
Learn from those better than you? Since day 1!
7-1/2 more years to go. Ouch.
 
posted on July 11, 2019 by Rubberduck VBA

If you’re an accountant, a sales analyst, or in any other office position where writing VBA code helps you do your job faster, you may have uttered the words “I’m not a programmer” before, and that wouldn’t have been wrong: once the code is written, you’d tweak it every once in a while to fix… Continue reading “I’m not a programmer” &#

 
6:16 AM
Good morning
 
6:34 AM
discussion on reddit is so simmilar as in my office..."what? why you need all of it, you can't debug you code"
I like rows numbers as a powerful debugging tool ;)
 
 
2 hours later…
8:21 AM
Good morning to you too :)
Anyway, Hi folks.

Just wanted to hear your opinion of this autofix that RD Inspections do, is a good one.
I found a code on the internet (not mine) and applied RD autofix of Inspections.
This was the original
...
        Next j
    End If
    ' if nothing selected but unload pressed then beep
    On Error Resume Next        ''' switch error handling
    If jUnloadct = 0 Then
        Beep
    Else
        ' remove successfully unloaded addins from the listbox
        For j = boxAddins.ListCount - 1 To 0 Step -1    ''' zero-based array
            If jUnloaded(j) > 0 Then
                boxAddins.RemoveItem (j)                ''' remove from list box
            End If
        Next j
    End If
End Sub
And shit was the fixed version:
-----------------------------------
        Next j
    End If
    ' if nothing selected but unload pressed then beep
    On Error GoTo ErrorHandler        ''' switch error handling
    If jUnloadct = 0 Then
        Beep
    Else
        ' remove successfully unloaded addins from the listbox
        For j = boxAddins.ListCount - 1 To 0 Step -1    ''' zero-based array
            If jUnloaded(j) > 0 Then
                boxAddins.RemoveItem (j)                ''' remove from list box
            End If
        Next j
    End If

    Exit Sub
Do I understand this correctly that in the first case, it will just "ignore errors" but in the fixed versions, it will "jump" at the end of the SUB?

So the conditional after 'TODO: handle specific error
should be edited and modified?

My point... Did the auto-fix fixed the code so that I don't have to modify anything?
From times to times, in my code, I have the On Error Resume Next for example when I'm searching and initializing ListObjectTable that don't have to be on the worksheet. Or Column/Row name of Table. But that's okay, because on the next line i check, if the "range" was set, if not, then "do stuff".
If I understood the auto-fix poorly, sorry. I do have to learn a lot on VBA still.
 
nop, you still need to handle error in thoughtful way
autofix just refactored code but without acctual handling an error it will
reset error nuber to 0 and resume next line that rasied error
Err.Clear
Resume Next
at minimum add
debug.print Err.Number &" "& Err.Description
to see what error is raised
or Err.Raise Err.Number, Err.Description
to stop on error and fix
 
 
1 hour later…
9:57 AM
@IvenBach template is very cool. So much so that I try to reserve Do for the start of template methods alone.
e.g. protected virtual void DoCalculate() {};
 
10:28 AM
Working on #5041: VB6 Code Explorer context menu should have 'Exclude from project' and 'Delete' options
Getting an AV :-(
Specifically, related to the Exclude command (new). This is basically the same as RemoveCommand, just minus the export prompt.
It calls IVBComponents.Remove, whose implementation is (almost) identical between VBA and VB6
And it seems to work fine. The problem is that after the component is removed, other commands go to re-evaluate their CanExecute, and the node is still in the CE. At the first attempt to access the now-removed COM component, AV occurs.
And I'm kinda stuck... any ideas?
Not sure why this isn't a problem with the VBA RemoveCommand
 
10:45 AM
Oh, hell... looks like a timing issue. With a breakpoint on `RubberduckParserState.Sinks_ComponentRemoved', it doesn't happen...
 
 
1 hour later…
11:52 AM
> Erl will display the code line number that the error happened.
No.
@mansellan are you suspending the parser?
 
12:14 PM
> @Vogel612 I may have mistyped somewhat - the error is referencing `AddRemoveReferencesPresenterFactory` and it's mentioned on line 3508 of the log attached to the original bug report. This is part of the multi-line error report I quoted (starting on line 3505 of said log file) in the OP.

However, this morning, after a fresh restart of Excel with RD .4782, the Add/Remove References dialogue does indeed pop-up when requested. I will note that I installed .4782 earlier this week and I was runn
 
@this uh, not that I know of!
 
I think that's the problem.
 
I just copypasta'd the VBA equivalent (RemoveCommand)
 
YOu need to wrap the removal action in an suspension action.
yeah those didn't have suspension originally - there are few commands that really need to have parser suspended.
 
hmm ok, howcome the VBA ones gets away without?
 
12:23 PM
not sure exactly.
 
could just be subtle timing differences + luck
 
Yes - the thing is that this is contigent on whether there's a parser request queued
so if you're removing components while parser is running, that's going to be a load of sads.
 
lol
iiuc though, this isn't during a parser run
rather, the component removal queues a fresh run
based on the VBE componentremoved event
 
which may be too premature
 
12:42 PM
> The changed hash codes are to be expected, since the menu items are recreated on every startup (because the VBE doesn't like us putting menus in places).
 
I'm not totally missing it here, am I?
You cannot pass a function as a parameter to another function in VBA. — FreeMan 19 secs ago
 
Well...
I expect you really can if you try hard enough to break things.
 
@FreeMan there is some hacks around it, actually
 
Like, maybe if you slipped some assembler or whatever in there :)
 
We invoke functions by their names, so if you pass around a function name, you can do what RD does to invoke the function in VBA
 
12:44 PM
@Vogel612 I'm gonna go out on a limb and say there's no way the OP on that issue is gonna be doing that!
 
however that's a poor substitute to passing around function pointers
but you might be able to write some COM-calling code that correctly deals with that
but it's most likely going to be extremely ugly
 
@Duga @Vogel612 you thumbsupped my latest comment there, so I presume you found something useful in that long ramble. ;) It was the first thing I typed this morning and I had to edit several times because I was even confusing myself.
Glad it made sense to you!
though if you made sense of my caffeine deprived ramblings, I'm a bit concerned for your sanity, too...
 
~shuffles off to the dentist
 
Have fun gettin' your head examined!
 
no worries, I'm somewhat sanity-deprived currently, because I've been sleeping somewhat badly the last few days...
 
12:46 PM
last time I checked dentists weren't in business of examining heads....
O_O
 
T.T
 
X.X
 
@this where the heck do you keep your teeth??
 
If a dentist examined your head, they'd think the eye sockets were cavities.
@FreeMan In the glass tumbler next to his bed.
 
@FreeMan in my mouth, thankyouverymuch
 
12:49 PM
(Sorry, @this.)
 
lol
 
@Duga ideally the menus would be permanent, so they could be user-customised
 
@Hosch250 That's a distinct possibility!
@this is that not part of your head?
ergo, get yer head examined!
 
@FreeMan nope. it's a part of my face.
 
<meeting> err... <TownHall> (much more importanter)
@this and you keep your face in a jar by the door?
 
12:56 PM
@FreeMan last time I checked, it's firmly attached to my body.
not being evasive at all
 
@this What Louis XVI said before they guillotined him.
(If that's the right guy...)
Don't mind me, my sense of humor got out of the wrong side of bed this morning.
 
Louis got a lousy deal, for sure.
 
1:17 PM
if rubberduck test (vba xls)
Assert.AreEqual 0, recordSet.AffectedRows
where affectedRows are long returns error thet values are not the same type
is this issue?
or "this is obvious!"
e.g this is green: Assert.AreEqual 0, CInt(recordSet.AffectedRows)
 
Assert are strict in type
VBA lets you compare CInt(1) = CLng(1) which will be true
but with Assert, it will be false because the types are not the same.
 
1:34 PM
@this Ok clear! thx. This is in wiki I should read with more focus.
hmm Ducky is very clever
Assert.AreEqual Null, TypeName(Null)
Inconclusive! Nice
 
2:20 PM
i see that you guys have visited my RD thread XD
that thread freakin exploded for a second thread post ever on reddit
 
@this #BeatlesReferenceFail
 
@MathieuGuindon Suppose we do a screenshare system like VS's new liveshare one, or whatever they call it.
Where you can work on two synced systems at once?
 
2:40 PM
0
Q: VBA root finder algor

NewbieI did two simple functions in VBA (see below). When a user calls TirNoPer360 in Excel he must select cashflows and dates (as range), then he will get a rate (through iterations according to the second function TirNoPer360). Function Opt(Caja, Fecha As Range, tasa As Double) Dim i As Integer ...

 
3:04 PM
yeesh. Don't tell anyone here, but I just installed all the corporate security crap on my (byod) phone so I can access work email/calendar. That's really a lot of apps that get installed!
 
wow, SQL Server indexed views is extremely restrictive.
 
The one thing it definitely does is makes me want to have a shorter, easier pwd for my work account because it's more difficult to type a good pwd into my phone's keyboard than my desktop's keyboard.
of course, I'm not answering email outside work hours, but at least I can check my work calendar for planning days off.
 
they should do a facial recognition or thumbprint. I hear it's really, really secure!
 
sarcasmeter pegs
 
ooo, ooo, use MFA!
everyone has a 2nd cell, right?
 
3:25 PM
round here, most seem to. I'm not worthy of a company issued phone, and I'm quite happy about it. If I've got the phone, they'll expect me to be available 24/7 and I don't wanna do that
 
3:46 PM
@FreeMan you could always use a password manager....
 
that implies it'd have to be in cloud
which is very very problematic
It's one thing to have a password manager with a local storage. Entirely another when it's up there in cloud.
 
@KySoto I've used KeyPass for years. My pwd for that is very long. But, I don't have it on my work machine, so I can't have a nice random 35 character pwd for work.
 
4:15 PM
i guess it depends on the level of risk you are ok with.
I know its difficult to break into lastpass, and that they dont actually keep your password
my wife quit using it because she forgot her password -_-
we pretty much had to remake her account
the good/bad part was she only had like 5 passwords in it
so good she didnt lose much
but bad because she didnt really use it
 
@mansellan I just need more exposure to these patterns and the opportunity to work with them. I will need a few more readings of it and stumbling till it really sinks in. Glad you brought this to my attention.
 
@FreeMan well to be fair, even if you did have it on your work comp... it would be pointless since you wouldnt be able to access keypass till AFTER you entered your login password.
 
@BloggingDuck You may not have started out as one. Newsflash though you become one as your skills grew.
 
i just meant storing whatever long password you use for work that is easy to type on a regular keyboard
then using the password manager to paste it into your remote stuff
 
@IvenBach in a nutshell, if you want to let subclasses introduce their own behaviour, but in a "safe" way, you can have a sealed method that does things before and/or after a virtual method (usually an empty stub) that the subclass can override.
for example, "yes, you can do your thing. but you will be authenticated before, and logged after. you ain't overriding those bits."
 
4:25 PM
@FreeMan I hear a repeated 35 times makes for a nice password. Long enough to stop brute force attackers. :wink:
 
I actually try to avoid template method and very much prefer strategy.
 
just to check - would template be equivalent to abstract class?
My understanding is that template is really more of a C++ thing
 
@M.Doerner yeah, composition is usually more appropriate. but as inheritance patterns go, template is one of the best
@this it's more like a semi-sealed method
sealed-but-with-overridable-bits
 
hmm, in C#, you could define a non-sealed class with sealed methods.
 
@this exactly. to add a template to one, just have it call a virtual method.
(usually empty)
 
4:31 PM
come to think of it, that's pretty much what an abstract class is.
 
btw i'm misusing sealed really - I just mean non-virtual.
 
I guess one main difference, however, is that the compiler won't let you instantiate an abstract class. IDK what C++ compiler will do if you do the same thing for a template class.
 
I think template (maybe) means something different in C++. this is the template pattern
 
Hmm. Didn't realize there was a pattern named that.
 
In object-oriented programming, the template method is one of the behavioral design patterns identified by Gamma et al. in the book Design Patterns. The template method is a method in a superclass, usually an abstract superclass, and defines the skeleton of an operation in terms of a number of high-level steps. These steps are themselves implemented by additional helper methods in the same class as the template method. The helper methods may be either abstract methods, for which case subclasses are required to provide concrete implementations, or hook methods, which have empty bodies in the...
 
4:35 PM
so yeah, abstract classes would be one way to implement the template pattern, I guess.
 
sure... templated methods are sort-of the method equivalent of abstract classes
I never saw the connection till now
but both have bits you can override, and bits you can't
 
5:24 PM
Duck check: Does VS have the same capability as the VBE to highlight a statement and see its evaluation in a tooltip?
isFoo && isBar && isDuk is the statement you are wanting to evaluate and selecting it would display true or false depending on the argument values.
 
@IvenBach yes
 
How do I enable it?
 
well, I think so. You're making me doubt now!
 
Or is it only the Immediate Window?
 
Can't you just hover the operator?
Wait you can highlight a statement in the VBE and hover-evaluate the selection????
 
5:30 PM
@MathieuGuindon ^
Note the hovering tooltip.
If it's not a tooltip forgive my #Words usage.
That's what I'm wanting to know if VS can do.
That's a VBE feature I use often.
 
I thought that was common knowledge.
That'll be an article for sure then.
 
If you don't select anything and just hover the first And you get isFoo And isBar = True, right?
 
@IvenBach better. VS has "watches".
you can define expressions that VS evaluates for every debugging step you perform
works for arbitrary expressions, even those that you can't highlight :)
 
@MathieuGuindon it shows isFoo = False in the hover
@Vogel612 VBE has them too. I use watches often as well.
 
5:45 PM
I've used conditional breakpoints in VS, but I find watches somewhat redundant... I just use the locals window
 
@MathieuGuindon watches have the advantage of allowing you to perform stuff on the locals that would be hard without expression evaluation
 
I suppose. conditional breakpoints are a blessing for debugging the resolver though :)
@IvenBach wait that's not consistent with the expression.... how is isFoo possibly False??
 
@MathieuGuindon In the above image is will be True. I had exited the sub and just F8 once to step into it causing the evaluation to be False because it's never assigned.
 
1
Q: loop code through each slicer value selection

aNobleNoobI have a PivotTable with a slicer that has 5 filters. I'm looking to have these filters to each be selected individually one by one and run a copy/paste code for every filter selected. I've set up the code to work for each filter so far with completely rewriting/copying each code for each filter...

 
6:16 PM
hm, do we need an inspection to flag a foo = foo instruction as redundant? (assuming foo is a local intrinsic-type variable and not an object with a default member)
 
6:52 PM
@IvenBach makes a note for the next time pwd expires
@KySoto I have a nice, long, meaningful but no longer relevant phrase as my master pwd. Most of my web accounts have fully random KeePass generated pwds.
@MathieuGuindon #MeToo
 
7:08 PM
Fresh RD install on Excel 2016. Empty add-in ribbon. I'm missing something obvious.
Yes, I've tried the repair function.
 
@Mast yup. RD is not an Excel add-in :)
hit Alt+F11
 
facepalm
 
you're welcome :)
 
Thanks @Mat
 
@Mast :+1: I do that constantly.
 
7:19 PM
@Mast don't worry, it's almost Friday!
 
Well, at least I figured it must've been something obvious. So there's that.
 
@Mast what brings you into the wonderful word of VBA? work? curiosity? masochism?
 
@MathieuGuindon Changed jobs a couple months ago, now I draw (among other things) electrical schemas for large installations.
You wouldn't believe how much that world runs on Excel.
 
nah, I do. Excel runs the world.
 
So I'm automating the crap out of my job and, every once in a while, try to improve my Frankensteins by polishing the result.
If picking a part is based on parameters, let Excel do the job. All those parameters go in tables anyway.
 
7:25 PM
oh fml... I die everytime I need to use a colleague's French Excel
 
The person who wrote the crap I inherited no longer works here, so I can't really ask him what he was smoking either.
So, last moth I learned the power of array formula. And that if you really like those, you should VBA instead.
Or I haven't fully learned he power of array formula, but, you know...
 
@Mast you make a vlookup (or match) function work with 2+ columns by adding a helper column that concatenates the lookup values
 
@MathieuGuindon ummmm... but you speak French, do you not?
 
@MathieuGuindon That gets incredibly messy I found out.
 
@FreeMan yes. and I wasted 10 minutes of my life figuring out that MID is STXT in French
 
7:29 PM
@FreeMan Canadians mainly swear in French.
 
@MathieuGuindon LOL!
 
@Mast huh, just hide the helper column..
 
@MathieuGuindon That's why I use translation sheets for Excel.
@MathieuGuindon Oh, like that.
 
My daughter spent a semester in Spain, so she set her mac book to Spanish. When she got back, she reset it to English. Only mr. mac didn't like that so well. Now she gets system messages in Spanglish. they're about 1/2 Spanish and 1/2 English.
 
@FreeMan lol
 
7:31 PM
FWIW =IF(ISBLANK(A2);"";IF(A2="Not Available";""; ... can turn into =IF(OR(ISBLANK(A2);A2="Not Available");"";...
 
but very frustrating when I have to use it because my Spanish is pretty much limited to no hablo
 
Reminds me of a German CAD program that's installed in English on Dutch computers, using Dutch in one place and English in another while at times being improper translations with a heavy German background.
 
eh, localization is hard
 
"improper translations with a heavy German accent" is how I read that. Much funnier that way
 
case in point, bring up RD code inspections - it's possibly a mix of English and German
 
7:33 PM
@MathieuGuindon That would actually improve it quite a bit already, but that particular function was simply too cumbersome to be resurrectable. It had to die so something better could rise.
 
it does look like it's quickly approaching the nesting limit
(7 levels IIRC) I apparently don't RC
 
@Mast I prefer to group the column itself from Data tab>Outline group>Group split button (top half). That way you have in indicator that something is hidden. As well as an easy way to hide several grouped/hidden columns in one click.
 
@MathieuGuindon I didn't count the parentheses, but if it ends with )))))))))))))))))))))))))))))))), I know enough.
 
that's a good indicator :)
 
One of these days I'll actually be posting some VBA on CR, after it has been through RD.
Which isn't as straight-forward as it should've been thanks to IT.
You lot put in a lot of effort to not require admin privileges to install RD and we're missing a framework out of all things.
 
7:40 PM
:sadface: ouch
 
@MathieuGuindon Meh, Excel is easily abusable as a combination of GUI, pseudo-DB and presentation platform. There's no other language that can trump it AFAIK.
 
lol tell that to the "real programmer" guy on that thread, that brags about coding in notepad and VBA being a "child's toy"
 
Languages come and go, Excel is forever.
2
 
> pffft. Hammer? Don't need it. I use my dense forehead for such trivialities.
 
7:53 PM
"Attention! Do not ride a car on this open space." doesn't seem right.
 
> Close #2776

Past-Iven opened this. Since then current-Iven has become more familiar with coding and using regex. This PR may no longer be applicable. Still submitting it as a means of review. And to show myself how past-Iven has progressed through small daily effort.
 
@this Yes, that's the joke.
@Duga lol
 
??
 
@Mast but is it in Germany?
Also, I am also confused by the apparent fried chicken picture as well. (but that might be just the photo being too blurry to make sense of what that blob is)
 
@this It's probably on a movie set.
 
8:00 PM
Ok, so not an actual road sign somewhere in Germany. That've been bad.
because TBH, I don't know what to make of not riding a car in an open space.
 
@Duga @IvenBach "Enclose whitespace in identifier" does what?
 
I suppose it's OK if you drive rather than ride, so no passenger. And it's OK to ride if the space is closed.... presumably in a tunnel or something. Share road with subways, perhaps.
 
@MathieuGuindon Encloses them in { }
 
I don't like the term "identifier" for this
 
I've no attachment to the word.
 
8:06 PM
:)
 
My struggle with #Words is well known.
 
not sure what a better term might be (curly braces?), but "identifier" is definitely confusing
 
@IvenBach encode them as binary. Then it's just #Numbers.
only 2 kinds, too :)
 
It could be [ ] square bracket ( ) parenthesis or whichever thing to help indicate it's there.
would indicator be more appropriate?
 
placeholder? ...IDK. thoughts @all?
 
8:11 PM
Is already in the PR comment it mayn't be applicable. Past-Iven previously thought it might help with RD users unfamiliar with regex.
 
8:24 PM
[rubberduck-vba/Rubberduck] build for commit 351fc699 on unknown branch: AppVeyor build succeeded
> # [Codecov](https://codecov.io/gh/rubberduck-vba/Rubberduck/pull/5044?src=pr&el=h1) Report
> Merging [#5044](https://codecov.io/gh/rubberduck-vba/Rubberduck/pull/5044?src=pr&el=desc) into [next](https://codecov.io/gh/rubberduck-vba/Rubberduck/commit/1c9a6b957b7241f2e04ca4f938e06a2955e295d7?src=pr&el=desc) will **decrease** coverage by `0.01%`.
> The diff coverage is `63.64%`.


```diff
@@ Coverage Diff @@
## next #5044 +/- ##
=======================
[rubberduck-vba/Rubberduck] build for commit 351fc699 on unknown branch: 64.22% (target 0%)
 
@MathieuGuindon so I'm clear, that's matching hte literal { and }?
If that's the case, the word I would have used is character....
 
> # [Codecov](https://codecov.io/gh/rubberduck-vba/Rubberduck/pull/5044?src=pr&el=h1) Report
> Merging [#5044](https://codecov.io/gh/rubberduck-vba/Rubberduck/pull/5044?src=pr&el=desc) into [next](https://codecov.io/gh/rubberduck-vba/Rubberduck/commit/1c9a6b957b7241f2e04ca4f938e06a2955e295d7?src=pr&el=desc) will **decrease** coverage by `0.01%`.
> The diff coverage is `63.64%`.


```diff
@@ Coverage Diff @@
## next #5044 +/- ##
=======================
 
@this the idea is to make the whitespace more apparent in the regexplainer tool
what's matched is the space character between { and }
 
hm
how do I know it's a space, though?
it could be nbsp for all I know.
 
that's a tough UX problem right there
 
8:30 PM
my vote would be for stuff like <space>
<tab>, <non-breaking space>, <linefeed>, and so forth. Note using italics to set it off apart from other literals.
 
I can stand by that
 
back to the original question, I'd call them literal characters, I guess.
 
yeah, that's what the match is being called. we're discussing what to label the checkbox with though
 
> FWIW, while this is an improvement, I'd prefer to be more explicit about what whitespace those are because there's no apparent visual difference between a space, a non-breaking space, a tab (under right conditions) and so forth. I think it's probably best to spell them out --- e.g. <space>, <tab>, <line feed>, <non-breaking space> --- using italics to set them off. Just a thought; I'm happy to take the PR as-is, though.
 
oh I see.
Speaking of PRs, the ComCommand PR needs a bit of reviewing eyes....
 
8:39 PM
@Duga @this the < and > eat the words.
 
escape it.
 
Came through in chat but in GH it's just several commas together.
 
facepalm
 
We've had 2 do that today in chat. Just need a 3rd for a hat-trick.
 
> FWIW, while this is an improvement, I'd prefer to be more explicit about what whitespace those are because there's no apparent visual difference between a space, a non-breaking space, a tab (under right conditions) and so forth. I think it's probably best to spell them out --- e.g. &lt;space&gt;, &lt;tab&gt;, &lt;line feed&gt;, &lt;non-breaking space&gt; --- using italics to set them off. Just a thought; I'm happy to take the PR as-is, though.
 
8:42 PM
Now it's escaped.
Gonna lurve the consistency between SE and GH....
 
Besides space, tab, line-feed, non-breaking-space, carriage-return are there any others I should know about?
 
I think it's all characters 0-32 and the nbsp in ASCII table.
though I would very much hope nobody tries to regex a bell character....
 
Doing so might cause ducky to ring their bell.
 
Hmm that'd be an Easter egg inspection WhyAreYouScrewingWithThoseObscureCharactersInspection
 
RegexSpectacularFail
 
8:44 PM
^
Come to think of it, I have my dobut you can type the literal bell character in an regex epression
you might have to use the unicode code (e.g. 0x0008 or whatever)
 
I'll stick with the ones already mentioned for now. YAGNI for the rest.
 
^
2 mins ago, by IvenBach
Doing so might cause ducky to ring their bell.
the only other one i'd actually add is carriage return.
A certain OS likes them carriage returns....
 
Windows?
 
:)
 
Can/should the pattern specifier ever be more than a single character?
 
8:48 PM
you mean like CRLF?
to me that's 2 characters.
 
Hrm... the specifier.Value is of type String. Could it be converted to char without issue?
 
I think so, at least if it's one character.
3
A: C# - How to convert string to char?

Juned Khan MominUse: string str = "Hello"; char[] characters = str.ToCharArray(); If you have a single character string, You can also try string str = "A"; char character = char.Parse(str); //OR string str = "A"; char character = str.ToCharArray()[0];

 
It's enjoyable working on RD now that I haz a clue what I'm doing.
4
 
9:11 PM
@this sorry to bug but how do I get those characters into the TextBox?
Tried copy and pasting but didn't work. I rarely generate them myself.
 
need more context
you're modifying XAML or ?
 
Trying to just insert the nbsp char or tab or linefeed into the text box to test.
 
for the regex specifier you mean?
 
Yes.
 
I think they are stuff like /n or /t or whatever it is. I never remember which's which
need to look at regex cheatsheet
 
9:15 PM
:derp:
 
doesn't help there's flavors of regex.
 
Why am I going about this as a user? I can just put them in myself.
 
though the regex assistant probably adhere to the vbs' flavor.
 
I saw that.
Why didn’t it occur to me to supply them at a direct argument the first time.
 
> I am in the process of writing VBA to do this for me and my limited use cases. It'll end up being an add in. It will look for all open workbooks that have at least one list object (table) and present the workbooks as candidates (optionally Browse... to open a workbook). Selecting a candidate will list all worksheets that have tables. User will select the tables to be used. Models and Proxies will be created along with Presenters and UserForms with Apply and Cancel buttons. IData and IDialog in
 
9:17 PM
@Duga race is on!
 
10:04 PM
private string ConvertWhitespaceToStringName(string whiteSpace)
{
    switch (whiteSpace)
    {
        case "\t":
            return RubberduckUI.RegexAssistant_SpelledOut_Tab;
        case " ":
            return RubberduckUI.RegexAssistant_SpelledOut_Space;
        case "\n":
            return RubberduckUI.RegexAssistant_SpelledOut_NewLine;
        case "\r":
            return RubberduckUI.RegexAssistant_SpelledOut_CarriageReturn;
        case "\r\n":
            return RubberduckUI.RegexAssistant_SpelledOut_CarriageReturnNewLine;
I'm trying to figure out where that should go. Presently it's housed in the Rubberduck.RegexAssistant/Atoms/CharacterClass.cs. But realized it also needs to be accessed by the Group and Literal classes in the Atoms directory.
Would a new static class with a single static method be appropriate?
Rubberduck.RegexAssistant/VBRegexParser.cs already has all static members. It kind of fits in with parsing.
 
is VBRegexParser ours, not code-generated?
 
AFAICT yeah VBRegexParser.cs is ours.
hrm.... But everything on it is private.
 
doesn't look appropriate, TBH
 
I guess I'll create a class for it then.
 
10:55 PM
I don't know if this code is the bad kind of "clever".
 
00:00 - 23:0023:00 - 00:00

« first day (1861 days earlier)      last day (1319 days later) »