What messages TEdit in delphi needs to answer in order for Windows Text Suggestions to work - delphi-10.4-sydney

When you create an new VCL form with one and put one TEdit and one TComboBox in it windows text suggestions works only with TComboBox. I guess this is because the Edit part of the combobox is a windows edit. I cannot seem to find anywhere how to make the VCL's edit behave the same way. Is there some IME messages I need to handle in a certain way or anything else?

What you ask is usually named autocomepletion.
TEdit doesn't support this out of the box (Not that I am aware of).
But there are several solutions floating around on the internet.
Not a direct solution, but have look at the answers to this question and also this one.
There is source code available for several solutions, you'll find it with this search on Google.

Related

Is there a way to prevent MS docx document editing in OpenOffice?

I know this is too strange question, but we have multiple authors of one document and some contributors use OpenOffice to edit document, originating and edited by majority in MS word. Document is quite complex with differently structured paragraphs and fonts, bullets, numbering, embedded pictures, references to comments under the line, copied/pasted sections pasted with source formatting instead of pure text etc., so generally "fragile" and maybe little bit exceeding expectations of OpenOffice authors for MS compatibility. Bottom line is about various formatting issues, glue-ing of some words (occasionally space is missing), page footer/header modified or completely disappeared etc. We are unable to control behaviour of contributors and editors to the extent I would like to have, so I am trying to findout whether is there a way how to force users to use exclusively MS word for particular docx and to prevent using anything else? (I am not on MS payroll, I personally moved couple of people around me with "standard" document writing needs to OpenOffice, but incompatibility in this case creates useless redaction work for us.)
Thanks for any hint.
whether is there a way how to force users to use exclusively MS word for particular docx and to prevent using anything else
To me, it sounds like a terrible idea to try to enforce this with a macro or similar (and it probably wouldn't work even if you tried). Instead, come up with a better workflow and communicate with anyone who may be involved so they know what to do.
First question, is the document under configuration control? For example, if a bad change is made, do you have a way of going back to a previous version? There are many different configuration management tools available, both free and commercial.
Next, I would strongly recommend making final changes with only one Office suite. Pick either LibreOffice (or Apache OpenOffice - is that what you mean by OpenOffice? The OpenOffice.org suite was forked several years ago) or MS Word to be the official editing tool, but not both.
If you pick MS Word, then people can still make preliminary changes to the document using LibreOffice. However, someone with MS Word will then need to use a Diff tool to see the changes and then use MS Word to incorporate those changes into the document. Or ideally, Track Changes would be turned on to make it easier to see what changes were made and who made them. Comments can also be added to explain why changes were made.
What is even better is to get people to send marked-up PDF files that contain their proposed changes. PDF files cannot be edited, which is good because it avoids the kinds of problems that led you to write this question, and also the formatting changes they made will not appear differently on another computer. However, this requires a certain amount of education so that everyone agrees to do it this way, and in my experience, that's not easy with a diverse group.
If you ever see that someone has made changes to the main document using LibreOffice, you or someone else needs to go back to the latest version not edited by LibreOffice and then use MS Word to incorporate all of the new changes.
At this point, if both suites have been used to edit the document, then I would probably start off with a new blank document and copy all of the text unformatted into it. This would require redoing all tables and other formatting. Otherwise, it's likely to be nearly impossible to get a clean document, and the underlying formatting may have no end to the number of problems that keep popping up.

VSCode extension for panel

I am new to VSCode and was wondering if it is possible to create additional tabs in the panel (With an Extension or just with VSCode). For example an interaktive Python window like in VS2019.
I haven't found anything on this topic, whether it is possible or not, so maybe you know if it is possible ( or planned for the future).
It is the same question that #Gama11 linked, but unfortunately it has not been answered so I can't mark it as duplicated. Right now it is not possible, but the January 2020 changes shows the experimental "Moving views from the Sidebar to the Panel". Even though This is only a preview of the features and many aspects of it are likely to change including the limitations mentioned above. it still gives me hope that this might be possible at some point.

VBA hide form from menu

I'm trying to hide a form from the menu using VBA; I've Googled this, but everything is giving me the .visible option, however I want to hide it from the groups menu located on the left side. I could just as easily manually do this, however it's very tedious and I can't be going on other user's computers to do so.
Is this possible?
I might suggest normally you should only disable menus vs. removing them all together, might suggest doing an enable/disable menu item instead..
It should be possible but how much work is it and is it worth it to you? It isn't clear what your host application is just that you're using VBA. Might suggest the host application may already allow for customization if so use what it provides.
If the app doesn't allow customizing your menu you can still do it, just how much work is it worth for you? You'll need to look at the Win32 way of doing things. If not familiar with Win32 and menus take a look and start here looking here at MSDN to start learning about menus in Windows. After this you'll find Pinvoke will be handle to give you C#/VB sample to call what is needed. The VB should be useful but you will probably need to further translate the VB to VBA for your needs. FYI when starting out a a C/C++ developer back in the day 30 years ago it was anticipated anyone getting into windows might take them a few months, there is a lot you'll need to get up to speed on. Thus is this feature really worth it?

Wordpress search also shows

I'm trying Agolia to see if it is something for our websites. So I did a little test on one of our websites (click here, it works but you also get the original dropdown. Does anyone know how to prevent this?
The theme you are using does come shipped with a built-in autocomplete experience.
You should disable that one.
An easy fix for you would be to comment all the code in this file https://eezo.nl/wp-content/themes/yoo_venice_wp/warp/vendor/uikit/js/components/search.js

How to highlight the differences between two versions of a text in .NET web app?

I have been supporting a web application at work for our Call Center unit for about 2 years now. The app is written in ASP.NET 3.5 with SQL server 2005 database. I’ve been asked to expand the call detail section to allow agents to edit the current call note with the ability to revert back to its previous version. Now, that’s all cool but now the manager wants to be able to click on any particular note and see all edits with changes highlighted in yellow (and if something was deleted, he wants to SEE the deleted text crossed out). Actually, what I need is very similar to how Stackoverflow handles edits on their questions. I’ve been thinking about how to go about this and after doing research and Google-ing of course, I am still unsure which route to take. I am fairly new to .NET development. Any ideas on the best technique for highlighting the changes in UI? I am afraid I am going to have to store a copy of the entire note each time they make a change because the manager wants to be able to easily review notes and revert back to ANY version (not just the most recent one) before sending the monthly call report off to our VIP customers. Since this department OFTEN changes their mind on things, I want to make sure the new functionality is scalable and easy to maintain. Any ideas would be greatly appreciated. I am really just looking for someone to point me in the right direction; maybe there are some tools out there that can be useful, recommended keywords in Google lookup, etc.
This will be difficult do to.
You'll need a "text editor" control that can not only edit the text, but which can also tell you what changes were made.
You then need to store not only the final text string, but also the list of changes
You'll then need to be able to display the text plus changes, using strike-outs, and different colors for inserts vs. changes
You'll need to do this not only for the changes of a single user, but you'll need to store each users' changes in the database, and will need to be able to display all the changes, all at once.
Your manager should be really sure he needs this.
Some tools for doing the diff for you can be found at Any decent text diff/merge engine for .NET?.
This would entail storing every version like you say. This should allow you to implement it similarly to SO. I seem to recall reading or hearing Jeff mention it, but wasn't able to find it, likely in one of the SO podcasts.
Easiest would be to store the text for each revision, then when the user wants to see the diff use a diff tool to generate the highlighted text.
Here is some Javascript diff code:
http://ejohn.org/projects/javascript-diff-algorithm/
If all the computers have Word installed you may be able to use a Word control to accomplish this. TortoiseSVN has scripts in its program directory which can take two word documents and produce a document with changes highlighted. To see this create c:\aaa.doc and bbb.doc, then install TortoiseSVN and run:
wscript.exe "C:\program files\tortoisesvn\Diff-Scripts\diff-doc.js" c:\aaa.doc c:\bbb.doc //E:javascript
I think you should see http://en.wikipedia.org/wiki/Revision_control