« first day (381 days earlier)      last day (2799 days later) » 
00:00 - 17:0017:00 - 00:00

5:11 PM
edited
@RubberDuck could CWell be anything other than a class module?
 
I don't think so.
 
5:38 PM
Did @Phrancis star that?
 
woah, I'm already at +190!
 
I'm still at 0.
 
@RubberDuck ? I did...
 
No, 10.
Somebody voted a 1-away.
I might be able to post my resx editor later.
 
Damn. I need to quit playing with this sku class and go write some answers.
 
5:42 PM
0
Q: WPF Datagrid edit cell on mouse double click

TomIn WPF i've added a DataGrid: <DataGrid x:Name="dataGridProdotti" HorizontalAlignment="Left" Margin="10,56,0,0" VerticalAlignment="Top" Height="250" Width="426" SelectionChanged="dataGridProdotti_SelectionChanged" IsReadOnly="False"/> with the property IsReadOnly="False" Then i do: dataGri...

There's my answer.
 
WTF
 
Something you can't see didn't get filled in....
I wish I didn't know exactly what that was....
Can I get three lines with identical character counts?
Damn.
 
 
1 hour later…
6:57 PM
It saves when I tell it to!
 
@Hosch250 you implemented voice recognition??!!
 
No.
When you stop editing a cell in my resx editor, it saves it.
 
nice
 
I put it up on GitHub.
 
next, put it up on CR!
 
6:59 PM
Not yet - it needs more work.
 
...but I need more rep to stay ahead of @SimonAndréForsberg! lol
 
I need to make either a file picker or a textbox to put the path in.
Right now, it is hard-coded.
 
0
A: VBA "Compile Error: Statement invalid outside Type Block"

FreeManYou have: Dim RangeNOut as Double Dim RangeNOut as Integer While the IF statements in there are a nice idea, VBA will not allow you to do that. It doesn't do conditional 'compilation' since it isn't a compiled language. When VBA runs your code, all your variables are declared (no matter where ...

 
@Mat'sMug Not yet - maybe in a few years.
@Mat'sMug Exactly what file do you put the hook in so @Duga posts messages here?
I can't find it.
Is it in the hooks files in the .git folder?
 
7:14 PM
@Hosch250 @RubberDuck set that up
 
OK.
 
Well, my answer is about 99.9% correct then. He can't do it the way he wants, but I had no idea you could do conditional compilation in VBA! Kinda nifty.
I'm at a mere 80 SO points today. Would be 95 if some goober hadn't un-checked my answer, then pasted in my code and checked his own answer... :/
 
Flag him.
 
That ^ can't be good...
 
@FreeMan Thanks for giving me an opportunity to whore myself promote my blog.
 
7:25 PM
@RubberDuck Any time, my good man, any time!
 
@Phrancis Dude.... that thing spits out errors I've never seen before. That's truly an accomplishment.
3
 
Ah, I think we had a brief network outage, Outlook lost connection too
 
7:42 PM
of interest:
0
Q: ReplaceLine method in VBE only replacing part of line

John ColemanIn response to this question I thought it would be fun to write a VBE macro that would automatically replace lines which look like DimAll a, b, c, d As Integer by Dim a As Integer, b As Integer, c As Integer, d As Integer In my first draft I just want to modify a single selected line. After...

another whoring self-promotion opportunity, @RubberDuck
 
lol
 
@FreeMan Flag it
@FreeMan I'll upvote if you link to it
 
@Chrismas007 meh, thanks, but I'm not really that worried about imaginary internet points.
2
it's fun and all, but I'm not going to get my panties in a bunch about it.
 
8:04 PM
There's the offer letter!
4
About time.
 
8:18 PM
@RubberDuck This was mostly proof of concept. It definitely needs polishing. For one thing, probably no one writes Dim a,b,c,d As Integer with the intention of declaring a,b,c as Variants. It would make more sense to skip that part about DimAll and just expand all things that look like Dim a,b,c,d As Integer in the entire project. Ultimately, I would like to figure out how to turn it into a VBE add-in with keyboard shortcuts. I'll look at that link — John Coleman 6 mins ago
@Mat'sMug I'm recruiting devs over here. ^
 
seeing that :)
he's got a point. the inspection/quickfix was implemented to not change what the code is doing. perhaps we could implement another quickfix, a smarter one, for when only the last type is specified.
 
@Mat'sMug I think you will probably be ahead of me for a while.
 
0
Q: I want to search items in Excel for certain keywords which are then copied to another sheet and highlighted

wesreeOption Compare Text Public Sub Textchecker() ' ' Textchecker ' ' Keyboard Shortcut: Ctrl+h ' Dim Continue As Long Dim findWhat As String Dim LastLine As Long Dim toCopy As Boolean Dim cell As Range Dim item As Long Dim j As Long Dim sheetIndex As Long Dim inclusion As String sheetIndex = 2 Con...

 
@SimonAndréForsberg uh, on the [All] tab? not expecting it.
 
I am expecting it
 
