Jump to content

programmerdelphi2k

Members
  • Content Count

    1406
  • Joined

  • Last visited

  • Days Won

    22

Everything posted by programmerdelphi2k

  1. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    a test using a XLS file Excell 2003 by FireDAC ODCB 32bits on MSWin 10 ... nothing more!!! I not use (not installed) MSOffice in my system ODBC_Excell_sheet.7z
  2. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    as said on Help: and, as we can change the "directional" mode, then is necessary check it.
  3. programmerdelphi2k

    FMX Default style in TStyleBook

    I think that by design, Embarcadero do it to minimize all compleXity between platforms... if was possible. then, you need just 1 TStyleBook to many "items" (platform flags) definitions in the same place (screen). be to load or define it on designtime (or same in creating on runtime,complicate but possible I has tryed and it's works) each one with its particularity... if "I agree" or not, does not matters, at all. if it's ok for you, it's ok! else, ... at end, for while, it's that way! maybe change someday. as usual.
  4. programmerdelphi2k

    FMX Default style in TStyleBook

    for FMX form with 2 platform (MSWindows and Android) style defined = a TImage empty!!! object Form1: TForm1 Left = 0 Top = 0 Caption = 'Form1' ClientHeight = 480 ClientWidth = 640 FormFactor.Width = 320 FormFactor.Height = 480 FormFactor.Devices = [Desktop] DesignerMasterStyle = 0 object StyleBook1: TStyleBook Styles = < item ResourcesBin = { 464D585F5354594C4520322E3501060B496D616765315374796C650246005450 46300654496D61676500095374796C654E616D65060B496D616765315374796C 650E4D756C74695265734269746D61700E01000005416C69676E070643656E74 65720000} end item Platform = 'AndroidL Light' ResourcesBin = { 464D585F5354594C4520322E3501060B496D616765315374796C650246005450 46300654496D61676500095374796C654E616D65060B496D616765315374796C 650E4D756C74695265734269746D61700E01000005416C69676E070643656E74 65720000} end> Left = 176 Top = 152 end end
  5. programmerdelphi2k

    FMX Default style in TStyleBook

    as you should know, each "enviroment" is distinct in many aspect!!! then, needs a particular approach for it! VCL and FireMonkey are distinct too! then, needs an particular approach too! before, the style was a "binary" file, now is a 'text".. you can open "*.style" file in your notepad and see for yourself! you'll see this line: for sure, internally, the "flag" will be used to special processing. if exists so much possibility, why put all in the same place? Is TImage in VCL the same as TImage in FMX? And why not? Are there any technical or design reasons?
  6. programmerdelphi2k

    Firedac Access Violation - TFDUpdateSQL

    maybe a conflict between "residual" files (old edition) persistents and new install... dcu or bpl I always prefere uninstall (first) and install (new). deleting all folders and residual files from old install, except the license keys in c:\ProgramData... in last case, I would try a clean install!!!
  7. programmerdelphi2k

    Stuck half way through fixing the XE4 help system

    and H2Reg? https://www.helpwaregroup.com/products/h2reg http://kb.helpwaregroup.com/product-h2reg/h2reg-faq/h2reg-installers http://kb.helpwaregroup.com/mshelp2/borland-h2-help http://kb.helpwaregroup.com/mshelp2/h2-info
  8. programmerdelphi2k

    Stuck half way through fixing the XE4 help system

    did try install just only the "Microsoft C++ Redistributable and Visual Studio 2008" for Win7? https://www.microsoft.com/en-us/download/search.aspx?q=visual studio sdk note: https://answers.microsoft.com/en-us/windows/forum/all/ms-help-2x-runtime-download/038c8455-e209-4694-b500-42936d934d07
  9. programmerdelphi2k

    Help on reading values from a JSON array

    You has many levels in this JSON... some like this... uses System.JSON; procedure TForm1.Button1Click(Sender: TObject); var s : string; jv: TJSONValue; ja: TJSONArray; jo: TJSONObject; jp: TJSONPair; begin s := '{"A":0,"B":0,"C":1,"D":0,' + { } '"K":{"T":"X","acc":81,"max":116},' + { } '"result":[{"type":{"TP":30.3,"message":"Added successfuly"},"time":503,"flex":"yes"}]}'; // try jo := TJSONValue.ParseJSONValue(s) as TJSONObject; // if JSON is good, go ahead. Else, break with an Exception! // try jp := jo.Get('result'); // 'K', 'result' // direct to the point! Memo1.Text := jp.JsonValue.ToString; // if jp.JsonValue is TJSONObject then for var i: integer := 0 to TJSONObject(jp.JsonValue).Count - 1 do begin // Memo1.Lines.Add(TJSONObject(jp.JsonValue).Pairs[i].ToJSON) Memo1.Lines.Add(TJSONObject(jp.JsonValue).Pairs[i].JsonString.ToString + ' is ' + TJSONObject(jp.JsonValue).Pairs[i].JsonValue.ToString); end else // array begin for var A in TJSONArray(jp.JsonValue) do if A is TJSONObject then for var z: integer := 0 to (TJSONObject(A).Count - 1) do Memo1.Lines.Add(TJSONObject(A).Pairs[z].JsonString.ToString + ' is ' + TJSONObject(A).Pairs[z].JsonValue.ToString); end; except // PAIR not valid!!! Key not found... end; // // Memo1.Lines.Add('-----------------'); // // walking on the road... for var O in jo do begin Memo1.Lines.Add('Object: ' + O.JsonString.ToString); // if O.JsonValue is TJSONArray then begin for var A in TJSONArray(O.JsonValue) do begin Memo1.Lines.Add('...Is an Array: ' + A.ToString); // ... recursive function here... end; end else // is an object... but... "if" is a array... needs a recursive too??? begin Memo1.Lines.Add('...Not an Array is Object: ' + O.ToString); end; end; except // JSON not valid!!! end; end;
  10. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    I understand! maybe some necessity of clean old read... like clear cache on memory... each read needs a transaction roolback or commit ... did try? Firedac create 1 transaction internally for when not explicitly created.
  11. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    SELECT * FROM tableX where invoice = 99 OR invoice = 98 ---- invoice in (98,99) ... invoice between 98 to 99
  12. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    im on cell now, then the point is: connections string ok... yeah db opened fdquery sql open the records (all records without any "where") and show my fields choiced? yeah table opened then just now use your filter, like "where" above did you try this?
  13. programmerdelphi2k

    Refresh dbedit after insert

    bang! bang! stay closed with me, baby! 😂
  14. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    first, you need test your connection string, if ok... 2nd, fdconnected, now you need just a fdquery as usual. 3rd, in fdquery, the sql xpression is the same than any other table access, same fields declaration, and others filters. nothing different than others data sources. you see?
  15. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    why do you need ClientDataset? some special? fdQuery can save in disk too!!! did you know?
  16. programmerdelphi2k

    D11 Update 1 + FireDAC + ODBC to Sage returning wrong data!

    hi @Jasonjac2 if your problem is about use ODBC in FireDAC, you can do it as usual in any other case, for example: Excell file access: with ODBC installed in your PC, 32 or 64bits edition in MSWin use ODBC tools (see in Control Panel or any other shortcut in MSwin) and create a "DNS" file with all setup necessary to access your EXCELL file. open this file and see what is necessary to config your FDConnection FireDAC in Delphi, in FireDAC you'll needs this components: a FDxxxWait, FDxxPhysODBC driver, FDxxxConnect, FDxxQuery, basically. now, just config your FDConnection you can use ADVANCED config to put all DSN file config (the string connection). it's simple way. now connect your FDQuery on FDConnection and fill your SQL to easy usage, use "PARAMS" in FDQuery to change the values on "where" clause, for example. fdqry.close; fdqry.Param.clear; fdqry.SQL.Text:= 'select .... from .... where YourField = :YourParamName'; fdqry.Param.ParamByName( 'YourParamName' ).AsInteger := 11111; fdqry.Open; .... when you need change the value on Param, just use this: fdqry.Param.ParamByName( 'YourParamName' ).AsInteger := 22222; fdqry.Refresh; https://intercom.help/ssgpenelope/en/articles/5189639-how-to-create-an-odbc-data-connection-in-excel https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Connect_to_ODBC_Data_Source_(FireDAC)
  17. programmerdelphi2k

    JEDI Installation Annoyances 10.4

    Delphi 7 there is not more support or it's shiped!!! if exists on Internet is not by Embarcadero, you see? dont lost your time with: "it's better" "it's cool", etc... go ahead, if it's good for you, it's good!!!
  18. programmerdelphi2k

    JEDI Installation Annoyances 10.4

    for sure you can do it this way... "IF..." the bpl is the same version than your IDE. pay attention ! (including is Debug or Release mode for DCUs files).. at end, all compilation and building will create a "BPL" in the Public (or in arbitrary folder) defined... then, it's ok if it's ok! summary: look at: BPL and DCP sub-folders... and see if the same pacakges names is in!!! xxx.BPL and xxx.DCP (basically to VCL, ) the DCU files is used to compose your final binary, then, you'll need it! else, you'll need PAS files, because the DCU will be create from it!
  19. programmerdelphi2k

    Disable then Enable a Procedure

    using "conditionals" is going to make it very unsafe... any other method can undo... better "nil" ED, then nothing will happen! for sure! NOTE: OF COURSE, ,any other method can UNdo it (nil...) too... but this "way" is done by default when building your class on Delphi.
  20. maybe better place would be Embarcadero... Malcolm Grooves blog is good for basic understanding... (above) https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Using_App_Tethering https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Connecting_to_Remote_Applications_Using_App_Tethering note: behind scenes = Indy
  21. AppTethering is understood just publish info, basically. Malcom know it better than me
  22. programmerdelphi2k

    JEDI Installation Annoyances 10.4

    but I think that Community would accept a install (manual) by packages... open each DPKs and build+install (design time packs) (in order, put path on IDE, etc...) see GROUP files to see what DPK is used... and the order to build it
  23. programmerdelphi2k

    JEDI Installation Annoyances 10.4

    solution: RAD non-Trial/Pro/Enterprise! try download and install in a VM same that TRIAL... and test
  24. at end... AppTethering use TCP UDP protocol behind scenes http://www.malcolmgroves.com/blog/?p=1854 Edit: the beggin: http://www.malcolmgroves.com/blog/?p=1842
  25. programmerdelphi2k

    Disable then Enable a Procedure

    or this: type TForm1 = class(TForm) Button1: TButton; procedure Button1Click(Sender: TObject); private procedure OrThisProc(Sender: TObject); public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} type TMyProcX = procedure(Sender: TObject); var MyProcX: TMyProcX; MyProcY: TNotifyEvent; // = procedure(Sender : TObject) of object; <-- in this case, Object = Form1 procedure HelloWorld(Sender: TObject); begin end; procedure TForm1.OrThisProc(Sender: TObject); begin end; // to better understanding... it was edited: begin // when it shouldnt be used MyProcX := nil; MyProcY := nil; // when, it should be... MyProcX := HelloWorld; MyProcY := OrThisProc; // before any use, test it if Assigned(MyProcX) then MyProcX(Sender); // if Assigned(MyProcY) then MyProcY(Sender); end.
×