-
Content Count
1406 -
Joined
-
Last visited
-
Days Won
22
Everything posted by programmerdelphi2k
-
you can use "https://docwiki.embarcadero.com/RADStudio/Sydney/en/Querying_Metadata_(FireDAC)" functions to create yourself if necessary! try some like this: using: FDConn + FDPhysXXX + FDWaitxxxxx + FDMetaInfoQuery to scan your database -- FDScript to execute yourself script!!! procedure TForm1.Button1Click(Sender: TObject); begin FDConnection1.Open; FDMetaInfoQuery1.MetaInfoKind := mkResultSetFields; // any other kind existent FDMetaInfoQuery1.Open; end;
-
Multiple Simultaneous Connections with TidFTP
programmerdelphi2k replied to Brian Warner's topic in Network, Cloud and Web
each FTP session, needs: user, password, a file to upload; then, you need use a way to send this data, like using a "thread", or in your case "n" threads. Each one for a FTP send! then, each thread will be independent and autonomous each others! needs controls like all works, mainly when any exception occurs! -
Delphi 11 uses designide270.bpl instead of designide280.bpl and won't let me replace it!
programmerdelphi2k replied to Al T's topic in Delphi IDE and APIs
if you dont have RAD 11 installed, YES! if "this" is any residual from old-Uninstall, then, just delete it! -
Delphi RAD 10.4 IDE: How do I make the shapes appear smaller.
programmerdelphi2k replied to Kurt G's topic in FMX
try this: just drag your "mini-windows" (tools) by title and drop it in your screen, or same, close it. now,you can use all "ClientAREA" from your IDE! note: left margin will be always = "0" -
TcustomComPort.Write(void type, integer) first parameter
programmerdelphi2k replied to Miro Hlozka's topic in Algorithms, Data Structures and Class Design
var // MyVar:string; // or MyVar:array of byte; begin SetLength( MyVar, 100) ; // if byte // READ( myVar[0], 100); // first var pos // READ( myVar, 100); // pointer pos try this gihub https://github.com/CWBudde/ComPort-Library https://github.com/CWBudde/ComPort-Library/blob/master/Source/CPort.pas = TCustomComPort SAMPLES: https://github.com/CWBudde/ComPort-Library/tree/master/Examples/ComExample -
Possible changes to string/char handling in Delphi 11(.2)?
programmerdelphi2k replied to omnibrain's topic in General Help
no bad-WORds here ass = AnsiStringS -
Clean cache memory after generete fast report
programmerdelphi2k replied to Zazhir's topic in RTL and Delphi Object Pascal
of course, there are many object on memory in this moment! (many FastReports object or any other that you use) my tip: try start with max 100 on loop... use the MS TaskManager to see the memory consume go on until your "2000" to see the chaos! look, while you dont "re-factor" your code, this situation always will be your rotine! keep in mind that if you put all the tasks inside the Query.EOF "loop"... you will be replaying all the same occurrences until you reach the last record in the query! So if you access 100 objects in the life of your loop, then you will have 100x the memory used by the first one, plus the amount of memory used by FastReport to generate the PDFs on disk, etc... -
Possible changes to string/char handling in Delphi 11(.2)?
programmerdelphi2k replied to omnibrain's topic in General Help
about translitation: AnsiString = char(1120) ... HELP (my fault dont read all content... // When a literal is assigned to an AnsiString, the compiler will convert that literal to Unicode using the code page of the // AnsiString and then convert that back to literal. This ensures that the AnsiString contains characters valid for its codepage. // If an invalid character is specified, it will be converted to byte "$3F" (question mark) to signal that an invalid byte sequence(s) // was encountered. var ass: AnsiString; begin ass := 'back-door'; <=> ass := AnsiString( Unicode( AnsiString( 'back-door', code-page) ) ) = if same codeS then ass = 'back-door', else = '?' -
ok! if I know some I let you know!
-
Clean cache memory after generete fast report
programmerdelphi2k replied to Zazhir's topic in RTL and Delphi Object Pascal
reflection: Imagine multiplying 500x all objects generated in just one report, and you'll have an idea of how much memory your app needs to run! Note: it doesn't matter if your computer has a lot more memory than that! Your app will only use a limited amount of memory to keep track of the objects it creates or uses! -
Clean cache memory after generete fast report
programmerdelphi2k replied to Zazhir's topic in RTL and Delphi Object Pascal
just for my curiosity: --- your original code , works in real world? (of course... no talking about your out-of-memory) -
https://blogs.embarcadero.com/this-google-api-easily-adds-powerful-speech-recognition-to-apps/ https://github.com/halilhanbadem/delphi-google-speech-to-text now, if you want just "read the text", you can use the "ISpeechVoice" from MS, just importing it in your IDE, nothing more: Component -> Import component... type library sapi
-
Clean cache memory after generete fast report
programmerdelphi2k replied to Zazhir's topic in RTL and Delphi Object Pascal
@Zazhir first: YOUR CODE IS, at least: CONFUSED! .. bad! let's start: divide it in "small parts": each part, do some!!! "single responsability" create a procedure for each phase, then, you can work it separately Do not mix Query responsibilities with decision-making responsibilities on data to be used! :< you use: Query; gisOBJECTxxxx ... Exporting to file.... etc... Files procedure .. FInd, Close, etc.... etc... a complete Chaos! if you need "get" some info before generate your "QUERY", AND after this, gerenate your FASTREPORT, then, do it: first "get the info necessary to create your SQL text" do all avaliations necessary here dont put all in a "loop" like your, because if any part needs a long time to process, the report will go wait it for always.... now, create your SQL Text, as expected if all ok above, then you can use your file *.FR3 FastReport to feed it. IF YOU BE USING FireDAC components or not, you can use "PARAMS" from this components to feed it, and many others tasks... then, many code can be "take out" --------- try implement this idea... im using "IF" just for show how would be ... ok? procedure MyDeselectAllInFrmSIG; begin for i := 0 to frmSIG.SIG.Items.Count - 1 do begin if not (TGIS_LayerAbstract(frmSIG.SIG.Items[i]) is TGIS_LayerPixel) then TGIS_LAYERVECTOR(frmSIG.SIG.Items[i]).DeselectAll; end; end; function MyComponentPropertyItsOK( AComp:TGIS_LayerVector; AYourMsgError:string; const AFrmSig: TYourFrmSigType; const ALegtFileName:string; out AErrMsg:string ):boolean; begin result := false; // if not(AComp is TGIS_LayerVector) or (AComp = nil) then begin AErrMsg := 'AComp is not "TGIS_LayerVector" or is nil'); // exit; end; // if not(AFrmSig is TYourFrmSigType) or (AFrmSig = nil) then begin AErrMsg := 'AFrmSig is not "TYourFrmSigType" or is nil'); // exit; end; // if (ALegtFileName='') then AErrMsg := 'ALegtFileName is empty'); // exit; end; // try AComp:= TGIS_LayerVector( AFrmSig.SIG.Get(ALegtFileName) ) then // if Assinged(AComp) then result := true; else AErrMsg := AYourMsgError; except on E:Exception do AErrMsg := E.Message; end; end; procedure YourProcedureXXXXX; var MyErrMsg:string; MyGeoLayerVectorScope:string; LCompOkForUsage:boolean; MyQueryUID:TADOQuery; begin ... // MyDeselectAllInFrmSIG; // MyQueryUID:= TADOQuery.Create(nil); // create just one time!!!! OUT OF LOOPING... MyQueryUID.Connection := xxxxx; // // THIS would can be "into" your looping, but I think that is wrong... because your looping is very big (2000 iterations...) try MyErrMsg:=''; MyGeoLayerVectorScope:=''; // // using this way for show how would be... of course, you can use another approach (right way) if MyComponentPropertyItsOK( geo_layer_vector,'Imove not for use', AFrmSig, 'Imovel.legt', MyErrMsg) then MyGeoLayerVectorScope := 'IMOV_ID_CODPREF = ' +#39+ qryPesq.FieldByName('IMOV_ID_CODPREF').asString+#39; else if MyComponentPropertyItsOK( geo_layer_vector,'Piscine not for use', AFrmSig, 'Piscina.legt', MyErrMsg) then MyGeoLayerVectorScope := 'PISC_ID_CODPREF = ' +#39+ qryPesq.FieldByName('IMOV_ID_CODPREF').asString+#39 else if MyComponentPropertyItsOK( geo_layer_vector,'Lote not for use', AFrmSig, 'Lote.legt', MyErrMsg) then MyGeoLayerVectorScope := 'LOTE_ID_INSCRICAO = ' +#39+ qryPesq.FieldByName('IMOV_ID_CODPREF').asString+#39; // if (MyGeoLayerVectorScope='') then begin ShowYourErrorMessage( MyErrMsg OR AYourMsgError ); // showing Dialog into your "Looping" will go stop all flow... // exit; end; // geo_layer_vector.Scope := MyGeoLayerVectorScope; ... MyQueryUID.Close; // close to reusage! // MyQueryUID.SQL.Text := Format('Select GID from TableX where %s',[MyGeoLayerVectorScope]); ... // now, you FastReport here... then you need to know that any problem in this task will can crash the rest of "loop" query... // ... what to do from forward /// /// finally MyQueryUID.Free; end; end; -
MSBuild error when switching platforms and try to compile
programmerdelphi2k replied to softtouch's topic in Cross-platform
BRCC32 is to resource compiling, then, can some resource (*.res, *.ico, etc..) be corrupted or read-only when trying recreate it? if you are using a "git/svn/mercury/etc..." this file can be in use in moment of compilation, by other process, or some like this! then the "res" files cannot be created! -
Possible changes to string/char handling in Delphi 11(.2)?
programmerdelphi2k replied to omnibrain's topic in General Help
@omnibrain what was the problem, in fact? -
Send a file from a Delphi VCL program using WhatsApp Cloud API
programmerdelphi2k replied to lior I's topic in Network, Cloud and Web
wrong subject... sorry! -
Clean cache memory after generete fast report
programmerdelphi2k replied to Zazhir's topic in RTL and Delphi Object Pascal
Well, memory consumption is closely linked to the content of each report, ie the amount of components used and the when of information generated by them. So if you carry or generate a lot of information on each report, say 1 page, 100 pages, etc ... This will be decisive for your final size in memory (RAM or disc). Another factor is the number of consecutive executions and also present in memory while previous reports have not yet been discharged from memory. It would be necessary, perhaps, to determine the maximum memory volume egixide by the highest consumption report, for example. And take this level as a midpoint in the execution of the other reports. But, of course, sharing the 2000 reports into smaller portions of execution could also help. How do you perform this batch of executions? What is your code in the software? -
FireMonkey designer does not implement Shift-F10 for context menu
programmerdelphi2k replied to eivindbakkestuen's topic in Delphi IDE and APIs
sorry! >:) -
FireMonkey designer does not implement Shift-F10 for context menu
programmerdelphi2k replied to eivindbakkestuen's topic in Delphi IDE and APIs
just use the keyboard "Context Menu key" -
OAuth Authentication Embedded or Standard Browser?
programmerdelphi2k replied to Angus Robertson's topic in ICS - Internet Component Suite
when "WebView2Loader.dll" is executed, it create a folder in your "Temp" folder with all files necessary to run Edge! like a zip-file uncompressed! for that, you need just this file! -
Clean cache memory after generete fast report
programmerdelphi2k replied to Zazhir's topic in RTL and Delphi Object Pascal
First of all, I think you must be adopting the wrong way to generate your batch reports! Of course, if the FastReport component acts as a command that can be executed without needing to wait for its return, then it might mistakenly give you the impression that you can run multiple FastReports in sequence! As if you a "multi-thread" software! I'm not discussing here whether FastReport is multi-threading or not! OK! Just to try to make a comparison with the report above! (run multiple (2000) batch report); On the other hand, running 2000 tasks in an unsecured and uncontrolled manner is, to say the least, a wrong thing to do! But anyway, you're already doing it. So, try to check the component properties to work with the memory in use, because FastReport provides some options! A report and its data can be cached both in memory (to increase speed) and in a file on disk (to reduce RAM usage). There are several types of caching in Fast Report: “TfrxReport.EngineOptions.UseFileCache” - when True the whole text and objects of a built report are saved in a temporary file on disk; “TfrxReport.EngineOptions.MaxMemoSize” sets how many MB are reserved for the report in RAM “TfrxReport.PreviewOptions.PagesInCache” - the number of pages which can be kept in cached memory, which greatly increases preview speed, but uses a lot of memory (especially if there are pictures in the report) “TfrxReport.PreviewOptions.PictureCacheInFile” - when True all pictures in a built report are saved in a temporary file on disk, which greatly reduces memory use in reports that have a large number of pictures; but it reduces the speed -
Delphi 11 uses designide270.bpl instead of designide280.bpl and won't let me replace it!
programmerdelphi2k replied to Al T's topic in Delphi IDE and APIs
any way, in Registry we have it: He done reference to ... -
Can anyone check their Hash against mine, please? certUtil -hashfile designide280.bpl SHA256 (Delphi 11)
programmerdelphi2k replied to Al T's topic in Delphi IDE and APIs
Nome: designide280.bpl Tamanho: 1894304 bytes (1849 KiB) SHA256: 0fc933dde785368de661ec031580b2ae10d316532fd2c8c1ec2b831dc2605dc8 - 7zip 256 hash -
What the Delphi 11 version number after november patch ?
programmerdelphi2k replied to William23668's topic in Delphi IDE and APIs
here, Embarcadero® Delphi 11 Version 28.0.46481.1287 in fact, the "loader" is a "BDS.exe"! using or not only Delphi personality, just indicate that the bpl/dll loaded is for this personality! using "RAD Studio", the BDS.exe load all for all personalities! In my case, I always use "only Delphi": C:\RADStudio\RX112\bin\bds.exe "-pDelphi" -np -
TEdgeBrowser - Problem on destroy
programmerdelphi2k replied to chkaufmann's topic in RTL and Delphi Object Pascal
I don't know if I understood your proposal correctly! Does a VirtualTree start navigation? A VirtualTree is edit URL params (or any other info) for navigation? If so, then you have a conflict of interest here!!! Perhaps, it would be better for you to determine "exactly" when navigation starts. For example, using a boolean flag! TVbrowser: if ICanStartNavegation then begin ICanStartNavegation := false; // again not, please!!! // BrowerXXXX.navegate(...); end; TVEdits: if not ICanStartNavegation then begin editXXX := zzzz; etc... //.... ICanStartNavegation := true; //ok, you navegate now! end;