dxGeneration
dx Generation works in conjunction with LeasePak's Automated Lease Doc (Document Generation, DocGen) module.
Once you have created a DocGen template (such as an invoice or letter template), you can use dxGeneration to schedule
and automate the data merge and print processes. You can print documents directly or save them to a user-specified location.
To get started with dxGeneration, you must first create a DocGen template. Then start the program, and, if this is the first time,
enter the Registration Code. Next, set up the Data Directory in the Options window. Then set up at least one User Profile. Finally,
set up and schedule at least one Task. When a task executes, it will produce the records for each SQL.
The content of the primary key depends on the Document Type. Following are some of the commonly used keys for the different type of documents:
Key | Document Type |
cus_s + grp_s | Customer/Group |
app_s | Application |
lse_s | Lease |
invo_s | Invoice |
les_s | Lessee |
In order to use dxGeneration you will need to own the Automated Lease Doc module.
In order to use dxGeneration a Windows service will be created and installed. Therefore the dxGenService will require Administrator privileges to start and stop the dxGenService.
When first started, the dxGeneration displays configuration utility. Once setup is complete, clicking on
User Profiles,
Tasks, or
Scheduled Tasks
will display existing users, tasks, or scheduled tasks, respectively. You can determine
which list the configuration utility is showing by the icon displayed immediately below the File menu in the upper left corner.

From the list of users, tasks, or scheduled tasks, select a list item by clicking on it. You can then click
to make changes to the item's setup or click
to delete the item.
User Profile Field Descriptions

- Profile
- The name of the user profile
- Description
- The item description as defined in its setup.
- UserName
- The user name login that would be used to login to the LeasePak client.
- Environment
- The LeasePak environment to use.
- Server
- The LeasePak application server domain name/IP Address
Tasks Field Descriptions

- Task Name
- The name of the task as defined in its setup.
- Description
- The item description as defined in its setup.
- Profile
- The user profile that is used by the task.
- Doc Template
- The document template to be used with in conjunction with this task.
Schedule Tasks Field Descriptions

- Event(Task) Name
- The name of the item--user, task, or scheduled task--as defined in its setup.
- Description
- The item description as defined in its setup.
- Schedule
- For scheduled tasks, the frequency scheduled for the task run.
- Next Run Time
- For scheduled tasks, the next time (in the future) the task is scheduled to run.
Before completing any other setups or running tasks, you must first provide a location for the Data Directory on the Settings
screen. To access the Settings screen, select Tools, Settings from the menu or click
.

Type the setup information and click OK to save or Cancel to abandon changes.
Field Descriptions
- Polling Interval (secs)
- Type a time interval in seconds or use
to increase or
decrease the number of seconds displayed. The Polling Interval determines how often dxGeneration checks to see if a task is
scheduled to run.
- Halt document generation
- Check this box to suspend the processing of all future tasks. This will not stop tasks that are already running. You must
use the Windows Services to stop the document generation service: dxGenService.
- Data Directory
- Type the full path and directory or click
to browse. dxGeneration uses this
directory for internal setup files, including user profile, task, and scheduled task setups.
Create one or more users to log on the LeasePak database and perform queries of the data. You can define
multiple User Profiles to allow different tasks to run on different databases and environments
(for example, Test and Production environments). After typing the information for the user, click OK to save or Cancel to
abandon changes.
Profile Tab

Field Descriptions
- Profile
- Type the User Profile (user) name. This field allows up to 12 alphanumeric characters.
- Description
- Type the User Profile description. This field allows up to 36 alphanumeric characters.
Server Tab

Field Descriptions
- Username
- Type the user's LeasePak client user name.
- Password
- Type the user's LeasePak client string password. Characters typed in this field appear as asterisks. For more information on
LeasePak users and passwords, refer to LeasePak and mPower Users in the System Administration Guide.
- IP Address or Name
- Type the LeasePak server (computer) name or IP address.
- Environment Name
- Type the name of the LeasePak environment to use.
- Server Port
- Type the TCP port number for the appropriate LeasePak service.
Create one or more tasks specifying data and templates to be merged into finished documents. After typing in the task information,
click OK to save or Cancel to abandon changes.
Task Info Tab

