Streets entry |
Top Previous Next |
Note: At the time of this writing, the program did not support adding update locations. This set of instructions assumes this is still the case. If the data entry definition contains a button to add an update location, please use that method instead.
Before beginning, you will need the name of the streets table and the field names to refer to.
1.Under .config, create the psrattr Data Entry Definition. Name it Streets. 2.Go to the .xml tab and paste this in: <pdroot> <DataEntryDefinition> <General> <AsLoadedChecksum>0</AsLoadedChecksum> <Notes/> <ValidationRules></ValidationRules> </General> <UpdateLocs> <UpdateLoc> <Name>Main</Name> <TABLENAME>DBO.STREETS</TABLENAME> <Connection>Writer</Connection> <LoadedCount>0</LoadedCount> <DoWrite>False</DoWrite> <DoWriteExpression>true</DoWriteExpression> <UniqueFields> <EntryField> <Name>StreetNum</Name> <XPos>0</XPos> <YPos>0</YPos> <Width>100</Width> <EntryWidth>0</EntryWidth> <ValuePos>None</ValuePos> <HAnchor>Left</HAnchor> <JustifyLabel>False</JustifyLabel> <LabelPos>Left</LabelPos> <ValueWidth>300</ValueWidth> <ContentMax>2147483647</ContentMax> <ContentMin>-2147483646</ContentMin> <UpdateLocName>Main</UpdateLocName> <FieldName>StreetNum</FieldName> <FieldType>Integer</FieldType> <PromptType>WholeNumber</PromptType> <PromptText>Street Number:</PromptText> <DBValue/> <Visible>True</Visible> <OnlyRead>False</OnlyRead> <Default/> <Expression/> <CustomProperties> <Property Name="IntersectionNormalizer"> <Value>Default</Value> </Property> </CustomProperties> </EntryField> </UniqueFields> </UpdateLoc> </UpdateLocs> <EntryFields> <EntryField> <Name>LabelStreetNum</Name> <XPos>0</XPos> <YPos>0</YPos> <Width>50</Width> <EntryWidth>0</EntryWidth> <ValuePos>Right</ValuePos> <HAnchor>Left</HAnchor> <JustifyLabel>False</JustifyLabel> <LabelPos>Left</LabelPos> <ValueWidth>300</ValueWidth> <ContentMax>2147483647</ContentMax> <ContentMin>-2147483646</ContentMin> <UpdateLocName>Main</UpdateLocName> <FieldName>StreetNum</FieldName> <FieldType>Integer</FieldType> <PromptType>Label</PromptType> <PromptText>Street Number:</PromptText> <DBValue/> <Visible>True</Visible> <OnlyRead>True</OnlyRead> <Default/> <Expression/> <CustomProperties/> </EntryField> <EntryField> <Name>StreetName</Name> <XPos>0</XPos> <YPos>0</YPos> <Width>100</Width> <EntryWidth>0</EntryWidth> <ValuePos>None</ValuePos> <HAnchor>Left</HAnchor> <JustifyLabel>False</JustifyLabel> <LabelPos>Left</LabelPos> <ValueWidth>300</ValueWidth> <ContentMax>50</ContentMax> <ContentMin>0</ContentMin> <UpdateLocName>Main</UpdateLocName> <FieldName>StreetName</FieldName> <FieldType>String</FieldType> <PromptType>String</PromptType> <PromptText>Street Name:</PromptText> <DBValue/> <Visible>True</Visible> <OnlyRead>False</OnlyRead> <Default/> <Expression/> <CustomProperties/> </EntryField> </EntryFields> </DataEntryDefinition> </pdroot> 3.Change the table name at the top (highlighted in yellow) to match the table name in the database. DO THIS BEFORE SAVING OR CLICKING ON THE TREE. 4.Then check the field names to make sure they match what’s in the database (also highlighted in yellow). 5.You’re done, unless you need another unique field qualifier, like city or county. Then go to the next step. 6.Copy another Data Entry section below, under the Unique Fields section at the top (after Street Num): <EntryField> <Name>CountyCode</Name> <XPos>0</XPos> <YPos>0</YPos> <Width>50</Width> <EntryWidth>0</EntryWidth> <ValuePos>Right</ValuePos> <HAnchor>Left</HAnchor> <JustifyLabel>False</JustifyLabel> <LabelPos>Left</LabelPos> <ValueWidth>50</ValueWidth> <ContentMax>2</ContentMax> <ContentMin>0</ContentMin> <UpdateLocName>Main</UpdateLocName> <FieldName>CNTY_CDE</FieldName> <FieldType>WideString</FieldType> <PromptType>Lookup</PromptType> <PromptText>CountyCode:</PromptText> <DBValue/> <Visible>True</Visible> <OnlyRead>False</OnlyRead> <Default/> <Expression/> <CustomProperties> <Property Name="Lookups"> <Value>CNTY</Value> </Property> <Property Name="LookupFormat"> <Value>Value+Lookup</Value> </Property> <Property Name="LookupSort"> <Value>NumberValue</Value> </Property> </CustomProperties> </EntryField> 7.Edit the field names highlighted in yellow above to match the database for the street qualifier field. |