Project JEDI - Issue Tracker
Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0005970 [JEDI VCL] 00 JVCL Components major always 2012-08-28 17:44 2015-09-21 17:47
Reporter jediuser9999 View Status public  
Assigned To obones
Priority normal Resolution fixed  
Status resolved   Product Version 3.45
Summary 0005970: JvAppInstance component doesnt work proper
Description in the jvcl dir, choose the example project for AppInstance-component.
-Set appinstancecount to 1.
-Compile.
-Copy the exe to three different dirs.
-You can start all the exes without problems.
-Starting a second instance from a exe in one dir is beeing blocked by the
component correctly.

Win7/64
Additional Information
Tags No tags attached.
Attached Files

- Relationships

-  Notes
(0020130)
jediuser9999 (reporter)
2012-08-28 17:45

Delphi 2010
(0020131)
outchy (administrator)
2012-08-28 19:23

This has always been the case. But you can specify an explicit application identifier by modifying the following function in jvcl/run/JvAppInstances.pas:

function TJvAppInstances.GetAppInstances: TJclAppInstances;
begin
  if csDesigning in ComponentState then
    Result := nil
  else
    Result := JclAppInstances(your application id here); // create AppInstance
end;

Then you need to recompile the JVCL.

An other alternative is not to use an instance of TJvAppInstance but to use JCL code directly. Basically you just need to add the following line as the first line of the project entry point (.dpr):

JclAppInstances(your application id here).CheckSingleInstance;

By doing this, you will have more control on how to count the instances (global, per user, per session).
(0020827)
obones (administrator)
2013-12-13 15:18

Use SetUniqueAppId before creating any TJvAppInstances component and you'll be able to achieve what you want.

- Issue History
Date Modified Username Field Change
2012-08-28 17:44 jediuser9999 New Issue
2012-08-28 17:45 jediuser9999 Note Added: 0020130
2012-08-28 19:23 outchy Note Added: 0020131
2013-01-15 15:24 obones Status new => acknowledged
2013-12-13 15:18 obones Note Added: 0020827
2013-12-13 15:18 obones Status acknowledged => resolved
2013-12-13 15:18 obones Fixed in Version => Daily / GIT
2013-12-13 15:18 obones Resolution open => fixed
2013-12-13 15:18 obones Assigned To => obones
2015-09-21 17:47 obones Fixed in Version Daily / GIT => 3.49


Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker