Jump to content

David Schwartz

Members
  • Content Count

    1264
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by David Schwartz

  1. David Schwartz

    How to gracefully get rid of the use of dictionaries?

    Code is supposed to reflect your design goals. I get nervous whenever someone tries explaining their design with code. I still don't know what you're trying to accomplish here other than change your code somehow. Are you familiar with Einstein's famous quote: "You cannot solve a problem at the same level of logic used to create it"? You showed us some code, assert there's a problem, then ask how to rewrite the code to solve this supposed problem without explaining a larger context. Several people made guesses based on assumptions they all had to make, but none of us really know for sure what the problem really is. I mean ... I do not understand why the dictionaries are there in the first place either.
  2. You are conflating "Is-A" and "Has-A" attributes. You're not talking about different kinds of humans. (Is-A) You're talking about Employees that all "Have-A" different Role. And each Role "Has-A" set of properties, like Responsibilities, Authorities, Permissions, etc. Each management level "Has-A" set of people who report to them. Also, just because you can look at something like an Org Chart that's hierarchical does not imply there's an "Is-A" relationship anywhere. Job roles are not inherited from the top-down! Nor even from the bottom-up. Each layer "Has-A" different set of properties, some of which may be delegated from time to time and for different durations, but they're certainly not all inherited for ever and ever. "Has-A" is called "composition" "Is-A" is called "inheritance". Since the larger context here is a "business", the base class identified as "human" is more of a distraction than anything else. Sure, everybody working in a business is a "human", but so what? Virtually every one of those people will, in reality, tell you that nobody at the company gives a crap about their life outside of the context of the business, which therefore excludes the vast majority of what their "human" attributes would include. If you dont have a much larger context in which all of those other attributes are being used, then it's "too abstract". No, the common attribute everybody at a company shares is better described as an "Employee". That might be a subclass of "human" but the vast majority of the human parts are irrelevant as far as the company is concerned. Just ask anybody who's not being paid a living wage or decent benefits! The company asks, "Why are these MY problem?" Technically, they're not. At least, not until you look at a much larger context of the role the company has in society, for example -- which is a question far too many people here in America prefer to ignore because they have been brainwashed into thinking that's "socialism" or even "communism". But that's what happens when your base class brings along too much baggage. It also leads to confusion. Try starting with "Employee" as your base class and see what happens. At that point, pretty much everything else can be expressed as collections of properties -- that is, "Has-A" attribute collections. Maybe there are some things where inheritance applies, but mostly you're talking about lots of mutually exclusive collections of rights, permissions, and authorities.
  3. David Schwartz

    Delphi LAMP- or WAMP-based Web Application

    Perhaps check out TMS WebCore ...
  4. David Schwartz

    Developer Express gave up on FMX

    I've never much cared for FMX as most of my work is Windows-based. I guess if you're working in mobile platforms, then FMX would make sense. But DevEx grids are so massive and there are so many tiny features that they just don't seem like something that would fit on a tiny screen unless you have tiny fingers and very sharp eyesight.
  5. David Schwartz

    50 Years of Pascal

    Libs, not DCUs. I don't know what they were called, or even when they were introduced since I never used TP. I jumped on-board when Turbo C++ was released.
  6. David Schwartz

    50 Years of Pascal

    a "timesharing calculator"! LOL!
  7. WebCore is really cool. I'm wanting to build an audio-based app using the Web Audio API. The pas2js guys processed the API with their magical tool and provided it as one of the free interface libs included with WebCore, but there's not a single bit of documentation and no examples. I've been trying to reproduce some of the many examples published for the API in JS, but either I'm not clear about how things are supposed to work (which is quite likely) or there's something about this library that's not working as intended (also very likely). Anyway, it would be great to find some other folks who are also interested in this API to help figure things out. I've asked them to adapt some existing JS examples, but Bruno says the guys are just too busy. Is anybody else here interested in audio?
  8. David Schwartz

    Refactor menu grayed out for Rename...

    I've noticed this quite a bit. Also, for some projects, the <ctrl>-Space does nothing, even though the project compiles and runs fine. Restarting the IDE doesn't help.
  9. At work, all of our computers and networks and everything need to be compliant with PCI, HIPPA, and a half-dozen other security protocols. So when we install software in Windows, we need to elevate to Admin. Most software has shows something that asks if we want to install for "this user" or "All Users". Delphi doesn't ask that, and seems to default to "this user" -- which if you're forced to install as Admin, means a lot of stuff is not accessible if you're NOT running as Admin. We are forbidden from running any sort of normal stuff as Admin! So I'm unable to install updates or new software in my laptop. Maybe there's a flag that lets you set this somewhere? I know a lot of Delphi is used in healthcare environments that are subject to HIPPA and other provisions, so I can't be the only person having to deal with this. (Note: I don't have this problem on my own machine; it's only an issue with my work computer.)
  10. David Schwartz

    50 Years of Pascal

    Originally, Intel built a custom chip for a calculator company who decided not to use it. So Intel made some small modifications and released it as the 4004. It got a lot of interest, but it only had a 4-bit data path. So not long after that, they released the 8008 with 8-bit data paths and registers. I was in 8th grade, I think, and saw something in Popular Electronics about this and wrote the company asking for more info. I got a reply from a guy in their Marketing Dept named William H. "Bill" Davidow. He sent me a rather large package of stuff, including a printout of the source code for their "monitor" software, the thing that evolved into the "boot ROM" code. When you get into most routers today, the UI is still nearly the same. 🙂 (People have asked me why I don't get "Cisco certified" as if it would open up lots of job opportunities for me. I ask, "Why? I spent many years writing and adapting that same ugly software for lots of different equipment! Those routers look exactly the same as what I worked with in the early 1980s.") Intel then released the 8080 and learned a very important lesson: The 8080 instruction set was different from the 8008, and so they naturally put out an assembler that was different. They charged an arm and a leg for their dev systems, and when people discovered they'd have to start all over rewriting their 8008 software to run on the 8080, including more dev systemss, they balked. So someone quickly rewrote the 8008 assembler to generate code for the 8080, and with minimal changes it could then be used to generate code for either one. This put the 8080 on the map. A guy named Charlie Bass left Intel and founded a company named Zilog, who then came out with the Z80 chip. It was the 8080 with a dozen or so additional instructions. But they had their own assembler with a different syntax, and nobody wanted to rewrite their code. Intel actually had the 8085 in the pipeline with almost the same bunch of additional instructions as the Z80, and they watched as the market refused to adopt the Z80's extended instructions. Shortly before its release, the afor-mentioned Bill Davidow -- who was now Intel's VP of Marketing -- decided the Z80 was not a threat, and when they released the 8085 it was only touted as being faster than the 8080 while consuming less power. And it had one additional instruction. However, the entire first generation of 8085 chips were all endowed with a full complement of extended instructions that were never officially documented. The next release did away with most of them. When the 8086 came out, they had learned their lesson, and the assembler would accept all of the source code written for the 8008, 8080, and 8085 chips, with additional features added for the new 8086 instructions. Intel realized that to ensure you got your existing customers to adopt your newer technology, you had to make it as frictionless as possible to "upgrade". That ultimately extended to hardware as well. When they introduced the 80386, they published "reference designs" of the motherboards. But so many companies didn't want to go to the hassle of building their own that Intel eventually started outsourcing their reference designs to HW manufacturers. When the 80486 went into general release, they had a list of sources with motherboards IN-STOCK that their customers could buy to start working with right away. I suspect it has a lot to do with why the latest Delphi compiler will STILL compile Delphi 1 code (and even TurboPascal code with minimal changes). Sad to say, there are still companies that haven't figured this out!
  11. David Schwartz

    Install flag to say it's for ALL USERS?

    I honestly cannot answer any further questions. I just don't know enough about how Windows security works today, or what these brainiacs have in mind with their restrictions and how we're supposed to work. (I guess their viewpoint is like this: When your only tool is a way to impose security restrictions, the whole world looks like a threat that needs to be kept at bay.) I started out with DOS and then Windows 3.1, then I learned Unix Sys V and those U / G / W permissions made sense. And there are the UID and GID bits that you can set to "run as..." the file's UID / GID if needed. But when MS introduced Win NT and the Secured Registry, I never bothered to dig into all of its subtleties. I'm a developer, not a Sys Admin, so as long as I can get my work done, I don't care. When security issues arise, I let the Sys Admins deal with them. At this job, we cannot run regedit. We cannot execute .reg files from the command line (I guess they use regedit). They have provided us with a batch file we can use to peek and poke individual registry entries in part of the Registry, but not subtrees. Most people have one main login and there's something where they can ask for Admin access for 15 minutes, and they have to explain why. When you get approval, you click on something and it does a kind of "switch user" thing. When the 15 minutes is up, it switches back. If you're in the middle of something, it gets all borked-up as the ACLs change mid-stream. Us Devs were issued a separate Admin login so we don't need to ask permission. But it's just a different login that has Admin rights -- otherwise it's unrelated to our normal login. I was told this policy was established so if someone got our normal user login credentials, they wouldn't have any ability to elevate to Admin status from that userid at all. Using my Admin login to install software, it used to work ok in that I could run the apps as my normal userid. But something was changed in the past 6 months so the files it installs and stuff it puts in the Registry can only be accessed (ie, read, not just written) by users who are members of the Admin group -- meaning my normal userid can't even see them. I was able to install Delphi 10.4.2 under my Admin login, but it won't even launch now under my normal userid. It works fine under my Admin login, however, but we're not supposed to use the Admin login for normal work. I had to copy some DLLs into Delphi's bin folder; I switched to my Admin login, copied the files, then switched back. My normal user couldn't see or access the files I just put into the bin folder. I had to have the Sys Admin intervene.
  12. David Schwartz

    Install flag to say it's for ALL USERS?

    I really don't know the depths of the security policies involved, but remove your main user from the Admin group, and create a separate admin login (not Administrator, but a separate user that's in the Admin group) that you use in a way that the two accounts are not coupled in any way. Then lock up your Registry so that only members of the Admin group can access it. If you're really that curious, read up on HIPPA and PCI compliance, then find any others that impose restrictions on what you can access and factor them in. Set things up so you have to login through a VPN and tunnel through a secondary firewall, and change passwords every 6 weeks. In other words, pretend you want to manage medical bills and collections, and also collect credit card and check payments on your own servers. Where people can get access to their medical records that were submitted with the bills. Is your brain hurting yet?
  13. David Schwartz

    Install flag to say it's for ALL USERS?

    This is a problem on my WORK MACHINE! I'm not screwing-up my personal machine trying to figure out a work-related problem! If I had much interest in IT Administration, then maybe. But I just want to get stuff done without having to deal with walls designed to keep intruders out that in the end keep us from do what we were hired to do. It's above my pay-grade. About 10 years ago I had a contract at a bank where every Friday at noon the Corp IT Dept shoved down a bunch of Windows updates, and part of that ended up revoking all of the Admin rights on all of the Dev computers. We'd back stuff up in the morning then there was a Dev meeting at 11AM for an hour, and everyone would leave for lunch. When we got back, we'd spend the rest of the afternoon getting our machines back to a working state, assuming the IT folks gave us back Admin rights before they quit for the day. Where I'm at now, we don't GET Admin rights. Period! We can't even access the damn Registry! Because even though we're behind two VPNs and several firewalls and have most of the CPU bandwidth on our laptops allocated to background security stuff, they fundamentally don't think they can trust anybody except the Managers. As if no company ever had problems with their managers... (Actually, I was told it's mostly because one of the Sr. Mgrs insists on the ability to connect to any computer in the company at any time, including production machines. Which makes everybody's computer potentially an attack vector.) Like I said, it's above my pay grade. I'm just trying to see if anybody here may have had to deal with this crap.
  14. David Schwartz

    Install flag to say it's for ALL USERS?

    We have VMs provided to us by IT, and they must also conform to all strict security policies. That is, we cannot use a VM to escape these silly policies. This is on my company laptop. The VMs are on our intranet, and they're slower to use. It's not fun.
  15. David Schwartz

    VirtualBox - no audio

    I've been running VirtualBox on my Mac with Win10 and Delphi installed in it to do my Delphi work. So far, I haven't needed any audio. But I need to do something with audio, and am having trouble with getting it to work. I can play some videos on, say, YouTube, but a Delphi app that makes sound via TMS WebCore is silent. When I save it to a web server it works. I installed XAMPP on my Mac host and now I can open the file at localhost and it works. But running it inside of VirtualBox --> no sound. Actually, it works for a bit right after a reboot of the VM, but then it stops after a time -- I haven't determined what blocks it. It's not a huge problem, but it would be nice to consistently get audio out of the VM when I want it. Has anybody run into this and know how to solve it? I did some searching around and found stuff that says to change some driver in VirtualBox. But all I get is immutable combos with no way to change anything the way the articles explain. So I'm not sure what's going on there.
  16. David Schwartz

    VirtualBox - no audio

    Yes, I did find lots of reports and suggestions about this, but nothing that worked for me. I was hoping someone here might have found a solution. Thanks, tho.
  17. David Schwartz

    How to install a design-time package

    Also, FWIW, the IDE only accepts 32-bit Design-Time packages AFAIK. It's not a 64-bit app.
  18. David Schwartz

    VirtualBox - no audio

    On my system, the drop-downs (comboboxes) in the first set of images are all read-only and have no options. I can't change them. Not sure why. And yes, I do have the Extension Pack installed.
  19. David Schwartz

    Install flag to say it's for ALL USERS?

    Have you actually dealt with this problem? Anybody here who has?
  20. David Schwartz

    Install flag to say it's for ALL USERS?

    Yes, the OPTIONS button was pointed out to me. I tried it, and sadly it didn't solve the problem. Is there a video on using the PowerShell as suggested? I don't know anything about it.
  21. David Schwartz

    swagger help needed

    Any update on this? I can really use it right now. BTW, I'm still rather astonished nobody has published anything that does this for Delphi -- unless someone did but it's being kept a secret. There are at least a half-dozen for C# and one or more for nearly every language imaginable ... except Delphi. What do people using Delphi do to connect with REST servers that have Swagger specs available? Write their REST interfaces all by hand???
  22. David Schwartz

    Edge Webview update (?)

    The announcement page says this Delphi update includes the latest release of the Edge Webview component. ok ... so ... why is it also listed in GetIt ?
  23. David Schwartz

    Edge Webview update (?)

    But it's part of the base install now, according to their website. And it wasn't updated in GetIt previously even though it had been updated by MS.
  24. Just installed 10.4.2 and it does a full un-install and re-install of everything. The Good News is ... it reinstalls all of your existing libraries (eg., TMS stuff in my case) and preserves the IDE layout and settings. The Bad News is ... it removes all of the GetIt packages and ... forgets to re-install them (?). What's the difference between TMS libs and GetIt libs that it thinks requires it to remove all of the GetIt libs but not the other ones? If this is intentional, the least it could do is leave a list of what you had installed previously so you can re-install them all instead of having to guess.
  25. I didn't recall how I installed 10.4.1, so I went with the web installer. Their info says it's a "headless install" but it shows some command windows that require you to hit the Enter key a few times to continue. Other than that, it went pretty smoothly. It clearly removes the GetIt components, but stops before re-installing them.
×