« first day (1649 days earlier)      last day (188 days later) » 

12:00 AM
RELOAD!
[rubberduck-vba/Rubberduck] 11 commits. 2 opened issues. 5 issue comments. 5992 additions. 3006 deletions.
[rubberduck-vba/RubberduckWeb] 2 commits. 10018 additions. 210 deletions.
 
12:50 AM
@MathieuGuindon That reminds me of Bill & Ted.
 
@M.Doerner isn't that a separate concern? The parsing project should only deal with providing a service for writing to both code and to attribute, while the refactoring would choose to use that service?
 
@M.Doerner technically we could swallow all non-navigational keystrokes in code panes when a parse is running... but then, get that done wrong and the VBE is essentially bricked.. not sure it's a good idea
@FreeMan the fiery furry browser has a memory leak?
 
1:08 AM
More likely a JS memory leak running on an open tab.
@FreeMan See what about:memory shows. It's usually either a script or a plugin.
I think the ReferenceSettings are going to be close to half of all the settings tests if I keep going at this rate.
 
Its not so much the amount of memory that FF is using, it's Windows' Memory Compression that's chewing up massive amounts of CPU...
 
@Comintern eh, was just looking for a reason to write "Fiery Furry"
 
lol
 
1:53 AM
So I have this code that does work:
container.Register(Component
    .For(typeof(RenameView), typeof(IRefactoringView<RenameModel>))
    .ImplementedBy<RenameView>()
    .LifestyleSingleton()
);
container.Register(Component
    .For(typeof(RenameViewModel), typeof(IRefactoringViewModel<RenameModel>))
    .ImplementedBy<RenameViewModel>()
    .LifestyleSingleton()
);
container.Register(Component
    .For(typeof(RenameDialog), typeof(IRefactoringDialog<RenameModel, IRefactoringView<RenameModel>, IRefactoringViewModel<RenameModel>>))
but this isn't ideal since that's hard-coding and would need to be done for every refactoring. We obviously want to do it by convention.
But with generic, well CW seems to get lost.
 
I wonder if that's because of the mangled internal naming for generics.
I had a hell of a time with that when I was trying to reflect on EF assemblies.
 
sorta - if i don't close the types, it will get the wrong type because there's mutliple matches
e.g. we have 5 implementations of IRefactoringView<> but only 1 implementation of IRefactoringView<RenameModel>
 
Right. I can't tell WTH it's doing based on your working registration.
 
and the documentation is a bit sparse on that point. :-\
i'm trying out the WithServiceSelect() now
 
TestCases rock BTW. 44 tests, 474 LoC.
 
2:04 AM
nice!
 
What sucks is that I need 44 tests for the ReferenceSettings alone and I'm not sure I covered everything.
 
Now the proud owner of Classic Computer Science Problems in Python: https://www.manning.com/books/classic-computer-science-problems-in-python. Thanks, @ManningBooks #Countdownto2019
Thanks for the like, Mat.
 
TBH, I wouldn't be surprised if it needed to be more than just 44.
Because reference management is a complex thing
 
^
Oh, that's the settings
 
and besides, the point of the tests is that if they report a bug, it's easy to make a red test and prevent that bug forever and more.
 
2:06 AM
It has to track per host pinned and recent lists, and the user settings dialog can't wipe any of that away.
 
(except for the case where you're trying to imitating VBE exactly...)
 
I apparently succeed at making all of this stuff moderately testable though.
 
Check out my little "IDE".
I have some ideas up my sleeve on what to do with this. Stay tuned :)
 
...and 44 of 44 tests failing because of a typo.
> System.ArgumentException : Byte array for GUID must be exactly 16 bytes long.
 
@Hosch250 have you seen the C# scripting tool?
Also, do you think that will end up in RD? :-)
 
2:19 AM
I love finding misunderstandings and misspellings for common idioms and phrases that totally change the meaning. Who knows others? - The plot sickens - Taken for Granite - Escape Goat - For all intensive purposes - Piece of mind - Peaked/Peeked my interest - Nip It in the Butt
 
2:46 AM
@Hosch250 I'll give you a like when you finish the book.
My recent experience has taught me it's much easier to buy the book than to read it. Entirely different again to understand and get the knowledge from reading.
 
