Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. ChrisGSchultz

    Compare Date using ADO and Access

    ...EndDate The query is then something like: with MyQuery do begin close; SQL.Clear; // build the main statement SQL.Add(' SELECT * FROM TestTable'; SQL.Add(' WHERE ((ExpireDate BETWEEN :startdate AND :enddate)'); // or > :startdate - anything with a : preceding it is a...
  2. ChrisGSchultz

    Delphi data file direct access to tables

    Check out http://filext.com to find the extension - FoxPro should be a DBF, with CDX (the index) and FPT (memos) files attached. Cheers, Chris [pc2]
  3. ChrisGSchultz

    Maxamize a program from a Delphi 7.0 program .

    Use the WindowState property: Form1.WindowState := wsMaximized; // type TWindowState = (wsNormal, wsMinimized, wsMaximized) Check out the help on WindowState, Application.Minimize and Application.Restore - it's all there. Cheers, Chris [pc2]
  4. ChrisGSchultz

    Old DOS Database In Delphi 5

    Delphi 5 Pro supported Paradox and dBase via the BDE, and it should be able to read them. Database Desktop has hardly changed since D5, so that shouldn't be an issue. If you can read them with this app, then D5 will work fine. A quick look at the ODBC setup in WinXP shows it can read v3 to v5 of...
  5. ChrisGSchultz

    searching an array

    G'day Les, Although I haven't done this - I have looked into it in the past. I assume your data structure will include date-time, string and numeric types. Arrays get very messy to search, and hard to maintain if things go wrong (eg your on leave and it breaks). I tend to use arrays of...
  6. ChrisGSchultz

    Delphi - Read Excel file

    Search this forum as well - there is an FAQ and several posts on how to do this, including links to websites with demos. Cheers, Chris [pc2]
  7. ChrisGSchultz

    Borland license information - Delphi won't start

    Hi Andrew, Not sure if this will help, but I had a similar problem when my PC didn't shut down properly about 18 months ago. However, my home PC had a copy of the software running ok. I found there are three files (BORLAND.LIC, REGISTRY.DAT and REGISTRY.SLM) in C:\Documents and...
  8. ChrisGSchultz

    How to read the "PATH"?

    The path is an environment variable. You can see them listed from a command prompt by typing set. To access any of these variables, use the Delphi function: GetEnvironmentVariable(sVarname) where sVarname is the environment variable - in your case 'PATH'. The function returns a string, so you...
  9. ChrisGSchultz

    Delphi - add trusted site in IE

    A quick look on Google (for trusted sites registry)found this information: http://msdn.microsoft.com/workshop/security/szone/overview/esc_development.asp and this (slightly more chatty): http://www.microsoft.com/technet/scriptcenter/resources/qanda/feb05/hey0214.mspx There is also some basic...
  10. ChrisGSchultz

    Closing A Program after Create

    I beg to differ - from the help on TApplication, and the Application.Terminate help: In my own apps, posts committed, files closed etc - no grief encountered [smile] Cheers, Chris [pc2]
  11. ChrisGSchultz

    Closing A Program after Create

    Always happy to help! Cheers, Chris [pc2]
  12. ChrisGSchultz

    Zipping A File then Renaming it...

    Renaming is fairly simple use either of these functions: Rename in the System unit syntax: procedure Rename(var F; Newname: string); This one assumes the file F exists, and is of any type RenameFile in the SysUtils unit. syntax : function RenameFile(const OldName, NewName: string): Boolean; It...
  13. ChrisGSchultz

    Closing A Program after Create

    You'll have to terminate the application (ie insert the code Application.Terminate;) rather than close the form if I understand you correctly. Cheers, Chris [pc2]
  14. ChrisGSchultz

    entering integers at runtime

    There are other ways to ensure that entry is as you require: Use a TMaskEdit component - this allows you create an edit mask, which can then be handled without any other code - the component handles the checking. Just convert the resulting MaskEdit.Text to your integer In D6 & D7 (not sure...
  15. ChrisGSchultz

    How to Display Blank Date in a TDateTimePicker

    Delfy is probably correct - Delphi is Pascal and will set any uninitialised variable to a random value normally. Components such as DateTimePicker can't allow this to happen, so will default to the earliest date they can use in the system - usually the end of the 19th century (depending on your...
  16. ChrisGSchultz

    Getting Data Out Of Columns

    Sorry about that - my fault for writing it off the top of my head! Here's a tested working version [tongue]: var sCurrLine, nVar1, nVar2, nVar3, nVar4 : string; I, nComma, nLastComma : integer; begin for I := 0 to (Memo1.Lines.Count - 1) do begin // initialise the temporary...
  17. ChrisGSchultz

    Getting Data Out Of Columns

    Oops - forgot about your max/min question! If your data is in an array, then you can use the MaxValue and MinValue functions (in the Math unit) From the help file: function MaxValue(const Data: array of Double): Double; There are also MaxInt and MinInt functions for integer arrays. However, how...
  18. ChrisGSchultz

    Getting Data Out Of Columns

    Do you write the data into the Memo, or read it in from a file? Your data looks like a Comma Separated Value (CSV) format file. If your reading it in, a very simple way to extract the data is use a READLN(fInFile,Var1,Var2,Var3,Var4.....varN); This will require you to know the types of each...
  19. ChrisGSchultz

    TADODataset with Access2000 like "*"

    ...MDAC. Similarly, Delphi has variations on this. One of the things I do is test the SQL in the Database Desktop. I suspect that your Name LIKE "*"wildcard should be NAME LIKE "%" To illustrate some other features - here's a piece of SQL that I use in one of my queries: SELECT pat_handle...
  20. ChrisGSchultz

    Please help me - Filter Data in DELPHI 7

    Oops - just noticed an extra bracket and extra BETWEEN in the SQL statement. It should read: SQL.Add:='SELECT * FROM Total1 WHERE (Data BETWEEN :Date1 and :Date2)'; BTW, I assume that Data is a date variable. If not, you'll have to ensure that the variable your testing with the WHERE is the...

Part and Inventory Search

Back
Top