

JohnLM
Members-
Content Count
350 -
Joined
-
Last visited
Everything posted by JohnLM
-
@ Alexander S - Thanks for your reply. I will look into your second suggestion. ** The TControlList ** I checked out the TControlList and found a video by Alister and he gave a brief tutorial using a TClientDataset. I copied to code snippet from the screen in the video and tried and it worked. It was a nice output. I just need to play around with it to get a better feel for my needs and what I may use it for in the future. So thanks, Alister.
-
Dellphi 12: IDE's F6 Search box still faulty
JohnLM replied to PeterPanettone's topic in Delphi IDE and APIs
I use these little-known keyboard secrets... On my laptop, I use shift+insert On my bluetooth keyboard, since I don't have the [insert] key, I use CTRL+Shift+V Both methods work for me in XE7, 11.2 and on my laptop with windows 7 And on my Chuwi Hi10X win10 tablet, these methods work in 11.2 and 12.0 using a bluetooth keyboard with Ctrl+Shift+V -
update.. I've also compiled the test app in Delphi 11 and 12 on my Chuwi Hi10X tablet. 11.2 works fine, but 12.0 hit or miss. Sometimes the machine locks up, other times the window (the memo) is blank. Makes no sense to me, but I'm late for work and will have to figure it out later.
-
Specs: win10, delphi 12, VCL app design I am searching for the best or optimum way of pulling all filenames (and folder names) from my current tablet. The hdd is an SSD. In the past, I used to use a dos command and run dir c:\*.* /A x y z >h:\cdrive.txt and save that as a text file to archive. But its been a long time since I've performed this and can't remember the exact parameters I used to use. That was windows XP and early windows 7 desktop pc. Now I want to do the same in a dos window, but I see the command seems to have changed and/or new ones added since. This is windows 10 now. I would use Delphi command instead but I'm not savy in that area. So I want to continue doing it the dos way if possible, or I would like to try both methods: dos and delphi. The reason I've used the dos method is because it is the fastest. There was a command to turn off screen updates and it would fly, 1, 2, 3 and it was done. TIA
-
I have updated the source code to include the time info (in the sec 4 portions of the source code, in the previous post above). Here is a demo of the final output: 1/27/2016 12:11:27 AM | Project2.cfg | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Project2.dof | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Project2.dpr | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Project2.exe | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Project2.res | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Unit1.dcu | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Unit1.ddp | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Unit1.dfm | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:27 AM | Unit1.pas | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:28 AM | Unit1.~ddp | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:28 AM | Unit1.~dfm | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:28 AM | Unit1.~pas | I:\delphi\d7\Activity List\ver01 1/27/2016 12:11:32 AM | Project1.dof | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:32 AM | Project1.dpr | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:32 AM | hdd.s.exe | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:33 AM | Project1.res | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:33 AM | Unit1.dcu | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:33 AM | Unit1.dfm | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:33 AM | Unit1.pas | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:33 AM | Unit1.~dfm | I:\delphi\d7\hdd serial\v01 1/27/2016 12:11:33 AM | Unit1.~pas | I:\delphi\d7\hdd serial\v01 7/10/2016 11:10:03 PM | Unit2.fmx.~1~ | I:\delphi\xe7\FMX\fishfacts\v01\__history 7/10/2016 11:10:03 PM | Unit2.vlb | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:10:08 PM | Project1.dpr | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:10:08 PM | Project1.dproj | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:10:24 PM | Unit2.dcu | I:\delphi\xe7\FMX\fishfacts\v01\Win32\Debug 7/10/2016 11:10:24 PM | Project1.exe | I:\delphi\xe7\FMX\fishfacts\v01\Win32\Debug 7/10/2016 11:10:23 PM | Project1.res | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:10:03 PM | Unit2.pas | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:10:03 PM | Unit2.fmx | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:10:08 PM | Project1.dproj.local | I:\delphi\xe7\FMX\fishfacts\v01 7/10/2016 11:17:48 PM | Project1.identcache | I:\delphi\xe7\FMX\fishfacts\v01 9/16/2017 11:15:18 PM | readme_KEEP.txt | I:\delphi\xe7\FMX\fishfacts\v01 11/13/2016 1:00:08 PM | data_Notes20161113sun1259pm.zi | I:\delphi\misc 1/13/2019 1:47:50 PM | data_Notes20190113sun0139pm.zi | I:\delphi\misc
-
I now have the date included. Again, this is not efficient, and with every new piece I add to the code, it gets slower, but still works. Below is the updated source code with added functions. Next, I will add the filename timestamp... uses strutils; // sec 1 function GetFileCDateTime(FileName: String): TDateTime; begin GetFileCDateTime := 0; If (FileName <> '') and (FileExists(FileName) = True) then begin GetFileCDateTime := TFile.GetCreationTime(FileName); end; end; // sec 2 function padspaceRT(S: string; Len: Integer): string; begin // this is my custom-made string padder, it insers spaces to a given length - its prob the slowest part and can be enhanced i'm sure. s := midstr(s,1,len); result := S; // give it a value right away. while Length(Result) < Len do Result := Result + ' '; end; // sec 3 function padspaceLF(S: string; Len: Integer): string; begin result := S; // give it a value right away. while Length(Result) < Len do Result := ' ' + Result; end; // sec 4 procedure tform1.findfiles(list: tstrings); begin list.Clear; var sw := TStopwatch.StartNew; var fname, fdate, ftime: string; var FileARR := TDirectory.GetFiles(eb1.text, '*', TSearchOption.soAllDirectories); var DateARR := tdirectory.GetCreationTime(eb1.Text); for fname in fileARR do begin fdate := datetostr(getfilecdatetime(fname)); ftime := timetostr(getfilecdatetime(fname)); list.Add(padspaceLF(fdate,12) + ' ' + padspaceLF(ftime,12) + ' | ' + padspaceRT(tpath.GetFileName(fname),30) +' | ' + TPath.GetDirectoryName(fname)); end; st1.Caption := Format('%d Files, %d ms, (%f s) ', [Length(FileARR), sw.ElapsedMilliseconds, sw.ElapsedMilliseconds / 1000]); end; // sec 5 procedure TForm1.btnPullClick(Sender: TObject); begin m1.Lines.Clear; // tmemo m1.Lines.BeginUpdate; // for speed but prob not necessary try findfiles(m1.Lines); except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; m1.Lines.EndUpdate; end;
-
After some mods and additions to the code I managed to get the filenames and folder names to display. The only problem I am having is with getting the date, mod date, and time. I believe it is TDirectory.GetCreationDate() My updated code snippet, below. I'm sure it can be enhanced better and/or less, but it works. uses strutils; function padspaceRT(S: string; Len: Integer): string; begin // this is my custom-made string padder, it insers spaces to a given length - its prob the slowest part and can be enhanced i'm sure. s := midstr(s,1,len); result := S; // give it a value right away. while Length(Result) < Len do Result := Result + ' '; end; procedure tform1.findfiles(list: tstrings); begin list.Clear; var sw := TStopwatch.StartNew; var fname: string; var FileARR := TDirectory.GetFiles(eb1.text, '*', TSearchOption.soAllDirectories); var DateARR := tdirectory.GetCreationTime(eb1.Text); for fname in fileARR do begin list.Add(padspaceRT(tpath.GetFileName(fname),30) +' -- ' + TPath.GetDirectoryName(fname)); end; list.add(Format('%d Files, %d ms', [Length(FileARR), sw.ElapsedMilliseconds])); end; procedure TForm1.btnPullClick(Sender: TObject); begin m1.Lines.Clear; // tmemo m1.Lines.BeginUpdate; // for speed but prob not necessary try findfiles(m1.Lines); except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; m1.Lines.EndUpdate; end;
-
I will attempt to add Uwe's code snippet along with the other snippets I found and tried, into the VCL app I was working on...
-
I ran the code again, 11.x seconds both stopwatches. By this time it was reading cached memory, but accurate.
-
Uwe's code snippet (above), On my win7 laptop (sandybridge i3-2370M 2.40GHz cpu), first run, it was 681,960 files, 418185ms (6969.75 secs) but my cellphone stopwatch said +/- 7m:30s
-
I've been at this since I first wrote this topic, but I did not receive a notification of a reply. Anyway. I've found the params that I used to use and tried them. They work okay, but rethinking this project idea I decided to go the delphi route and I've been searching around for old code that I once tried before and had it working then but I can't find it. It was a project I started about 7 years ago and lost code snippet I was working on. All I have is the incomplete app. Now I am re-researching old and new code snippets via google and found several so far. But I've had mixed results with them. I want to include the recursive portion. That was the hardest part for me to understand back then, and now I want to try and figure it out again and get working. In one of the example recursive snippet I found via google, I entered c:\windows as the search path to recursive folder lookup and it took over 15 minutes to complete and give me 126,504 files. I will do further searches for more efficient code snippets in this area. Next time I will test on a smaller set of recursive folders.
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM posted a topic in Delphi IDE and APIs
Hi, I just realized that I am installing the wrong Delphi version on a new tablet. Embarcadero was quick to supply me a registration bump (from 2 to 3) and I was able to begin the installation of Delphi 12.., or so I thought. However, I grabbed the wrong .iso file folder "RADStudio_11_2_10937a" and began installing it. It should have been the "RADStudio_12_0_4915718.iso" file. Being so used to the Rad Studio 11 logo, I over looked it--twice! I am currently at the "specify location" dialog. Is it too late for me to stop and cancel the install and restart but with the "RADStudio_12_0_4915718.iso" file?- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
Success !! I now have both Delphi 11 and 12 installed on my new Windows 10 tablet. Both are up and running without conflicts or issues. Tablet Specs: Chuwi Hi10 X 10.1 in, 128GB SSD 6GB RAM Windows 10, 1920x1200, Intel Celeron N4120 (Gemini Lak) 4-core cpu. Known issues: *1 BSOD - Stop Code: MEMORY MANAGEMENT *2 BSOD - IRQL NOT LESS OR EQUAL (blue screen of death) I've mainly only been getting issues showing *2- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
update.. re: registration At the first, it showed me, "Existing License found" message Then I select the (o) Use existing license option, and so far the installation is going smoothly. And I see a Delphi 12 shortcut icon on my desktop under Delphi 11 shortcut.- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
update.. I decided to image this setup in case I run into problems I can restore back to that condition. Now, I will attempt to install 12.- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
I must admit, this was the fastest install of Delphi 11.2 Alexandria and without any glitches--even mobile (android components) installed, as far as I can tell. It just works!- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
update.. It's too late, LoL. It did install. I just launched Rad Studio 11 and is up and running.- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
But the Rad Studio 11 dialog was still up and it had a blue [Get Started] button, or something Started. When I click it to test it, the Embarcardero registration dialog popped up asking for a serial, etc., and there is a Delphi 11 shortcut on my destkop.- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
Okay, I cancelled it. The install said: Install was successfully canceled.- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
Installing the wrong Delphi version on new tablet - RESOLVED
JohnLM replied to JohnLM's topic in Delphi IDE and APIs
Okay. It was at the installing features dialog box. at 5% for the 15 minutes probably. its so slow. I don't know what it is doing. This delphi 11 install for windows 10 that I started has a set of different install dialogs versus the one I installed for a win10 laptop back in Nov/2022. It is currently at the 'Acquiring Debugging Tools for Windows.." 5% progress. I will cancel this. It is taking too long and I have to get ready for work in an hour, as I work the night shift. I will try to install the 12 now while I get ready for work. The worst that can happen is that it fails the registration. I will have a hard time getting another bump for it this time.- 9 replies
-
- delphi
- installing
-
(and 2 more)
Tagged with:
-
For me, getting 12 installed has become frustrating. I just learned my registration limit has been reached. I now know that the limit is two. But what I wanted to mention is that the link(s) in the installations 'product registration' dialogbox (located at the bottom left corner) do not work. Actually, all the links in that dialog box do not work. When it opens my browser, I get "Hmmm... can't reach this page. Make sure you've got the right web address: http://www.embarcadero.com" and make a suggestion that I search Bing! Now, I will have to wait until next Monday to bump my registration because my rep(s) never answer email after 5 or 6pm. And when they do, its another 24 hours of waiting. Since my subscription runs out today, 11/10/2023, I will not be able to install 12 after all. Oh well.
-
When I do installations of new software, I always image my current hard drive with Reflect Macrium Reflect Disk Imaging and Backup software. If I have a new pc or latop/tablet, I do the following: 1. download the latest Macrium 2. get the new device up and running and make any special settings like * (like extra large mouse, set keyboard to fast typing, etc.) 3. then I perform an initial image of it as it is. 4. then I will install any special or new software, like Delphi 12 for instance. Once I have 12 installed, then I do another Macrium image of this new setup (hoping that the installation of all the necessary components all work, like mobile compiling to Android, etc). And, assuming that all that went well, I then run some compiling tests, specifically for Android. If that goes well, I'm done and have my master image. But if not, then I work out what the issue(s) are, fix them, and do a final Macrium image, test again, and done. Thus, this becomes my new master image for developing on this pc/laptop/tablet. Should I have any future problems, I can alway refer back to the main image and start over from that point. I will be doing this process shortly, for Delphi 12.
-
re: the webinar I wouldn't mind a Youtube video link once it's over.
-
@ Mike - I just came across this topic and thought I give you a thanks for the info. But.., I wish I could test some of the suggestions, including yours, but I can't since I lost my beep function when I disabled one of the windows services some time ago. I was trying to stop my HDD from being accessed so much. In that quest, I mistakenly removed the beep in windows (using win7) when I removed a service and I can not figure out how to restore that portion of the service to restore my windows beep. The only time I can hear the beep is when I click on the volume bar. I use the beep a lot in my apps. I sometimes call it with beep(x,y) (if I move the winapi.windows as the last uses position. If you or anyone knows of which windows service is responsible for the windows beep, please tell me so that I can go in an re-enable it. TIA
-
re: finding a bug report list Okay, I stand corrected. I found a link (for 'bug report') below, but it does not cover all versions, not that I need every single one. https://docwiki.embarcadero.com/RADStudio/Athens/e/index.php?search=bug+report&title=Special%3ASearch&go=Go