3:12 AM
@IvenBach Well, I'm 4 chapters into my Microservices book. I'll (almost) finish that one on my vaca.
I'm also 4 (smaller) chapters into my F# book (lots of small chapters there). Reading that one in snatches at work because I left my microservices book home for now, since I'm kind of busy.
I'll finish both of those first, then this one. Probably by June of next year, although might be longer, depends how many fires work manages to start.
@this I'm going to publish it on GitHub unlicensed for backup purposes, because if this works out, I might monetize it. However, I will license anything you feel would be interesting to you as MIT.
Depending on where I take this, I might even make (parts of) it open source under MIT.
I'm planning on turning it into a training tool, like how so many other language sites let you run the code right as you do the training.
The important part will be the content.
I need to redo the UI, this is just PoC.
 
Ah, yeah. A fiddle is very useful.
that'll be fun. :)
 
And yes, I used the C# scripting window in VS regularly.
Frequently to generate new guid's for stuff we hard-code guids in at work.
(Stuff that relies on it being the same across all our sites and needs to be seeded.)
 
@Comintern thanks for the rubberduck earlier - I now have something I can work with. I will come back to it tomorrow but I think I'm on the track to get the closed types registered by conventions.
 
@PeterMTaylor They were also the first to not read the ToC :)
 
NP, not entirely sure I was more helpful than a literal rubber duck though.
 
3:22 AM
and that was all I needed; had to articulate my thought a bit more
 
3:49 AM
@Hosch250 :) sorry for a typo on Twitter.
 
 
4 hours later…
7:36 AM
Hi folks. Please, a little help with translations.

I pulled from `origin https://github.com/rubberduck-vba/Rubberduck.git (fetch)`
Then opened the project in VS
Added few lines of translations, modified other
Cleaned the project
Built the project
Opened RD and I don't see the changes. What do I do wrong?
 
 
5 hours later…
12:10 PM
@SonGokussj4 @SonGokussj4 you said you did "fetch" - did you actually pull after you fetched? Fetching only updates the tags but pulling pulls the changes.
 
12:27 PM
@Comintern at least you know now
@Hosch250 Maybe you could demo that to the "I'm a beginner, but I'm writing an OS in VBA" guy
@Hosch250 needs to readjust thinking... Read that as "Piece of Crap" before realizing you meant "Proof of Concept". Brain has just not been right lately...
 
@this I apologize. I did the pull, not fetch. Was writing that on the morning without coffee.
 
