Cancelled

Add Functions to VB 2010 .NET Application

# I have a VB 2010 project that has one import function and needs additional functions to import similar comma separated values (CSV) data. The program's purpose is:

1. Read settings from an XML file.

2. Read CSV files from a folder. (The folder location comes from the XML file).

3. Format the CSV data for insertion into a SQL Server table.

4. Insert the data into the SQL table.

5. Move the CSV file to a "Processed" folder.

6. Write a log file to a "Logfiles" folder.

The above steps are functioning for one vendor. There are some differences in the format of the files from other vendors and I need the import function to read and write the formats from other vendors.

**Read the detailed description before bidding.**

## Deliverables

# Requirements

I have a VB 2010 project that has one import function and needs additional functions to import similar comma separated values (CSV) data. The program's purpose is:

1. Read settings from an XML file.

2. Read CSV files from a folder. (The folder location comes from the XML file).

3. Format the CSV data for insertion into a SQL Server table.

4. Insert the data into the SQL table.

5. Move the CSV file to a "Processed" folder.

6. Write a log file to a "Logfiles" folder.

The above steps are functioning for one vendor. There are some differences in the format of the files from other vendors and I need the import function to read and write the formats from other vendors.

The current program is set to run as a scheduled task in Windows Scheduled Tasks and has no user interface.

**Requirements of this project**:

1. You will need to add functions to the existing VB 2010 project.

2. Most functions will be minor changes from the current function to adjust for different fields or formatting.

3. You will need to add new settings in the XML file for the new vendors.

**Specific functions**

1. Function FMS: One new field has been added to the CSV file for the currently working function. You will need to add support for this one new field.

2. Each of the following will need a new function which will be a variation of the existing function to read in the slight differences between the vendor CSV files:

a. Function Orilley

b. Function Merle

c. Function AutoZone

3. Function PA: One vendor provides us with a PHP script to download a JSON formatted file. This will require a new function to perform the following:

a. Convert the PHP into VB code

b. Add username and password values to the XML configuration file and read them into this function in order to access the data.

c. Pass in the (current date -1) to get transactions from the previous day.

d. Retrieve the data provided in JSON format and either convert it to CSV and then import it into the SQL database or directly convert the JSON data into the SQL database.

**Deliverables**

1. Source code in a Visual Basic 2010 project

2. Compiled executable.

Items Provided

1. Current Visual Basic 2010 project files with all the source code.

2. SQL script to create the SQL table where program inserts the CSV data.

3. Sample CSV files from each vendor.

4. PHP code for PA vendor.

# Appendix A

Below are the instructions for the current vendor import program.

## Vendor Import Instructions

#### Description

The vendor import application runs without an interface. All setting necessary for the application to run are specified in the [url removed, login to view] file. They are described below.

#### Configuration Settings

There are two configuration settings that need to be specified for the application to run.

connectionStrings/[url removed, login to view]

Specifies the connection to the database containing the tblAPFilePending table.

For example.

connectionString="Data Source=*localhost*;Initial Catalog=*dbName*;Integrated Security=True"

will connect to the database server on localhost and use the database dbName.

#### appSettings/FMP-BaseDir

This setting specifies the folder in which to look for FMP files. The path to the folder can be absolute or relative.

For example

Will cause the application to look for files in the folder c:\inbound\MP-IN

Or

Will cause the application to look for files in a sub folder of whichever folder the app is running in called MP-IN. ie. If the app was installed into C:\program files\VendorImport the application would look for files in C:\program files\VendorImport\MP-IN.

The application will automatically create the following sub folders under this base director

* Archived : Summary files will be moved into this directory.

* Processed : Detail files will be moved into this directory after they have been processed.

* LogFiles : Log files will be created in this folder.

## Application Operation

When run the application will :

1) Write a 'Processing Begins' message to a log in Logfiles

2) Iterate through each file in log files.

3) Examine the file name, if it contains Summary it will be moved into Archive

4) Otherwise it will be processed as below

5) Each row is read from the file

6) The row is checked for duplicates against data in the tblAPFilePending table and records already read from the file.

7) If a duplicate is found the details are logged to the file in LogFiles

8) If no duplicate is found the details are queued for insertion

9) Once all rows have been read, all valid rows are inserted into the database.

10) Application exits

# Appendix B

PHP File for Function PA

require_once('[url removed, login to view]');

$nw = new invoiceReport();

$nw->setUser(UserName,'Password');

$nw->setAction('getInvoiceInRange');//only supported function

$nw->setStartDate('20121001');//start date

$nw->setEndDate('20121005');//end date

print_r($nw->sendRequest());//send request and get response in json format

?>

Class ([url removed, login to view]):

class invoiceReport{

function invoiceReport(){}

function setUser($userName,$password){$this->userName=$userName;$this->password=$password;}

function setAction($x){$this->action=$x;}

function setStartDate($x){$this->startDate=$x;}

function setEndDate($x){$this->endDate=$x;}

function sendRequest()

{

$req = array(

'userName'=>$this->userName,

'userPass'=>$this->password,

'action'=>$this->action,

'startDate'=>$this->startDate,

'endDate'=>$this->endDate

);

$handle = fopen("[url removed, login to view]".urlencode(json_encode($req)), "r");

$contents='';

while (!feof($handle)) {$contents .= fread($handle, 8192);}

fclose($handle);

return $contents;

}

}

?>

Skills: Anything Goes

See more: windows action script, visual basic x, visual basic net array, vb net array example, vb net array, sql server get windows username, sql get duplicates, return path, psp create, my day application, functions in vb.net with example, function in vb.net example, function - 1 to 1, create psp, convert php to vb.net, convert php code to vb.net, autozone com, autozone, array program in vb.net, array in vb.net with example

About the Employer:
( 0 reviews ) United States

Project ID: #2784024

3 freelancers are bidding on average $84 for this job

joserarodrigues

See private message.

$85 USD in 7 days
(3 Reviews)
3.8
feninsoftech

See private message.

$80.75 USD in 7 days
(0 Reviews)
0.0
devmstech

See private message.

$85 USD in 7 days
(0 Reviews)
0.0