Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6978711
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T17:47:31+00:00 2026-05-27T17:47:31+00:00

I’m wondering if someone has an example on how can be used the TJvProgramVersionCheck

  • 0

I’m wondering if someone has an example on how can be used the TJvProgramVersionCheck component performing the check via HTTP.

The example in the JVCL examples dir doesn’t show how to use HTTP

thank you

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T17:47:32+00:00Added an answer on May 27, 2026 at 5:47 pm

    The demo included in your $(JVCL)\Examples\JvProgramVersionCheck folder seems to be able to do so. Edit the properties of the JVProgramVersionHTTPLocation, and add the URL to it’s VersionInfoLocation list (a TStrings). You can also set up any username, password, proxy, and port settings if needed.

    You also need to add an OnLoadFileFromRemote event handler. I don’t see anything in the demo that addresses that requirement, but the source code says:

    { Simple HTTP location class with no http logic.
    The logic must be implemented manually in the OnLoadFileFromRemote event }
    

    It appears from the parameters that event receives that you do your checking there:

    function TJvProgramVersionFTPLocation.LoadFileFromRemoteInt(
      const ARemotePath, ARemoteFileName, ALocalPath, ALocalFileName: string;
      ABaseThread: TJvBaseThread): string;
    

    So you’ll need to add an event handler for this event, and then change the TJVProgramVersionCheck.LocationType property to pvltHTTP and run the demo. After testing, it seems you’re provided the server and filename for the remote version, and a local path and temp filename for the file you download. The event handler’s Result should be the full path and filename of the newly downloaded file. Your event handler should take care of the actual retrieval of the file.

    There are a couple of additional types defined in JvProgramVersionCheck.pas, (TJvProgramVersionHTTPLocationICS and TJvProgramVersionHTTPLocationIndy, both protected by compiler defines so they don’t exist in the default compilation. However, setting the ICS related define resulted in lots of compilation errors (it apparently was written against an old version of ICS), and setting the Indy define (and then setting it again to use Indy10 instead) allowed it to compile but didn’t change any of the behavior. I’m going to look more into this later today.

    Also, make sure that the VersionInfoLocation entry is only the URL (without the filename); the filename itself goes in the VersionInfoFileName property. If you put it in the URL, it gets repeated (as in http://localhost/Remote/ProjectVersions_http.iniProjectVersions_http.ini, and will fail anyway. (I found this while tracing through the debugger trying to solve the issue.)

    Finally…

    The solution is slightly (but not drastically) complicated. Here’s what I did:

    Copy JvProgramVersionCheck.pas to the demo folder. (It needs to be recompiled because of the next step.)

    Go to Project->Options->Directories and Conditionals, and add the following line to the DEFINES entry:

    USE_3RDPARTY_INDY10;USE_THIRDPARTY_INDY;
    

    Delete the JvProgramVersionHTTPLocation component from the demo form.

    Add a new private section to the form declaration:

    private
      HTTPLocation: TJvProgramVersionHTTPLocationIndy;
    

    In the FormCreate event, add the following code:

    procedure TForm1.FormCreate(Sender: TObject);
    const
      RemoteFileURL = 'http://localhost/';
      RemoteFileName = 'ProjectVersions_http.ini';
    begin
      HTTPLocation := TJvProgramVersionHTTPLocationIndy.Create(Self); // Self means we don't free
      HTTPLocation.VersionInfoLocationPathList.Add(RemoteFileURL);
      HTTPLocation.VersionInfoFileName := RemoteFileName;
      ProgramVersionCheck.LocationHTTP := HTTPLocation;
      ProgramVersionCheck.LocationType := pvltHTTP;
      VersionCheck;  // This line is already there
    end;
    

    In the ProgramVersionCheck component properties, expand the VersionInfoFileOptions property, and change the FileFormat from hffXML to hffIni.

    Delete or rename the versioninfolocal.ini from the demo’s folder. (If you’ve run the app once, it stores the http location info, and the changes above are overwritten. This took a while to track down.)

    Make sure your local http server is running, and the ProjectVersions_http.ini file is in the web root folder. You should then be able to run the demo. Once the form appears, click on the Edit History button to see the information retrieved from the remote version info file. You’ll also have a new copy of the versioninfolocal.ini that has the saved configuration info you entered above.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I want to count how many characters a certain string has in PHP, but
I used javascript for loading a picture on my website depending on which small
I have a jquery bug and I've been looking for hours now, I can't
Basically, what I'm trying to create is a page of div tags, each has
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I've got a string that has curly quotes in it. I'd like to replace
In my XML file chapters tag has more chapter tag.i need to display chapters

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.