@this *in theory ;-)
11 hours ago, by this
(except for the case where you're trying to imitating VBE exactly...)
yup, that
 
@SonGokussj4 Just to be sure I understand the problem - the RD is working just fine but it just isn't showing your new czech translation, right?
w00t! Got it working!
This is the IoC registration I needed.
        private void RefactoringDialogRefactor(IWindsorContainer container)
        {
            container.Register(Types
                .FromAssemblyInThisApplication()
                .IncludeNonPublicTypes()
                .BasedOn(typeof(IRefactoringView<>))
                .WithServiceSelect((type, types) =>
                {
                    var face = type.GetInterfaces().FirstOrDefault(i =>
                        i.IsGenericType && i.GetGenericTypeDefinition() == typeof(IRefactoringView<>));
#NotComplicatedAtAll
 
1:30 PM
I'm having a brain dead morning so far... I start with:
  Dim outputWB As Workbook
  Set outputWB = Workbooks.Add
Then I do a lot of stuff (wide variety of routines called). At the end of all that, instead of blindly doing outputWB.Close, how do I check to see if the workbook is still open first so that the .close doesn't throw an error?
struggled to even put all that into words... May need sleep.
 
meh. I'd just stick it in a OERN-OEG0 block (or make a function just for that purpose).
I suppose you could do a For Each wb In Application.Workbooks : If wb Is outputWB ...
 
1:45 PM
Was thinking something like:
if outputWB.IsOpen Then
  OutputWB.Close
End If
 
Any objections to not mocking up a registry? I'm not entirely sure it would be useful.
 
but .IsOpen isn't a valid option. If outputWB <> Nothing Then... ??
 
no, Nothing test won't help you
that's why I said just to do a OERN-OEG0.
 
Getting with-it-er today (at some point). Coffee isn't helping.
OREN it is, then.
 
or creating a function IsWorkbookOpen to encapsulate that.
 
1:47 PM
I just want to close it w/o error (not that I've had that particular error with all the other things I've had go wrong...)
thanks.
 
@FreeMan What about checking for the lock file (~workbook.xlsx) in the directory?
 
Maybe I should stay outta my code until my head clears up. Or at least make a backup
@Comintern that could be a nifty little IsWorkbookOpen utility function ...
 
@Comintern apparently someone else had the same problem: github.com/Haacked/Rothko
 
PSA: Take everything @FreeMan says today with a huuuge grain of salt. He is currently experiencing a major brain malfunction. Brain will be rebooted shortly.
 
The only limitation is that you need to know the full path.
 
1:50 PM
@Comintern isn't it only true if it's not opened read-only?
 
@Comintern workbook.fullname or workbook.path or something along those lines, right?
 
@this Hmmm... you might be right about that.
 
in this case, it's my output WB, so it won't be RO...
 
@FreeMan Yes, except you would need to know that from somewhere other than the workbook. I think asking for the path will throw if it's closed.
 
@FreeMan sure - just don't make it a generic function that promises to work in any situation.
 
1:52 PM
^
 
e.g. a private function in a class
 
^that could be a good test. ;)
 
2:31 PM
Trying to decide what to log and at what "detail" level is about as hard as naming stuff
 
Yes, that's it. After rebuilding it. I think it will be some stupid thing but don't know what.

My immediate git status is this
/GIT/Rubberduck$ git status
On branch next
Your branch is up-to-date with 'origin/next'.
Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

        modified:   Rubberduck.Resources/CodeExplorer/CodeExplorerUI.cs.resx
        modified:   Rubberduck.Resources/Inspections/InspectionNames.cs.resx
        modified:   Rubberduck.Resources/Inspections/InspectionResults.cs.resx
        modified:   Rubberduck.Resources/Inspections/InspectionsUI.cs.resx
 
2:54 PM
@FreeMan I don't get what this is supposed to mean.
@PeterMTaylor Pfff, Twitter is for typos.
 
@Hosch250 Mug was having a go 'round a week or two back with some guy who was asking a bunch of very poor, very vague questions about writing an OS in VBA. It was funny to me. Maybe I needed more coffee...
 
3:10 PM
lol
I got a PR on retailcoder/vbtools for an edge-case bug in my old StringFormat function. I should probably write a bunch of RD unit tests for it.
 
@SonGokussj4 I don't think Templates.resx needs to be localized.. right @this?
 
Does it have comments?
 
hmm
  <data name="PredeclaredClassModule_Caption" xml:space="preserve">
    <value>Predeclared Class module (.cls)</value>
  </data>
  <data name="PredeclaredClassModule_Code" xml:space="preserve">
    <value>VERSION 1.0 CLASS
BEGIN
  MultiUse = -1  'True
END
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Attribute VB_Ext_KEY = "Rubberduck", "Predeclared Class Module"

Option Explicit</value>
  </data>
  <data name="PredeclaredClassModule_Description" xml:space="preserve">
there's a typo in PredeclaredClassModule_Description
 
only the other 3 entries, not the code
 
3:18 PM
IMO these belong in a namespaced resource
I thought Templates.resx only contained code templates
 
needed the caption & stuff for the menu items
@MathieuGuindon Nah it's speeled right.
 
There's also a persistent misspelling I introduced into Rubberduck.SettingsProvider 3 years ago that I should fix at some point when it won't be obnoxious.
 
maybe need to run it through code analyzer? extension? something? that does spell checking. I wouldn't leave it in by default, though - as it might end up more obnoxious than the occasional typos that do make into the codebase.
 
I only found it because R# added one.
 
3:34 PM
@FreeMan I know. I still don't see how it's relevant to that screenshot.
 
> It was funny to me. Maybe I needed more coffee...
Pretend it didn't happen.
 
4:14 PM
...Pretending in progress...
CRITICAL ERROR!
Belief suspension broke.
Please purchase a new one and try again.
 
I just can't see how a C# fiddle is at all similar to a VBA OS.
 
4:30 PM
@Hosch250 Probably in that a "VBA OS" would likely look just like that and wouldn't be able to do much more than what you displayed? (I just can't wrap my head around the idea of a VBA OS... How could that even remotely work? As a virtual machine maybe? You'd need a VBA host first, nonetheless. And that one wouldn't be in VBA...) Anyway, just my humble guess. ;)
 
A VBA fiddle would be completely badass.
 
don't we kind of have that w/ the immediate window, though?
though I wonder - could we expose the hidden immediate module as a code pane...
 
mumble mumble today better mumble better than yesterday mumble. Morning.
 
@this Only for single lines of code though.
In c# you can do things like linq expressions in the VS immediate window that would be impossible to check in VBA without coding the loop.
 
yeah.
to be fair, though, even in VS, immediate window is iffy
(mainly because of threading)
but if we can expose the hidden immediate module as a codepane, that'd be a big prize, having a proper scratchpad.
In my project I always add a zzzScratchpad module but... blech.
 
4:40 PM
Pwning the VBE Immediate Window is a longstanding goal of mine. I just keep getting sidetracked.
 
IKR? There's so many to do!
 
My goal is to win the lottery, quit my job, and work on RD full time.
3
 
lol
pretty sure you're not the only one
 
0
Q: Excel Range less clumsy

grNadpaAs an old dog (age 73) learning new (Excel VBA) tricks, I am reasonably happy with putting together the code below. But I think it could be cleaner. How would you have coded it? Private Sub Workbook_Open() Dim lastRow As Long 'last row with data Dim thisDate As Double 'start tim...

 
Yep, mine too, except I won't win because I don't play.
 
4:47 PM
@Hosch250 I guess "as an example of something that's actually achievable". Dunno. brain's still non-functional today. It sounded good when I first typed it.
 
Well, you still can win without playing.
It's just a matter of finding a lottery ticket that someone else lost.
 
LOL.
 
But if you did that, you'll have to change your name to Earl.
 
That's happened a couple times.
 
Is there a limit on how many lottery tickets you can buy?
 
4:48 PM
how much money do you have?
 
Not enough.
 
They'll happily take it all...
 
No. Although there is a feasible ammount.
 
I mean, I should calculate how much the value is vs the cost of buying enough tickets to hit every number once.
 
I've thought this through - it's largely limited by the logistics of printing the tickets.
 
4:49 PM
Story on NPR about a guy who played the odds against the numbers and bought enough lotto tickets to win several jackpots over various years.
 
If the first is greater than the second...
 
@Comintern Basically what he was limited by.
He had to go to various liquor stores and buy a set amount if tickets. Something like 100,000 per store.
 
I.e., I'm allowed to purchase a million tickets, but it would take longer than the 4 days between drawings unless I was paying temp workers to go the convenience stores for me or something.
 
LOL.
 
4:50 PM
Swing by all the gas stations and booze stores in town.
 
10,000 tickets at a time. My memories none too good.
 
One time in the UK when the jackpot got silly-big, a consortium was trying to see if they could buy every permutation on the basis they were almost guaranteed to profit. IIRC it got denied because they weren't UK registered. They may have tightened up the rules by now.
 
I'd be "that guy" everyone waiting to buy a six-pack would be stuck behind in the line - "Ummm, and can I get ten thousand Power Ball quick-picks?".
 
> someone managed to buy every single combination of tickets to guarantee a win.
Thinking outside the box. Only took $7million to do.
 
@IvenBach And that was turning them in.
 
4:54 PM
I can totally envision them walking into the lotto office with a couple garbage bags stuffed with winning tickets.
 
@mansellan this! It might take so long to find the winning ticket in that pile that they'd no longer honor it. Is there a time limit to claim your prize?
 
pretty sure that the tickets has to be claimed before the next drawing at most.
it wouldn't look so good if they can walk out with multi million dollars pot on a ticket bought 5 years ago
 
LOL.
 
Most of them go unclaimed for quite a while - it takes time to hire an attorney, set up a trust to accept the winnings, discuss the tax implications of the payout methods, etc., etc.
 
5:10 PM
I'm sure there's a lag but I'd still expect that you still have to submit the claim before the next drawing.
 
> Ticket expiration dates vary from 90 days to one year, depending on the selling jurisdiction. The expiration date is often listed on the back of your ticket. If the expiration date is not listed, check with your lottery. Unclaimed prizes are kept by the lottery jurisdiction.
 
180 days in UK
 
oh, interesting. #TIL.
 
It's all electronic, so they probably know how many winning tickets there are before the holders can check them.
 
Didn't think of that angle. You'd be right; they just have to see if anyone actually come in with that winning ticket.
 
5:16 PM
> Local news there was a winning lottery ticket for the umpteen billion dollars. But more importantly here's a cute cat video.
Distract them so they don't check the numbers.
 
^
 
How can I get the inspections window to be not off the top of my monitor?
 
get a bigger monitor?
 
...
 
You might have to delete the registry key for the layout.
I think there's an issue for that.
 
5:20 PM
can the move command be activated by keyboard
 
I don't think so.
 
@this probably, yea.
 
Yes pretty sure daFreeMan reported it originally. He also mentioned he managed to work around it but don't remember how he did it.
 
@IvenBach click it, press Alt, arrow down
 
@FreeMan How'd you fix it?
 
5:21 PM
or try to resize it
@IvenBach by forcing Windows to reposition it - resizing the window should to it
 
FML. Resize pushed top into viewable area. #IFeelSmrt
FYI Alt+ArrowDown didn't move it.
 
need to be Alt, Enter, then Arrow
Alt opens that weird control menu on left side; Move is the first command, and needs to be entered to activate it before you can use the arrow keys.
 
5:37 PM
> For `If` statements that are checking for strings, auto-closing quotes removes a space after the equal sign.

This:
```VBA
If TestString = "
```

Changes too:
```VBA
If TestString =""
```

VBA auto fixes it to the correct `= ""` so it isn't the biggest issue, but still mildly annoying.

Version 2.3.1.4308
OS: Microsoft Windows NT 6.1.7601 Service Pack 1, x64
Host Product: Microsoft Office 2016 x86
Host Version: 16.0.8431.2329
Host Executable: EXCEL.EXE
[rubberduck-vba/Rubberduck] Vogel612 is checking what fun stuff @Duga can say about project cards
> Tagging as a bug because this isn't the intended behavior, but given the caret is correctly positioned I'll treat this one as a lower priority issue; there's another SCP bug that's actually annoying and needs fixing - I'll try to slip a fix for both.
> Yes, this should be easy to update and a good first issue. Being a built in template, the source is stored in [this resource](https://github.com/rubberduck-vba/Rubberduck/blob/next/Rubberduck.Resources/Templates.resx). I am not certain if the annotation and the inspection needs any additional updates, however.

There is one more consideration not covered with the template. If you change the code in resource, how do you ensure that the file that was previously generated is updated? Though it
> Yes, this should be easy to update and a good first issue. Being a built in template, the source is stored in [this resource](https://github.com/rubberduck-vba/Rubberduck/blob/next/Rubberduck.Resources/Templates.resx). I am not certain if the annotation and the inspection needs any additional updates, however.

https://github.com/rubberduck-vba/Rubberduck/blob/7e17257abc1848e34c0d69fa9137eeb8aff79610/Rubberduck.Resources/Templates.resx#L123-L134

There is one more consideration not covere
 
@Duga yay codefile permalinks!
@TimidJavon @David_A_Flores @itsTimHell @WhatKeithSays He tried so hard 😂😂😂
^ thread start lol
 
5:55 PM
@MathieuGuindon Nice. Much better than a lame link.
 
> Yes, this should be easy to update and a good first issue. Being a built in template, the source is stored in [this resource](https://github.com/rubberduck-vba/Rubberduck/blob/next/Rubberduck.Resources/Templates.resx). I am not certain if the annotation and the inspection needs any additional updates, however.

https://github.com/rubberduck-vba/Rubberduck/blob/7e17257abc1848e34c0d69fa9137eeb8aff79610/Rubberduck.Resources/Templates.resx#L123-L134

There is one more consideration not covere
[rubberduck-vba/Rubberduck] Vogel612 did something with some project card
[rubberduck-vba/Rubberduck] Vogel612 is checking what fun stuff @Duga can say about project cards
[rubberduck-vba/Rubberduck] Vogel612 is bored so why not move a project card
 
poke @Inarion have you found out why the changes in your PR re ShadowedDeclarationInspection are not mirrored in the App.config?
 
[rubberduck-vba/Rubberduck] Vogel612 is bored so why not move a project card
[rubberduck-vba/Rubberduck] Vogel612 created project card
[rubberduck-vba/Rubberduck] Vogel612 is checking what fun stuff @Duga can say about project cards
[rubberduck-vba/Rubberduck] Vogel612 created project card
[rubberduck-vba/Rubberduck] Vogel612 is bored so why not move a project card
 
[rubberduck-vba/Rubberduck] Vogel612 project card. Enough said.
 
6:02 PM
Who needs a space heater? My computer is doing just fine at heating my office.
 
@Duga @Comintern did you ever figure out why VBE is funny about not listing all libraries? AFAICT, registrations are fine.
 
No clue. My guess is that it's just checking the flags in the registry.
 
> As realized in the comments in #4622, a simple versioning system may be needed for the built-in template in order to support the scenario where we need to update the built-in template's code in the resource. That also implies prompting the user whether to update the built-in template as they may have already made customization to the template and may not want to lose the changes.
 
@Duga uh-oh... I smell duck nuggets
 
@MathieuGuindon Definitely needs a better name than that...
 
@Comintern yeah, and they are 0
 
@MathieuGuindon IDK if I'd call it that. It's just a way to create a new component quickly.
Nuget packages aren't quite like that.
 
@IvenBach by doing what you did... :)
 
6:06 PM
More akin to VS' template, I'd say.
 
@this And we're registering both the 32 bit and 64 bit paths, right?
 
yes
(really need to cut down the extraneous registry entries, too...)
 
Default locale?
 
always 0.
since we aren't localizing our COM API.
and TBH I have no idea in hell how I'd.
(without generating a tlb for each locale and I will not do that)
 
Yeah, that would be silly.
FWIW, we could perma-pin them in the RD dialog.
 
6:08 PM
they say you can implement the localization within the DLL yourself but given that it's driven by attributes.... #BeatsMe
and besides that RD dialog will get rid of that.... funky selection of the VB's references dialog.
so it would be solving for all libraries, not just RD's.
 
I hadn't given it much thought really, in that it will soon be the VBE's problem, not ours.
 
That's what I'm seeing. I have no idea how I'd cajole VBE; and browsing to it does work.
If registration were off, then that wouldn't have worked.
 
You can load unregistered libraries.
 
Well, you can but it won't work.
since I think VBE will still go for the CLSID as soon as it processes a CreateObject or a New statement
and if it can't get that....
 
Depends on what you're doing with it. Does the VBE register libraries when it loads them?
 
6:12 PM
Given that I can generate a TLB from IDL without a backing DLL, and load it into VBE, nothing.
VBE's OB will even show what I have in my out-of-thin-air TLB
But I just can't actually run code against any objects from that TLB because there's no DLL for it.
 
Oh sure, but in our case we obviously have the dll.
 
so the loading of that library must be deferred until I actually new an object from that TLB.
there is one angle I didn't try, though - and it's whether you can call a LoadLibrary on a library that has no CLSID entries.
 
I would probably have to try them on load to see if they're broken.
 
My guts is that VBE won't care about that; it will always be looking for CLSID keys.
@Comintern Consider also that even if there's a DLL, it doesn't mean it's all A-OK; it might be out of date, corrupted, wrong bit, etc. etc. -- I think actually loading it via an object instantiation is the only way to be 100% sure.
 
> IMO versioning is overkill. If you added an earlier version of a template, it's in your project already; adding another instance will use the newer template, and that's fine. Why would a template change anyway? Adding annotations? They can be added later on, inspections can even find the missing ones, at least in the case of @PredeclaredId.
 
6:16 PM
Right, but that shouldn't stop the VBE from compiling. I think the only ones it loads at compile time are ActiveX objects in designers.
 
yet we don't have to reference them?
 
No, you do have to reference them. You just don't have to use the CLSID in the registration.
 
> Wait I missed the part about user customizations... how about we just list all the available files, and the filename deals with the version?
 
My understanding is that if the CLSID isn't found in the registry, the run-time calls LoadLibrary on the path.
 
@Comintern then complains it can't load the library IME
(semi-joking)
 
6:18 PM
Only if it can't extract the ITypeLib.
It will even use an associated exe - that's why I avoided calling LoadLibrary on host references.
 
> No, the issue is that when we first add a component, the subsystem will check the `%APPDATA%\Rubberduck\Templates` for a `rdt` file of that template. If it doesn't exist, it will create a new `rdt` file from the resource file.

So if we issue an updated version where we changed the template, the users who already generated the template `.rdt` file wouldn't get the changed template unless they delete that file in which case we will then regenerate from the resource file.

If we automatica
 
LoadLibrary("RandomExcel.xlsm") will open the thing in Excel.
 
Hmm. Interesting.
 
> No, the issue is that when we first add a component, the subsystem will check the `%APPDATA%\Rubberduck\Templates` for a `rdt` file of that template. If it doesn't exist, it will create a new `rdt` file from the resource file.

So if we issue an updated version where we changed the template, the users who already generated the template `.rdt` file wouldn't get the changed template unless they delete that file in which case we will then regenerate from the resource file.

If we automatica
 
It's because I was under the impression that VB* can't do reg-free com stuff
Have you ever seen any VB* project successfully working with a reg-free COM deployment?
Duh, I have. I do that all the time with vbDotNetLoader....
 
6:24 PM
@this actually, been hanging out on VBForums recently, COM SxS seems quite common over there...
 
OK, GTK.
 
> I'd say just list everything that's available; you want to use the file from 3 releases ago, go ahead. Perhaps include a readme.txt in the templates folder, suggesting a naming scheme: rd.template-name.rdt for the "built-ins" (gets overwritten), and user.template-name.rdt for customized ones.
> Ok, but there's 2 still more considerations:

1) in future, users would be able to create their own templates for where there is no corresponding built-in template. Labeling them as `user.template-name.rdt` seems a bit silly. We can use the convention of `template-name.rd.rdt`, and say that those will be always overwritten by RD which...
2) means the user needs a way of knowing there's a new version of the built-in template that won't be picked up because their customized template will be a
 
6:43 PM
> Why not just list all available templates, built-in or custom? We could even load the string and hover-preview it with syntax highlighting...
 
I feel like I'm missing something
 
Ok, let's make sure we're clear on the mechanics.
right now we have a submenu that will list all templates.
Currently it only lists one - the predeclared class
but eventually it'll list all templates, both built-in and users (ideally with a separator in between.)
 
@this Because it finds the .rdt or because it's in a .resx?
 
the former
 
6:46 PM
Note that in the case of the built-in template, it will also pull from resx for the menu item localization
the user-defined template will have no localization support.
but as long there's the .rdt file, it's the code in there that's used, not the one in the .resx file.
Now, I am not sure we want to list all versions of templates in the menu, do we?
there should be only one Predeclared Class Module entry in the menu, right?
 
One such built-in, yes
 
Just as an aside, I'd use a term like "Custom Template" instead of "User-Defined Template" to avoid future confusion when we start abbreviating it to UDT.
 
good point, Comintern
@MathieuGuindon ah, and I was thinking that if they customize the built-in template, they simply edit the rdt file for the Predeclared Class Module
and that menu entry will then use that file with their customization
but if you want to say that they should not customize those files but rather create their own file and call it My predeclared class module, which then appears as a 2nd menu item, we could do that.
Is that what you were envisioning?
 
I think that sounds reasonable - maybe with an option to "base template on..." when it's created?
 
one thing I don't particularly like about that is that it can lead to quite cluttered menu
right now we have only one template but when we have 10 template and they want to customize them all, that's 20 menu items already....
 
6:53 PM
Meh, that's a meat-space issue.
Maybe make "Custom" its own fly-out?
 
could but that's also ugly
 
@this yeah. You want custom, you copy it and tweak the copy, or PR a change of the built-in template
 
(my personal rule is that a menu should not be more than 1 submenu deep)
 
@this almost like we need some kinda dialog, a la VS... ducks
 
True - granted I haven't looked at the UI yet.
 
6:55 PM
j/k ;-)
 
heh. If the macro system does get implemented, a dialog may be actually necessary
but that's later later
 
would be great if we could have the menu collect the VB6 templates though
should be easyish
 
@Comintern the UI is basically just a submenu.
@mansellan in theory that is possible. In fact, that's how we are building the menu for the templates by scanning the templates directory.
 
When though? On right-click -> add?
 
yeah
 
6:56 PM
OK, that makes sense.
 
@this yeah would just need to pick up the configged VB6 template folder and scan that too
 
and the resource strings, too. I don't know where they use that.
 
I think it could be fairly simply implemented... the .rdt files that ship with RD 2.4 are the files they are; if RD 2.4.35 changes foo.rdt and user had the version we shipped with RD 2.4.27 and tweaked it, we have all rights to overwrite it when 2.4.35 is installed - but we should not delete any .rdt file that we're not shipping/installing
 
there are wizards as well as plain text files tho
 
@mansellan If we ever do themes, "Duck a la Orange" goes in with "Rubberdark".
3
 
6:58 PM
@MathieuGuindon I'm thinking that's better. Invoke the principle of YAGNI here and see how it flies for a bit.
If we get users clamoring about their lost customizations, we can deal with that then once we know there's value in the extra complexity.
 

« first day (1649 days earlier)      last day (188 days later) »