Field Descriptions
- Task
- Type the name of the task.
- Last Run Date
- If the task is scheduled and has been previously run, the last run date will appear here.
- Description
- Type a short description of the task.
- User Profile
- Click
to select a valid user for the task.
Tasks require user profile information to connect to the LeasePak database.
- Connect/Disconnect
- Click Connect to connect to the LeasePak database. You will need to connect to the database in order to access the Custom
SQL tab. Click Disconnect to disconnect from the database.
- Doc ID
- Template to use for creating the document for this task. Select from the dropdown list. This field will be populated by the document IDs created by U0736 Document update of LeasePak.
- Copy to Print
- This field determines whether the generated document is to be copied to a print directory for printing later.
- File Attachment
- This field determines whether to copy the generated document into the File Attachment directory as defined in U0712 Custom General->Document Generation Customizations update. Selection of this box creates a file attachment link for use with the File Attachment module if the document contains either an application or a lease.
- Output Directory
- Directory for merged documents. Type the full path or click
to browse.
- Print Directory
- Directory for the documents to print if "Copy to Print" checkbox is selected. Set the location of this field directory different from the Output Directory. Type the full path and file name or click
to browse.
The files in this directory must be removed after the documents have been printed from the print directory. Existence of the files in this folder consumes storage space.
- Log Directory
- Directory for log files. Type the full path or click
to browse.
ChannelIT users: provide a location for this directory.
Settings Tab

Field Descriptions
- Process Task on Save
- Check this box and click OK to immediately run the task. Useful for testing newly defined or updated tasks.

Field Descriptions
- SQL Statement
- Type an SQL statement specifying which LeasePak database records the task will process. Use one of the
primary keys listed in the Introduction section above as the basis for the record selection. dx
Generation will run the task on each record returned by the query. For more information on using SQL with dx Generation, contact your NetSol representative.
- Special SQL Reserved Words
- Listed below are some resevered words that can be included in your SQL to perform various tasks:
- LAST_RUN_DATE - This value represents the last run date the task was processed. If this task has not been processed yet, then it will use yesterday's date.
For example: Get all of the leases that have been booked since the last date that this task was performed on:- select lse_s from rls where d_boo_s < LAST_RUN_DATE
- Process Now
- Click on this button to process documents.
You can create periodic schedules for defined tasks. Tasks can be set to run once, one or more times weekly, or on a certain day of
one or more months each year. For each schedule you will need to complete the following fields:
- Event
- Type a name for the scheduled task.
- Type a description for the scheduled task.
- Task
- Type the name of the task to run or click
for a list of valid defined tasks.
- Task set to run
- Check this to schedule the task to run at the set time. Uncheck this (turn it off) if you do not want to run the task. This
option allows you to suspend tasks without losing their setup information.
Interval: One Time
Select the One Time option to schedule the task to run once at a future date or time.

Field Descriptions
- Start Time
- Type a future time or use
to change the time displayed.
- Start Date
- Type today's date, a future date, or use
to change the
date displayed.
Interval: Weekly
Select the Weekly option to schedule the task to run at a certain time one or more days each week. You can set the task to run Monday
through Friday or every day to create a daily task.

Field Descriptions
- Start Time
- Type a time or use
to change the time displayed.
- Select the day(s) of the week below
- Check each day of the week you want the task to run.
Interval: Monthly
Select the Monthly option to schedule the task to run at a certain time on a certain day of one or more months. You can set the task
to run certain months to create an annual, semiannual, quarterly, etc., or monthly task.

