Re: Is it Possible to Print Subtotals in Subforms when Using Print Selection?

2018-03-19 Thread Chip Scheide via 4D_Tech
Doug,
I looked for the report I mentioned, which if I could find would 
probably allow me to resolve your issue with subtotals...
but it is not in any current system, and the old system i think it 
might be in I can not get into, as I have forgotten the PW..

I will try again this evening to see if I can get into that system.

and yes I know that print form would require a bunch of coding, but...i 
have not used area/print list... i figured it might/would be easier 
then starting from scratch, and since the forms you would need to print 
from already exist (the existing report and subforms). You would need 
to duplicate a some of the forms, and set the markers, but the code for 
print form is pretty straight forward. It seemed to me that it would 
not take as much work as the plugins.

Chip
On Mon, 19 Mar 2018 11:15:13 -0700, Douglas von Roeder wrote:
> Chip:
> 
> Print form is a 4D *command* and, yes, it allows me "complete control".
> That's a nice way of saying that I'll have to write a lot of code to use it
> because, by itself, the Print form command doesn't accomplish much.
> 
> In contrast, PrintList Pro is a *product* that allows me to print arrays or
> fields in one line of code but also has another couple of dozen commands to
> let me do formatting, break level processing, calculated columns, etc. In
> the same way that I use a "3rd party product" like 4D because the IDE and
> database engine have the features that I need, I use a 3rd party products
> like ALP and PLP because *they* have the features that I need. Q.E.D.
> 
> This particular application is rife with code and techniques from the 90's
> - subtables, "included areas", fixed size windows, Before, During, and
> After, etc. As time goes by, we're moving to AreaList Pro so we'll be able
> to use the tight integration of AreaList Pro and PrintList Pro to make
> things easy to print. I've been able to update this particular report with
> some small changes that the customer wanted but it appears that subtotals
> aren't doable without rewriting the report.
> 
> 
> --
> Douglas von Roeder
> 949-336-2902
> 
> On Sun, Mar 18, 2018 at 8:48 PM, Chip Scheide <4d_o...@pghrepository.org>
> wrote:
> 
>> it is a lot of work, but probably less then using a plugin or component
>> you *could* rewrite the report using print form.
>> 
>> You already have the base versions of the various forms you would need to
>> print with from the subtables
>> you would also have complete control at that point.
>> 
>>> it has been a long time since I did subform subtotals...
>>> I'll look for the code/system on monday.
>>> 
>>> I'll probably have to find the one report I did...
>>> 2 or 3 subforms, and 3 or 4 text areas all variable frame, with break
>>> points etc.
>>> 
>>> quite a beast!
>>> 
>>> But from memory...
>>> don't forget to sort the data ...ONE LEVEL EXTRA! place...
>>> sort on one more data bit then the break levels
>>> i.e.:
>>> break level 2
>>> Order
>>> selection([subtable];[subtable]field1;>[subtable]
>> field2;>;[subtable]field3;>)
>>> 
>>> 
>>> 
 Chip:
 
 Thanks for the reply.
 
 That tracks with the code that I put together after RTFM but no joy.
 
 I'm hitting On printing break in the parent form but never hitting it
 in the subforms. I can get a variable to print in the Break 0 area of
 the subform but the Subtotal function returns 0.
 
 Live and learn, eh?
 
 --
 Douglas von Roeder
 949-336-2902
 
 On Sun, Mar 18, 2018 at 7:00 AM, Chip Scheide
 <4d_o...@pghrepository.org> wrote:
> Doug,
> 
> if you have subforms set to print variable frame you need need to
> make sure the 'Z' order is correct also, otherwise variable frame
> printing will not work correctly. I do not remember which way it is,
> but it is either:
> lowest (on the 4D from) is lowest and top most variable frame object
> is top,
> or
> vise versa.
> 
> some code to help(?)
> only one level of break processing...
> you may need to have one more level of break processing set then you
> actually want.
> ie. : break level(3) for a 2 level break processing report, but that
> might be ancient history
> 
> -- setup for printing --
> 
> // clear sub and grand totals
> l_Animal_Grand_Total:=0
> l_Cage_Grand_Total:=0
> r_Cost_Grand_Total:=0
> l_Animal_Sub_Total:=0
> l_Cage_Sub_Total:=0
> r_Cost_Sub_Total:=0
> 
> //locate records
> QUERY SELECTION([Cage_Counts];[Cage_Counts]Laboratory_ID=$Lab_IDs-
>>> {$i})
> // setup values to (sub)total
> ACCUMULATE([Cage_Counts]Number_of_Animals;\
> [Cage_Counts]Number_of_Cages;\
> [Cage_Counts]Daily_Cost)
> //set break level
> BREAK LEVEL(1)
> 
> -- in the form method --
> : ($Form_Event=On Printing Break)
> l_Animal_Sub_Total:=Subtotal([Cage_Counts]Number_of_Animals)
> 

Re: Is it Possible to Print Subtotals in Subforms when Using Print Selection?

2018-03-19 Thread Douglas von Roeder via 4D_Tech
Chip:

Print form is a 4D *command* and, yes, it allows me "complete control".
That's a nice way of saying that I'll have to write a lot of code to use it
because, by itself, the Print form command doesn't accomplish much.

In contrast, PrintList Pro is a *product* that allows me to print arrays or
fields in one line of code but also has another couple of dozen commands to
let me do formatting, break level processing, calculated columns, etc. In
the same way that I use a "3rd party product" like 4D because the IDE and
database engine have the features that I need, I use a 3rd party products
like ALP and PLP because *they* have the features that I need. Q.E.D.

This particular application is rife with code and techniques from the 90's
- subtables, "included areas", fixed size windows, Before, During, and
After, etc. As time goes by, we're moving to AreaList Pro so we'll be able
to use the tight integration of AreaList Pro and PrintList Pro to make
things easy to print. I've been able to update this particular report with
some small changes that the customer wanted but it appears that subtotals
aren't doable without rewriting the report.


--
Douglas von Roeder
949-336-2902

On Sun, Mar 18, 2018 at 8:48 PM, Chip Scheide <4d_o...@pghrepository.org>
wrote:

> it is a lot of work, but probably less then using a plugin or component
> you *could* rewrite the report using print form.
>
> You already have the base versions of the various forms you would need to
> print with from the subtables
> you would also have complete control at that point.
>
> > it has been a long time since I did subform subtotals...
> > I'll look for the code/system on monday.
> >
> > I'll probably have to find the one report I did...
> > 2 or 3 subforms, and 3 or 4 text areas all variable frame, with break
> > points etc.
> >
> > quite a beast!
> >
> > But from memory...
> > don't forget to sort the data ...ONE LEVEL EXTRA! place...
> > sort on one more data bit then the break levels
> > i.e.:
> > break level 2
> > Order
> > selection([subtable];[subtable]field1;>[subtable]
> field2;>;[subtable]field3;>)
> >
> >
> >
> >> Chip:
> >>
> >> Thanks for the reply.
> >>
> >> That tracks with the code that I put together after RTFM but no joy.
> >>
> >> I'm hitting On printing break in the parent form but never hitting it
> >> in the subforms. I can get a variable to print in the Break 0 area of
> >> the subform but the Subtotal function returns 0.
> >>
> >> Live and learn, eh?
> >>
> >> --
> >> Douglas von Roeder
> >> 949-336-2902
> >>
> >> On Sun, Mar 18, 2018 at 7:00 AM, Chip Scheide
> >> <4d_o...@pghrepository.org> wrote:
> >>> Doug,
> >>>
> >>> if you have subforms set to print variable frame you need need to
> >>> make sure the 'Z' order is correct also, otherwise variable frame
> >>> printing will not work correctly. I do not remember which way it is,
> >>> but it is either:
> >>> lowest (on the 4D from) is lowest and top most variable frame object
> >>> is top,
> >>> or
> >>> vise versa.
> >>>
> >>> some code to help(?)
> >>> only one level of break processing...
> >>> you may need to have one more level of break processing set then you
> >>> actually want.
> >>> ie. : break level(3) for a 2 level break processing report, but that
> >>> might be ancient history
> >>>
> >>> -- setup for printing --
> >>>
> >>> // clear sub and grand totals
> >>> l_Animal_Grand_Total:=0
> >>> l_Cage_Grand_Total:=0
> >>> r_Cost_Grand_Total:=0
> >>> l_Animal_Sub_Total:=0
> >>> l_Cage_Sub_Total:=0
> >>> r_Cost_Sub_Total:=0
> >>>
> >>> //locate records
> >>> QUERY SELECTION([Cage_Counts];[Cage_Counts]Laboratory_ID=$Lab_IDs-
> >{$i})
> >>> // setup values to (sub)total
> >>> ACCUMULATE([Cage_Counts]Number_of_Animals;\
> >>> [Cage_Counts]Number_of_Cages;\
> >>> [Cage_Counts]Daily_Cost)
> >>> //set break level
> >>> BREAK LEVEL(1)
> >>>
> >>> -- in the form method --
> >>> : ($Form_Event=On Printing Break)
> >>> l_Animal_Sub_Total:=Subtotal([Cage_Counts]Number_of_Animals)
> >>> l_Cage_Sub_Total:=Subtotal([Cage_Counts]Number_of_Cages)
> >>> r_Cost_Sub_Total:=Subtotal([Cage_Counts]Daily_Cost)
> >>>
> >>> l_Cage_Grand_Total:=l_Cage_Sub_Total+l_Cage_Grand_Total
> >>> l_Animal_Grand_Total:=l_Animal_Sub_Total+l_Animal_Grand_Total
> >>> r_Cost_Grand_Total:=r_Cost_Sub_Total+r_Cost_Grand_Total
> >>>
> >>>
>  Philippe:
> 
>  Agreed ― PrintList Pro has tons of features, including subtotaling and
>  PrintList
>  Pro is one of the reasons why I've haven't needed to use commands like
>  Print selection since the early 90's. The app uses AreaList Pro,
>  fortunately, but we weren't planning on adding PrintList Pro to the
>  application until "the next version". I may have to modify that
> >>> part of the
>  plan if we can't use Print selection.
> 
>  "BTW AreaList Pro v10 also now provides break processing. I’ll
> >>> show you at
>  the Summit." - I'm looking forward to that!
> 
> 
>  --
>  Douglas von Roeder
>  

Re: overlapping subforms

2018-03-19 Thread John Baughman via 4D_Tech
If I understand you correctly, you have 3 subforms visible and want them to 
remain visible when you make a 4th subform visible on top of them? However, 
when you open the form and click the button to make it visible it appears 
behind the other 3 forms.

I just tested the above scenario and after in design mode I move the 4th 
subform to the front with Move To Front (control-F) then run it, the 4th 
subform displays in front. If I move it to the back with Move To Back 
(control-B) in design mode, it properly opens behind the other subforms when 
run.

Are you sure that you in fact moved the 4th subform to the front while in 
design mode?

John



> On Mar 19, 2018, at 3:02 AM, Randy Jaynes via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> I have a form with 3 subform container objects sitting on top of each other. 
> I just use OBJECT SET VISIBLE to hide the ones that don’t need to be seen at 
> the moment.
> 
> They all occupy the same space on the parent form, so because I hide the 2 
> not needed, the ordering on the form does not matter.
> 
> I use a tab to control which one is visible at the moment. Your buttons could 
> serve the same purpose.
> 
> Randy
> 
> --
> Randy Jaynes
> Senior Programmer and Customer Support
> 
> http://printpoint.com  • 845.687.3741 • PrintPoint, 
> Inc • 57 Ludlow Lane • Palisades, NY 10964 
> Please send all email contacts to supp...@printpoint.com 
> 
> 
> 
> 
> 
>> On Mar 19, 2018, at 4:40 AM, Piotr Chabot Stadhouders via 4D_Tech 
>> <4d_tech@lists.4d.com > wrote:
>> 
>> Hi,
>> 
>> I have a form with a couple of subforms on it
>> Now I want to add another subform, that is on top of 3 others, and becomes 
>> visible when pressing a button
>> You can see it as a kind of popup viewer
>> Because the subform must show in front of the others, in design mode I put 
>> the subform container to the front
>> However, when I save the form the subform container disappears to the back 
>> again
>> 
>> Are there known problems putting subforms on top of each other?
>> 
>> Gr,
>> 
>> Piotr
>> 
>> **
>> 4D Internet Users Group (4D iNUG)
>> FAQ:  http://lists.4d.com/faqnug.html 
>> Archive:  http://lists.4d.com/archives.html 
>> 
>> Options: https://lists.4d.com/mailman/options/4d_tech 
>> 
>> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com 
>> 
>> **
> 
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **

John Baughman
Kailua, Hawaii
(808) 262-0328
john...@hawaii.rr.com





**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Modelling graph image

2018-03-19 Thread STARDATA via 4D_Tech
Thank you for the answer. Can you send me a demo for the application,
database or just the code snippet that you made to implement this function.
I can't see how you can create a graph without the function. Are you using
external plugin? Do you think is a good idea to use the image made by the
graph command with SVG commands?

Thanks for the attention

Cheers!



--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Modelling graph image

2018-03-19 Thread Adam Bevan via 4D_Tech
A few years ago I built my own graph method using the svg commands. It did all 
you’ve indicated but the coloured/symbol points. Though that would have been 
easy to add.

I did not use the graph command though.

Sent from my iPhone

> On Mar 17, 2018, at 3:43 AM, STARDATA via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> Hi everyone!
> Is there any way which i can manipulate the result of the function GRAPH()
> to obtain a graphic similar to the mail attached? Are SVG commands somehow
> helpful? 
> What i wanna do is color the points over a certain value as you can see for
> those yellow points and give a color to a value limiter as shown in the
> image by the blue and green lines.
> 
> Many thanks to everyone will come in help!
> 
> Cheers!
> 
> 
> 
>  
> 
> 
> 
> --
> Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: overlapping subforms

2018-03-19 Thread Randy Jaynes via 4D_Tech
I have a form with 3 subform container objects sitting on top of each other. I 
just use OBJECT SET VISIBLE to hide the ones that don’t need to be seen at the 
moment.

They all occupy the same space on the parent form, so because I hide the 2 not 
needed, the ordering on the form does not matter.

I use a tab to control which one is visible at the moment. Your buttons could 
serve the same purpose.

Randy

--
Randy Jaynes
Senior Programmer and Customer Support

http://printpoint.com  • 845.687.3741 • PrintPoint, Inc 
• 57 Ludlow Lane • Palisades, NY 10964 
Please send all email contacts to supp...@printpoint.com 





> On Mar 19, 2018, at 4:40 AM, Piotr Chabot Stadhouders via 4D_Tech 
> <4d_tech@lists.4d.com > wrote:
> 
> Hi,
> 
> I have a form with a couple of subforms on it
> Now I want to add another subform, that is on top of 3 others, and becomes 
> visible when pressing a button
> You can see it as a kind of popup viewer
> Because the subform must show in front of the others, in design mode I put 
> the subform container to the front
> However, when I save the form the subform container disappears to the back 
> again
> 
> Are there known problems putting subforms on top of each other?
> 
> Gr,
> 
> Piotr
> 
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html 
> Archive:  http://lists.4d.com/archives.html 
> 
> Options: https://lists.4d.com/mailman/options/4d_tech 
> 
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com 
> 
> **

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

overlapping subforms

2018-03-19 Thread Piotr Chabot Stadhouders via 4D_Tech
Hi,

I have a form with a couple of subforms on it
Now I want to add another subform, that is on top of 3 others, and becomes 
visible when pressing a button
You can see it as a kind of popup viewer
Because the subform must show in front of the others, in design mode I put the 
subform container to the front
However, when I save the form the subform container disappears to the back again

Are there known problems putting subforms on top of each other?

Gr,

Piotr

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**