DEMO banner appears randomly

Knowledge exchange related to the VPE Report Engine and PDF Library

Moderator: IDEAL Software Support

DEMO banner appears randomly

Postby rlizak » Wed Feb 08, 2006 3:27 pm

Our application which generates reports from a grid of data is causing some odd behavior at random. This problem was found by our testers, usually after running many reports within the same session. Essentially, after "n" attempts, the DEMO banner appears on the reports, and from that point until the machine is rebooted, the DEMO banner appears on any report run from that point forward.

The code is running on a local workstation.

I have read references on the board regarding the need / need to not call VpeCloseDoc(), which I am not calling in code.

So the flow is:

long ch_VPE;
ch_VPE = VpeOpenDoc(m_hWnd, "Report Output",VPE_NO_RULERS|VPE_NO_INFOBUTTON);

VpeLicense(ch_VPE, "key one", "key two");

... call another class which actually writes the data, passing in ch_VPE

VpePreviewDoc(ch_VPE, NULL, 2);

The user would preview, maybe print and then close the preview. They may or may not close the dialog where they select the report type to run.

My question is, in regards to the way the app operates, do we need to watch for the preview window to close and at that point call VpeCloseDoc()? I am confused as to why the DEMO banner appears after "n" runs of the report code within a single application on a local box. Does calling VpeLicense() over and over cause any potential issues?

Thanks for any insight.
--Rob.
rlizak
 
Posts: 7
Joined: Wed Feb 08, 2006 3:13 pm

Postby IDEAL Software Support » Thu Feb 09, 2006 5:48 pm

>>
My question is, in regards to the way the app operates, do we need to watch for the preview window to close and at that point call VpeCloseDoc()?
<<

Unless you set the property AutoDelete = false, the document is automatically deleted (closed), when the preview window is closed. By default AutoDelete is true, so you should not call CloseDoc() when the preview windows is closed.

Your problem may be related to a bug. Did you download the latest version of VPE (R4) from our website?

Regards
Thorsten Radde
IDEAL Software GmbH
IDEAL Software Support
 
Posts: 1631
Joined: Thu Nov 18, 2004 4:03 pm

Postby rlizak » Thu Feb 09, 2006 10:53 pm

Yes, I am building against the R4 service pack. What seems odd is that it appears to happen at random. I have seen the demo banner come up in as little as 5 runs, and other times I ran literally hundreds of times while testing code and never see the demo banner.

Thanks,
--Rob.
rlizak
 
Posts: 7
Joined: Wed Feb 08, 2006 3:13 pm

Postby IDEAL Software Support » Fri Feb 10, 2006 11:54 am

Are you using multi-threading in your application?

On what platform are you encountering these problems?
IDEAL Software Support
 
Posts: 1631
Joined: Thu Nov 18, 2004 4:03 pm

Postby rlizak » Fri Feb 10, 2006 2:09 pm

Platform in Windows 2000 Professional, Service Pack 4.
The app does use multi threading, however, not in the reporting area.

Thanks,
--Rob.
rlizak
 
Posts: 7
Joined: Wed Feb 08, 2006 3:13 pm

Postby IDEAL Software Support » Fri Feb 10, 2006 3:03 pm

If this should be a bug in VPE, much more customers would report this problem, but you are the only one.

The demo banner appears, because VPE thinks it is running in a server environment without an installed server license. I assume your application is not running as a service or as part of a web server?

If it is a standalone application, it must have to do with multi-threading. For each license key, a single thread (or application) can open an unlimited number of VPE documents simultaneously. But only up to three threads may use the same license key at the same time.
IDEAL Software Support
 
Posts: 1631
Joined: Thu Nov 18, 2004 4:03 pm

Postby rlizak » Fri Feb 10, 2006 3:39 pm

The application is stand alone and VPE is used in only one thread. Would running the application from a network share potentially cause the issue? My development area is on another file server on the network. Crazy thing is when this was based on 3.50 the problem did not occur, and the class that uses VPE has not changed since then.

Here are the third-party pieces of the app (if that may make any difference):

VPE 3.60 R4 of course
Objectivity/DB 9.1
Stingray Objective Toolkit

everything else is stock MFC or controls subclassed from stock MFC controls.

What seems very odd is that once the demo banner appears, it won't go away until the machine is rebooted, so even if the process is exited clean, the problem persists in subsequent runs of the application.

Thanks,
--Rob.
rlizak
 
Posts: 7
Joined: Wed Feb 08, 2006 3:13 pm

Postby IDEAL Software Support » Mon Feb 13, 2006 6:33 pm

>>
What seems very odd is that once the demo banner appears, it won't go away until the machine is rebooted, so even if the process is exited clean, the problem persists in subsequent runs of the application.
<<

This indicates a problem with license counting. It is done via shared memory. If it does not help to terminate your application, which frees the shared memory, another instance of VPE is running elsewhere. Please check this.

We can also send you a debug version of the VPE DLL to get some more information.
IDEAL Software Support
 
Posts: 1631
Joined: Thu Nov 18, 2004 4:03 pm

Postby rlizak » Mon Feb 13, 2006 7:31 pm

Next time I see this happen I will check out the process and make sure everything was cleared out when terminating the application.

The debug DLL sounds good. I wrote a sample app that opened and closed over 5000 documents with no problem... I am starting to think something is happening in the real app that uses Objectivity/DB... I have two applications that use this and on both of them I see the "demo" banner at random times, but what still is odd to me is that neither of those applications uses multi threading within the dialog where VPE is used, but that is the only thing I can think of thats getting in the way somehow...

--Rob.
rlizak
 
Posts: 7
Joined: Wed Feb 08, 2006 3:13 pm

Postby IDEAL Software Support » Tue Feb 14, 2006 2:19 pm

Please send an e-mail to our support e-mail address and request the debug DLL.
IDEAL Software Support
 
Posts: 1631
Joined: Thu Nov 18, 2004 4:03 pm


Return to VPE Open Forum

Who is online

Users browsing this forum: No registered users and 5 guests

cron