Field Descriptions
- Start Time
- Type a time or use
to change the time displayed.
- Day
- Type a day of the month or use
to change the day
displayed.
Setting this field to 31 will not process tasks on the last day
of the month. Instead, NetSol recommends scheduling an end of month task to run very early on the first day of the month.
- Of the month(s)
- Check each month of the year you want the task to run.
Before completing any other setups or running tasks, you must first provide a location for the Data Directory on the Settings
screen. To access the Settings screen, select Tools, Settings from the menu or click
.

Type the setup information and click OK to save or Cancel to abandon changes.
Field Descriptions
- Polling Interval (secs)
- Type a time interval in seconds or use
to increase or
decrease the number of seconds displayed. The Polling Interval determines how often dxGeneration checks to see if a task is
scheduled to run.
- Halt document generation
- Check this box to suspend the processing of all future tasks. This will not stop tasks that are already running. You must
use the Windows Services to stop the dxGenService.
- Data Directory
- Type the full path and directory or click
to browse. dxGeneration uses this
directory for internal setup files, including user profile, task, and scheduled task setups.
To open the Windows Services console, (In older versions this was called Service management console), goto the Windows Start menu and chose the option Run. From this console we can start or stop a service and also set
the service start type to automatic/manual/disabled etc. The run command to open services console is services.msc

Services

Look for the service called dxGenService and then double click the entry to configure the service.
dxGenService Properties

From the dxGenService you can control the run state for creating new documents. This service can be placed in the following run states:
Start, Stop, Pause, or Resume.
In order to determine the current run state of the dxGenService, one can always launch the dxGeneration Configuration Utility and check the run state. The dxGeneration configuration utility will display the current system status of the dxGenService in the lower bottom corner. Here are the three run states:
This state represents that the Halt Document Generation checkbox has been selected in the File/Settings window.
This state represents that the Windows Service: dxGenService is in a stopped state.
This state represents that:
- the Windows Service: dxGenService is in a running state, and . . .
- the Halt Document Generation checkbox is not selected in the File/Settings window.
Currently, dxGeneration uses Microsoft Office automation to aid in the documentation generation via a Windows Service. Microsoft does not recommend or support server-side Automation of Office. Because dxGeneration is dependent on Microsoft, your mileage may vary.
In order to run dxGeneration as a service on Windows Server, all or some of configurations below may or may not be required:
Addtional Directories
The following directories should be present and writable for the account that is going to run dxGenService.
- C:\Windows\System32\config\systemprofile\Desktop
- C:\Windows\SysWOW64\config\systemprofile\Desktop
- C:\Windows\System32\config\systemprofile\AppData\Local\Microsoft\Windows\INetCache
- C:\Windows\SysWOW64\config\systemprofile\AppData\Local\Microsoft\Windows\INetCache
Component Services
In some cases the Microsoft Word 97 - 2003 Document component service needs to be configured in order to use the local account that is going to run dxGenService.
- To open the Component Services console, goto the Windows Start menu and chose the option Run. The run command to open the component services console is dcomcnfg.exe. To launch the component services console, press the OK button.

- The Component Services console, will open as such:

- Traverse the menu tree in the left pane as such: Console Root / Component Services / Computers / My Computer / DCOM Config
- Select the Microsoft 97 - 2003 Document icon in the middle pane. Right-click and choose properties.

- A new screen will appear, (see below), and choose the Identity tab.
- Configure the application to run as "The interactive user." as depicted in the red rectangle then press the OK button.

LeasePak Documentation Suite
©
by NetSol Technologies Inc. All rights reserved.
The information contained
in this document is the property of NetSol Technologies Inc. Use of the information
contained herein is restricted. Conditions of use are subject to change without
notice. NetSol Technologies Inc. assumes no liability for any inaccuracy that may
appear in this document; the contents of this document do not constitute a promise
or warranty. The software described in this document is furnished under license and may be used
or copied only in accordance with the terms of said license. Unauthorized
use, alteration, or reproduction of this document without the written consent
of NetSol Technologies Inc. is prohibited.