Menu

Report module: usage of PGVRSetVar

Help
Kerry Choy
2010-06-08
2013-05-30
  • Kerry Choy

    Kerry Choy - 2010-06-08

    I'm having trouble with the PGVRSetVar node. There are two PGVRSetVar calls: the first one work, the latter does not.

    <PGVRBody>
                <PGVRRelatives id="$pid" group="$relatives" sortby="$sortby" maxgen="*">
                    <PGVRSetVar name="thePerson" value="@ID" />
                    <PGVRSetVar name="theBirthDate" value="@BIRT:DATE" />
    

    Suggestions? The full report is appended below.

    <PGVReport access="PRIV_PUBLIC" icon="cfamily">
        <PGVRTitle><PGVRvar var="pgv_lang[Convict_Ancestors]" /></PGVRTitle>
        <PGVRDescription>Prints a list of convicts related to a specific person - patch for multiple OCCU</PGVRDescription>
        <PGVRInput name="pid" lookup="INDI" type="text"><PGVRvar var="pgv_lang[enter_pid]" /></PGVRInput>
        <PGVRInput name="relatives" type="select" options="direct-ancestors,ancestors,all"><PGVRvar var="pgv_lang[choose_relatives]" /></PGVRInput>
        <PGVRInput name="sortby" type="select" options="none,BIRT,DEAT,NAME"><PGVRvar var="pgv_lang[sort_by]" /></PGVRInput>
        <PGVRInput name="pageSize" type="select" options="letter,A4,A3,A5,legal"><PGVRvar var="pgv_lang[page_size]" /></PGVRInput>
        <PGVRStyle name="header" font="dejavusans" size="14" style="b" />
        <PGVRStyle name="pagenum" font="dejavusans" size="8" style="" />
        <PGVRStyle name="text" font="dejavusans" size="9" style="" />
        <PGVRStyle name="label" font="dejavusans" size="9" style="b" />
        <PGVRDoc pageSize="$pageSize" orientation="P" margin="24">
            <PGVRHeader>
                <PGVRCell width="0" height="20" align="center" style="header"><PGVRvar var="pgv_lang[convict_report_header]" /><PGVRGetPersonName id="$pid" /></PGVRCell>
                <PGVRCell width="0" height="10" align="right" style="pagenum"><PGVRvar var="pgv_lang[page]" /> <PGVRPageNum /> <PGVRvar var="pgv_lang[of]" /> <PGVRTotalPages /></PGVRCell>
                <PGVRTextBox width="35" height="12" border="1">
                    <PGVRText style="label"> </PGVRText>
                </PGVRTextBox>
                <PGVRTextBox width="160" height="12" border="1">
                    <PGVRText style="label"><PGVRvar var="pgv_lang[name]" /></PGVRText>
                </PGVRTextBox>
                <PGVRTextBox width="170" height="12" border="1">
                    <PGVRText style="label"><PGVRvar var="factarray[BIRT]" /></PGVRText>
                </PGVRTextBox>
                <PGVRTextBox width="0" height="12" border="1" newline="1">
                    <PGVRText style="label"><PGVRvar var="factarray[DEAT]" /></PGVRText>
                </PGVRTextBox>
            </PGVRHeader>
            <PGVRBody>
                <PGVRRelatives id="$pid" group="$relatives" sortby="$sortby" maxgen="*">
                    <PGVRSetVar name="thePerson" value="@ID" />
                    <PGVRSetVar name="theBirthDate" value="@BIRT:DATE" />
    
                    <PGVRRepeatTag tag="OCCU">
    
                        <PGVRif condition="@OCCU=='Convict'" >
    
                            <PGVRTextBox width="35" height="12" border="0">
                                <PGVRText style="text"><PGVRvar var="thePerson" /></PGVRText>
                            </PGVRTextBox>
                            <PGVRTextBox width="160" height="12" border="0">
                                <PGVRText style="text"><PGVRGetPersonName id="$thePerson" /></PGVRText>
                            </PGVRTextBox>
                            <PGVRTextBox width="170" height="12" border="0">
                                <PGVRText style="text"><PGVRvar var="theBirthDate" /> </PGVRText>
                            </PGVRTextBox>
                            <PGVRTextBox width="0" height="12" border="0" newline="1">
                                <PGVRText style="text"><PGVRGedcomValue tag="DEAT:DATE" />  <PGVRGedcomValue tag="DEAT:PLAC" /></PGVRText>
                            </PGVRTextBox>
                            <PGVRLine x1="25" x2="575" />
    
                        </PGVRif>
                    </PGVRRepeatTag>
                </PGVRRelatives>
            </PGVRBody>
            <PGVRFooter>
                <PGVRCell width="0" height="10"><PGVRNow /></PGVRCell>
            </PGVRFooter>
        </PGVRDoc>
    </PGVReport>
    
     
  • Kerry Choy

    Kerry Choy - 2010-06-09

    OK - answered my own question with a different approach.

     

Log in to post a comment.