8:24 PM
so you already updated your CV to say #6 on Code Review?
 
damn, right. No, haven't done that yet
 
FWIW you're still showing up at rank 5
10 Simon's on the wall
 
you'll easily pass by me there
 
@StackExchange man, the guy assigned macro to Ctrl+H
> John: Support, John speaking.
> Eric: Yeah hi John. My Excel is acting up. I can't find/replace anymore, wtf's happening?
 
8:44 PM
BTW, did you know that CTRL-R is already used in the VBE?
If we want to do CTRL-R, CTRL-? for refactorings, we've got to change that one too.
 
displays the project explorer IIRC
 
Yup.
 
multistep shortcuts won't work
 
Oh, they don't?
 
we'll have to go with Ctrl+Shift+Something
 
8:45 PM
I think they can.
 
but there's no statusbar to mention the UI is expecting a keypress. it would be awkward UX
 
Just like you have to use a Boolean value to remember when the CTRL key is pressed, and release it when released, just remember when CTRL-R is pressed, and release it on next key release.
Yeah, but still possible.
We could, implement a statusbar?
 
that would be a massive hack
 
Lol, isn't RD one massive hack?
2
I mean, we hi-jack the context menus and stuff...
I've got the UI to select the resx files done, now I just need a file picker.
 
@StackExchange Is this the source for Clippy?
2
 
8:47 PM
but pretty much everything in RD is in the VBEIDE library. I mean, the ability to add menu items is a feature of the API
 
> findWhat = CStr(InputBox("What word would you like to search for today?"))
 
I think I'll steal RD's.
Oh wait, that is GPL, and mine is unlicensed/viewable-closed-source.
 
^^
 
NVM, I don't even need it.
28
A: Where's the file-picker dialog in WPF?

Anna LearThere is no built-in control that has a textbox with a [Browse] button beside it. You gotta set that up yourself. For the "open file" dialog itself, there is the OpenFileDialog in Microsoft.Win32 namespace.

I've got my UI, I just need to use that.
 
9:02 PM
@Hosch250 shhhhhhh no one's supposed to knwo that.
 
Lol.
 
if we had the ability to add a statusbar to the VBE, we'd also have the ability to add a bar with colored notches next to the code pane vertical scrollbar for every inspection result, click-to-navigate, and a little floating icon with a dropdown to select a quickfix
I don't do assembler.
the only code I've seen doing anything remotely similar, is the $$$$$ add-in that lets you walk the VBA stack trace with an API.
partly written in assembler
I don't do assembler
did I say I don't do assembler?
 
That app doesn't even use assembler. It uses hex code.
It's frakking binary mate.
 
damn
like, fuck it. bold. red. underline.
TTQW
 
9:18 PM
@Mat'sMug don't forget all caps
 
0
Q: Modifying VBA copy and paste code to search down rather than across

114I have the following VBA code: Sub test(): Dim NameValue As String, w1 As Worksheet, w2 As Worksheet Dim i As Long, j As Long, k As Long, c As Long Set w1 = Sheets("Sheet2"): Set w2 = Sheets("Sheet3") GetNameValue: For i = 1 To w1.Range("A" & Rows.Count).End(xlUp).row If w1.Range("A" &...

So: Many: Colons:
 
Why in the world did this get 1k views, and not some of my other questions?
5
Q: WPF UserControl

Hosch250I wrote my first WPF UserControl today, and I would like you to review it. Its purpose is to have images by default resize with the page, but expand to full size with a double-click: <UserControl x:Class="MyApp.ImageDisplay" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presenta...

I got the UI fully working.
I just need to update when the user deletes a row, and let them add a row.
I'm almost ready for CR.
 
10:02 PM
Remove is done.
Only thing before CR is allowing the user to add a row, I think.
 
@Hosch250 that's a bad title ;-)
 
Maybe that's why it got the 1k views?
 
Yeah well, probably came up on google searches with such a title.
Good titles get views and votes ;-)
 
11:06 PM
Ready?
I'm posting on CR.
Wait - one more bug.
 
11:20 PM
Aw...I'm out of ammo till reload!
 
#VBA CallByName saves the day! http://codereview.stackexchange.com/a/94344/23788
 
@Mat'sMug Ditto.
 
11:46 PM
in TCG Creation, 1 min ago, by Duga
Mat's Mug vs. Simon André Forsberg: 30 diff. Year: +971. Quarter: +1721. Month: +375. Week: +95. Day: +155.
seems like this hasn't really been my quarter, @Mat'sMug
 
Done.
Wait, I've got to move my strings to the resx.
 
0
Q: Need VBA code to find Frequency of occurance of 2 or more consecutive zeroes

user76130I have sales data for rolling 12 months and for each month and I have sales data. I want to write a VB script where I have to take the salesperson opportunity into consideration( if he joined 3 months back then his opportunity is 3 and this field is already present in the excel sheet). I need to ...

 
00:00 - 17:0017:00 - 00:00

« first day (381 days earlier)      last day (2799 days later) »