SlideShare a Scribd company logo
1 of 60
LISTINGS.txt
345678 116900 0 80513-2918 Metro Brokers
432395 150743 1 80512-2771 City Realty
353455 342522 2 34534-3454 Upper East
999999 99999 2 92130-1312 This Test
555555 555555 0 77777-7777 Final Test
CHANGES.txt
432395 -25000
353455 -2500
221111 -1000
345678 +5000
HodellAssn#6.cpp
//***************************************************
**********************
#include <iostream>
#include <fstream>
#include <string>
#include <iomanip>
#include <cctype>
using namespace std;
// Global structure definition
enum availability { AVAILABLE, CONTRACT, SOLD };
struct propertiesRec
{
int mlsNum;
double price;
availability status;
string zipCode;
string realtor;
};
//FUNCTION PROTOTYPES SECTION -
//Previous Lab#4 functions with linked list mods
void IntroProgram ();
char MenuOne();
char UserMenuChoices ();
void Add_New_Listing ();
int Existing_Listings ();
int Get_Validate_MLS_Input ();
double Get_Validate_Price_Input ();
availability Get_Status_Entry();
string Status_Enum_Text ( int );
string Get_Validate_ZipCode_Input ();
string Get_Validate_Realtor_Input ();
int CountIntegers( int );
void Display_MLS_Numbers ();
bool Does_File_Exist(const char *fileName);
//Class Definition - New Lab#6 Functions
class node
{
propertiesRec Xdata;
node *next;
public:
//Default constructor used to initialize variable with
values
node() { next=0; }
//Constructor with parameters
node ( propertiesRec varibable ) { Xdata = varibable;
next = 0; }
void put_next ( node *n ) { next = n; }
node *Get_Next ( ) { return next; }
int Get_MLS ( ) { return Xdata.mlsNum; }
double Get_AskingPrice ( ) { return Xdata.price; }
int Get_ListingStatus ( ) { return Xdata.status; }
string Get_ZipCode() { return Xdata.zipCode; }
string Get_Realtor() { return Xdata.realtor; }
void SetAskingPrice( double );
void Append_List( propertiesRec );
void Remove_Node();
void DisplayListings();
void WriteToFile();
void ChangeAskingPrice();
//Declaring two nodes: header and 'n' initialized to 0.
} *header=0, *n=0;
//Input data constants
const int MAX_REALTY_NAME = 15;
const int MAX_ZIPCODE = 10;
const char Y_UPPERCASE = 'Y';
const char N_UPPERCASE = 'N';
const char ADD_LISTING = 'A';
const char REMOVE_LISTING = 'R';
const char DISPLAY_ALL = 'D';
const char CHANGE_ASKING_PRICE = 'C';
const char EXIT_PROGRAM = 'E';
//***************************************************
**********************
// FUNCTION: main
// DESCRIPTION: Main function will call various functions to
read, input,
// calculate and display per account the
phone usage totals
// CALLS TO:
// IntroProgram
//***************************************************
**********************
int main() {
// variables
int count;
char additional;
propertiesRec listings;
bool exit=false;
n = new node();
// Begin Program execution
IntroProgram ();
additional = MenuOne();
if (additional == Y_UPPERCASE) {
Existing_Listings();
}
else {
Add_New_Listing ();
}
while( !exit )
{
additional = UserMenuChoices ();
switch ( additional ) {
case DISPLAY_ALL:
if ( header == 0 )
{
cout << "No existing data - Please Add data"
<< endl;
Add_New_Listing ();
} else
{
n->DisplayListings();
}
break;
case ADD_LISTING:
{
Add_New_Listing();
}
break;
case REMOVE_LISTING:
{
n->Remove_Node();
}
break;
case CHANGE_ASKING_PRICE:
{
n->ChangeAskingPrice();
}
break;
case EXIT_PROGRAM:
{
n->WriteToFile();
exit = true;
}
}
}
return 0;
}
//***************************************************
**********************
// FUNCTION: Program Introduction
// DESCRIPTION: Introduce user to Reality Listing Program
// INPUT: None
// OUTPUT: Display a introduction to the user of the
program.
//***************************************************
**********************
void IntroProgram (void)
{
cout << endl;
cout << "Welcome to the Realtor's Association MLS
Listing(s) Program" << endl;
cout << endl;
}
//***************************************************
**********************
// FUNCTION: Menu One
// DESCRIPTION: First menu that the user can use to make a
choice.
// INPUT: User input and error correction
// OUTPUT: Returns an answer to the main function.
//***************************************************
**********************
char MenuOne()
{
char answer;
cout << endl;
cout << "Load existing data from file (Y/N) " << endl;;
cout << "Y - Existing MLS Listing(s)" << endl;
cout << "N - Enter New Listing(s)" << endl;
cout << "Enter choice: ";
do {
cin >> answer;
answer = toupper(answer);
if (answer != Y_UPPERCASE && answer !=
N_UPPERCASE) {
cout << "invalid choice: re-entern";
}
} while (answer != Y_UPPERCASE && answer !=
N_UPPERCASE);
return answer;
}
//***************************************************
**********************
// FUNCTION: Existing Records
// DESCRIPTION: Reads the LISTINGS.txt file into an linked
list
// INPUT: inputFile (LISTINGS.txt) are called for read
from this
// function, if there is no txt and error will
be screened
// and the user can either exit or add new
data to the new
// linked list.
// OUTPUT: A return value countRec records and adds up
the number of
// records read into the array-struct.
//***************************************************
**********************
int Existing_Listings()
{
int availabilityInt;
char userAns;
char filename[20];
cout << "Enter a filename: ";
cin >> filename;
struct propertiesRec listings;
ifstream inputFile(filename);
if (!inputFile)
{
cout<< "INPUT FILE DOES NOT EXISTS." << endl;
}
else
{
while ( !inputFile )
{
cout << "No Existing file data available or Input
file did not open." << endl;
cout << "Would you like to (A)dd new listings
or (E)xit?" << endl;
cin >> userAns;
userAns = toupper (userAns);
if ( userAns == 'A' )
{
Add_New_Listing();
return 0;
}
if ( userAns == 'E' )
{
return 1;
}
}
while ( inputFile >> listings.mlsNum )
{
inputFile >> listings.price
>> availabilityInt
>> listings.zipCode;
getline ( inputFile, listings.realtor);
listings.status =
static_cast<availability>(availabilityInt);
n->Append_List(listings);
}
}
inputFile.close();
}
//***************************************************
**********************
// FUNCTION: (A)dd Records
// DESCRIPTION: This function takes user input via keyboard
and copies it
// per member into a array-struct record.
// INPUT: Take use input and also countRec (# of actual
records at
// that moment. It also calls verification
functions to verify
// the data being entered.
// OUTPUT: Adds a new record the array-struct and asks if
they would
// like to continue or stop.
//***************************************************
**********************
void Add_New_Listing ()
{
char more;
do
{
propertiesRec listings;
listings.mlsNum = Get_Validate_MLS_Input();
listings.price = Get_Validate_Price_Input();
listings.status = Get_Status_Entry();
listings.zipCode = Get_Validate_ZipCode_Input ();
listings.realtor = Get_Validate_Realtor_Input ();
n->Append_List( listings ); // Appends
the linked list
cout << endl;
cout << "More Listing(s) to add (Y)es or (N)o?";
cin >> more;
} while ( toupper(more) != N_UPPERCASE );
}
//***************************************************
**********************
// FUNCTION: Display Listings
// DESCRIPTION:
// INPUT:
// OUTPUT:
//
//***************************************************
**********************
void node::DisplayListings()
{
// Header Display
cout << setw(15) << "Asking" << setw(11) << "Listing"
<< endl;
cout << "MLS" << setw(11) << "Price" << setw(11) <<
"Status" << setw(13)
<< "zipcode" << setw(13) << "Realtor" << endl;
cout << "------ " <<"------- " << "--------- " << "--------
-- " << "------------ " << endl;
node *q;
for( q=header; q!= 0; q= q->Get_Next() )
{
cout << q->Get_MLS() << setw(10) << q-
>Get_AskingPrice() << setw(12);
string status = Status_Enum_Text ( q-
>Get_ListingStatus() );
if ( q->Get_ListingStatus() == 0 )
{
cout << setw(12) << status;
cout << setw(13) << q->Get_ZipCode();
cout << " " << left << setw(10) << q-
>Get_Realtor() << right << endl;
}
if ( q->Get_ListingStatus() == 1 )
{
cout << setw(11) << status;
cout << setw(14) << q->Get_ZipCode();
cout << " " << left << q->Get_Realtor() << right
<< endl;
}
if ( q->Get_ListingStatus() == 2 )
{
cout << setw(7) << status;
cout << setw(18) << q->Get_ZipCode();
cout << " " << left << q->Get_Realtor() << right
<< endl;
}
}
}
//***************************************************
**********************
// FUNCTION: User Menu Choices
// DESCRIPTION: This is the central user menu where they
can make choices.
// INPUT: This function takes no input, but does error
check what the
// user enters.
// OUTPUT: A menu with all the major takes that this
program can accomplish.
//***************************************************
**********************
char UserMenuChoices ()
{
char answer;
cout << endl;
cout << "User Menu Choices:" << endl;
cout << "------------------" << endl;
cout << "D - Display All" << endl;
cout << "A - Add Listing(s)" << endl;
cout << "R - Remove Listing(s)" << endl;
cout << "C - Change Asking Price" << endl;
cout << "E - Exit Program" << endl;
cout << "Please enter your choice ";
cout << endl;
do {
cin >> answer;
answer = toupper(answer);
if ( answer != DISPLAY_ALL && answer !=
ADD_LISTING &&
answer != REMOVE_LISTING && answer!=
CHANGE_ASKING_PRICE && answer != EXIT_PROGRAM )
{
cout << "invalid choice: re-enter" << endl;
}
} while ( answer != DISPLAY_ALL && answer !=
ADD_LISTING &&
answer != REMOVE_LISTING && answer!=
CHANGE_ASKING_PRICE && answer != EXIT_PROGRAM );
return answer;
}
//***************************************************
**********************
// FUNCTION: Append_List
// DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX
// INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX
// OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX
//***************************************************
**********************
void node::Append_List( propertiesRec Xdata )
{
node *q,*t;
if( header == 0 )
{
header= new node ( Xdata );
}
else
{
q = new node();
q = header;
while( q->Get_Next() !=0 )
{
q = q->Get_Next();
}
t = new node( Xdata );
q->put_next( t );
}
}
//***************************************************
**********************
// FUNCTION: Remove_Node
// DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX
// INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX
// OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX
//***************************************************
**********************
void node::Remove_Node()
{
Display_MLS_Numbers();
int mls;
cout << "Enter MLS to remove: ";
mls = Get_Validate_MLS_Input();
node *q,*r;
q = header;
// If node to be deleted is the first node
if( q->Get_MLS() == mls )
{
header = q->Get_Next();
delete q;
return;
}
//if node to be deleted is not the first node
r = q;
while( q!= 0 )
{
if( q->Get_MLS() == mls )
{
r->next=q->next;
delete q;
return;
}
r = q;
q = q->Get_Next();
}
cout << "MLS number " << mls << " not Found.";
}
//***************************************************
**********************
// FUNCTION: WriteToFile
// DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX
// INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX
// OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX
//***************************************************
**********************
void node::WriteToFile()
{
if ( header == NULL ) // End of list or not populated head
node
{
cout << "No existing data - no data will be saved" <<
endl;
}
char ch;
bool again= true;
cout<<"Do you want to save the listing(y/n): ";
cin>>ch;
ch=toupper( ch );
if ( ch=='Y' )
{
char filename[20];
cout<<"Enter file name to save: ";
cin>>filename;
do
{
if ( Does_File_Exist(filename) ) //if file
already exists
{
cout << "this file already exists. Do you
want to overwrite it (y/n): ";
cin >> ch;
ch = toupper( ch );
if ( ch == 'Y' )
{
ofstream FileOutput;
FileOutput.open( filename );
node *q;
for( q= header; q!= 0; q= q-
>Get_Next() )
{
FileOutput << q->Get_MLS() <<
" " << q->Get_AskingPrice() << " " << q->Get_ListingStatus()
<< " ";
FileOutput << q->Get_ZipCode()
<< " " << q->Get_Realtor() << endl;
}
FileOutput.close();
again=false;
}
else
{
cout << "Enter another file name to
save the listing: ";
cin >> filename;
}
}
else //if file does not exists
{
ofstream FileOutput;
FileOutput.open( filename );
node *q;
//iterate from header to the end of the
linked list
for( q=header; q!= 0; q= q->Get_Next() )
{
FileOutput << q->Get_MLS() << " "
<< q->Get_AskingPrice() << " " << q->Get_ListingStatus() << "
";
FileOutput << q->Get_ZipCode() << "
" << q->Get_Realtor() << endl;
}
FileOutput.close();
again= false;
}
} while( again );
}
}
//***************************************************
**********************
// FUNCTION: SetAskingPrice
// DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX
// INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX
// OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX
//***************************************************
**********************
void node::SetAskingPrice( double newPrice )
{
Xdata.price = newPrice;
}
//***************************************************
**********************
// FUNCTION: ChangeAskingPrice
// DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX
// INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX
// OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX
//***************************************************
**********************
void node::ChangeAskingPrice()
{
ifstream inputFile;
inputFile.open( "CHANGES.TXT" );
if ( !inputFile )
{
cout << "ERROR: File 'Changes.txt' does not exists."
<< endl;
return;
}
int mls;
double price;
node *q;
bool found = false;
cout << "MLS number" << setw(20) << "New Asking
Price" << endl;
cout<<"---------- " << " ----------------" << endl;
while ( inputFile >> mls )
{
inputFile >> price;
for( q= header; q!= 0; q= q->Get_Next() )
{
if ( q->Get_MLS() == mls )
{
found= true;
q->SetAskingPrice( q->Get_AskingPrice()-
price );
cout << mls << setw(14) << q-
>Get_AskingPrice() << endl;
}
}
}
inputFile.close();
if ( found == false )
{
cout << "No matching MLS number found" << endl;
}
}
//***************************************************
**********************
// FUNCTION: Enter MLS listing
// DESCRIPTION: Gets and validates the MLS number from
the user
// INPUT: User input with error correction.
// OUTPUT: Writes data back to add data function.
//***************************************************
**********************
int Get_Validate_MLS_Input ()
{
int MAX_MLS_NUMBER = 6;
int MIN = 100000;
int MAX = 999999;
int mlsNum;
cout << endl;
cout << "Enter MLS number (Between 100000 - 999999)";
cin >> mlsNum;
int numIntegers = CountIntegers( mlsNum );
while (cin.fail())
{
cin.clear();
cin.ignore();
cout << "not integer" << endl;
cin.clear();
cin.ignore();
cin>>mlsNum;
}
numIntegers = CountIntegers( mlsNum );
do {
if ( numIntegers > MAX_MLS_NUMBER )
{
cout << endl;
cout << "Length of MLS too long - Only 6 Digits."
<< endl;
cin >> mlsNum;
numIntegers = CountIntegers( mlsNum );
}
} while ( numIntegers > MAX_MLS_NUMBER ) ;
while (! ( mlsNum > MIN ) || ( mlsNum > MAX ))
{
cout << "Invalid Entry - (Between 100000 -
999999)";
cin.clear();
cin.ignore();
cin>>mlsNum;
}
return mlsNum;
}
//***************************************************
**********************
// FUNCTION: Enter Price
// DESCRIPTION: Gets and validates the price entered by the
user.
// INPUT: User input with error correction.
// OUTPUT: Writes data back to add data function.
//***************************************************
**********************
double Get_Validate_Price_Input ()
{
int MAX_Price_Length = 6;
int MIN = 1;
int MAX = 999999;
int price;
cout << endl;
cout << "Enter Price (Between 1 - 999999)";
cin >> price;
int numIntegers = CountIntegers( price );
while ( cin.fail() )
{
cin.clear();
cin.ignore();
cout << "not integer" << endl;
cin>>price;
}
numIntegers = CountIntegers( price );
do {
if ( numIntegers > MAX_Price_Length )
{
cout << endl;
cout << "Length of Price too long - Only 6
Digits." << endl;
cin >> price;
numIntegers = CountIntegers( price );
}
} while (( numIntegers > MAX_Price_Length ) && (
cin.fail()) );
return price;
}
//***************************************************
**********************
// FUNCTION: Count Number of Integers
// DESCRIPTION: counts the numbers
// INPUT: Enter price function inputs the user data.
// OUTPUT: Returns the actual numbers entered by the user
to the calling
// function.
//***************************************************
**********************
int CountIntegers( int number )
{
if ( number < 10 ) {
return 1;
}
int countInt = 0;
while ( number > 0 )
{
number /= 10;
countInt++;
}
return countInt;
}
//***************************************************
**********************
// FUNCTION: Enter ZipCode
// DESCRIPTION: Gets and validates the zipCode number.
// INPUT: User input with error correction.
// OUTPUT: Writes data back to add data function.
//***************************************************
**********************
string Get_Validate_ZipCode_Input ()
{
string zipCode;
bool valid = true;
do
{
valid = true;
cout << "Enter Zipcode (XXXXX-XXXX)" << endl;
cin >> zipCode;
if ( zipCode.length() <10 || zipCode.length() >
MAX_ZIPCODE )
{
cout << "Invalid ZipCode - Zip code length must
be 10 " << endl;
valid = false;
}
else if ( zipCode[5] != '-' )
{
cout << "Invalid ZipCode - '-' is not at correct
position" << endl;
valid = false;
}
else
{
for ( int counter = 0; counter <= 4; counter++ )
{
if ( !isdigit(zipCode[counter]) )
{
cout << "Invalid ZipCode - all must
be digits" << endl;
valid = false;
}
}
for ( int counter = 6; counter <= 9; counter++ )
{
if ( !isdigit(zipCode[counter]) )
{
cout << "Invalid ZipCode - all must
be digits" << endl;
valid = false;
}
}
}
}while ( valid == false );
return zipCode;
}
//***************************************************
**********************
// FUNCTION: Enter Realty Company Name
// DESCRIPTION: Gets and validates the propertiesRec name
// INPUT: User input with error correction.
// OUTPUT: Writes data back to add data function.
//***************************************************
**********************
string Get_Validate_Realtor_Input ()
{
string propertiesRec;
int counter;
bool valid = true;
do
{
cout << endl;
cout << "Enter propertiesRec Name, only letter(s) and
spaces allowed " << endl;
cin.ignore();
getline( cin, propertiesRec );
if ( propertiesRec.length() >
MAX_REALTY_NAME )
{
cout << "Invalid propertiesRec Name"
<< endl;
getline( cin, propertiesRec );
}
} while ( propertiesRec.length() > MAX_REALTY_NAME
);
// This tests for letters
for ( int counter = 0; counter < propertiesRec.length();
counter++ )
{
if ( !isalpha(propertiesRec[counter]) && valid ==
true )
{
cout << "Invalid propertiesRec Name"
<< endl;
getline( cin, propertiesRec );
}
// This is the first letter Capitializer
for (int counter = 0; counter < propertiesRec.length();
counter++)
{
if ( isalpha(propertiesRec[counter]) &&
valid == true )
{
propertiesRec[counter] = toupper(
propertiesRec[counter] );
valid = false;
}
else if (isspace (
propertiesRec[counter]) )
valid = true;
}
}
return propertiesRec;
}
//***************************************************
**********************
// FUNCTION: Get Status Entry
// DESCRIPTION: Takes user input and enters the status via
switch.
// INPUT: User input with error correction.
// OUTPUT: Outputs the data into the array-struct via add
data function.
//***************************************************
**********************
availability Get_Status_Entry()
{
int entry;
cout << "Enter the listing's status ( 0 - Available; 1 -
Contract, 2 - Sold): ";
while ( !(cin >> entry) || entry < 0 || entry > 2 )
{
cout << "Invalid listing status, please enter 0 -
Available, 1 - Contract, or 2 - Sold." << endl;
cout << "Try again: ";
cout << endl;
}
switch (entry)
{
case 0:
return AVAILABLE;
case 1:
return CONTRACT;
case 2:
return SOLD;
default:
break;
}
}
//***************************************************
**********************
// FUNCTION: Status Enum to Text
// DESCRIPTION: Converts from cell integer to enumuration
for display
// INPUT: Is call by the display all function.
// OUTPUT: Returns the correct converted enumeration
status type.
//***************************************************
**********************
string Status_Enum_Text (int status)
{
switch (status){
case 0:
return "AVAILABLE";
case 1:
return "CONTRACT";
case 2:
return "SOLD";
default:
break;
}
}
//***************************************************
******************
// FUNCTION: Display MLS Numbers
// DESCRIPTION: Displays MLS list from the Linked-list.
Checks first if
// there are any MLS records.
// INPUT: Reads the Linked-list
// OUTPUT: Outputs to screen a header and list of
current MLS#.
//***************************************************
*******************
void Display_MLS_Numbers ()
{
node *q;
if ( header == NULL )
{
cout << "There are no Listings stored." << endl;
}
else
{
cout << "MLS#" << endl;
cout << "------" << endl;
//Work through head node to null node
for( q= header; q!= 0; q= q->Get_Next() )
{
cout << q->Get_MLS() << endl;
}
cout << endl;
}
}
//***************************************************
******************
// FUNCTION: Does_File_Exist
// DESCRIPTION: Performs a check on the existence of the
user inputed
// file name.
// INPUT:
// OUTPUT:
//
//***************************************************
*******************
bool Does_File_Exist ( const char *fileName )
{
ifstream inputFile( fileName );
bool exists = false;
if ( inputFile )
exists= true;
return exists;
}
APA Assignment Instructions
Attached you will find the following sections of a formal paper
written using APA format:
· Title Page
· Abstract
· First two pages of Chapter 1
· Reference List
Unfortunately, this paper contains multiple common formatting
errors. To complete this assignment you must correct the errors
in each of the above sections and return the assignment for
evaluation. Errors include omissions as well as commissions.
For example, when looking at the title page you want to observe
for omission errors by checking to see that all necessary
components have been included and commission errors by
determining whether or not the information that has been
provided is in the right place on the page. If you do not have a
copy of the 6th Edition of the APA Manual, you can use one of
the APA Web sites listed in Module 5.
Please note: This assignment only contains selected sections of
a formal paper. Other required sections (for example, a table of
contents) have been omitted. For the purpose of this assignment,
you only need to address the sections provided. You also do not
have to correct any grammar errors you may find.
Title Page
Writing for Publication
Abstract
Writing for publication is more than opportunity for
professional development. It is a responsibility of all health
care professionals. Unfortunately, many health care
professionals, especially those outside of academia are
unfamiliar with the publication process. The purpose of this
paper is to provide a detailed description of the publication
process from conception of the idea through actual publication.
The topics addressed include finding a publishable idea, finding
the right journal for publication, contacting the editor and
preparing and submitting a manuscript. The paper will also
discuss actual and perceived obstacles to publication.
Chapter 1
Introduction
In this world of evidence based practice, it is becoming more
and more important for health care professionals to share their
clinical successes and their failures. Health care professionals
have a responsibility to themselves, their colleagues and their
patients to read what others are saying, to evaluate the
relevance of what they are reading and to write so that their
successes can be implemented by others. The opportunities to be
published are growing every year. “In the past two decades
there has been a phenomenal rise in the number of peer
reviewed publications, either as paper-print or as online
journals, and this has been in response to the growing demand
for information, research activity and the necessity to apply
empirical findings to the delivery of patient care (Albarran, J. &
Scholes, J. 2005, page 72)”.
For the novice writer, writing for publication can appear to be a
daunting task and many fear that they haven’t the time, skill or
experience to undertake the challenge (Albarren, J., & Scholes,
J. 2005; Doyle,E., et. al., 2004). However, writing for
publication is not the “Mount Everest” most fear and the
process is one that can be learned. Although writing requires a
commitment, it is a doable task that can be enjoyable and
rewarding.
GETTING STARTED
Making the decision to try your hand at publication is the first
hurdle. Once the decision has been made, an idea needs to be
formulated and a work plan established. When choosing a topic,
experts agree that you should begin by writing about a topic that
you know well (Cook, R. 2000). “Ideas for a journal article are
everywhere. Start with your area of practice. Think about the
type of work you do, the types of clients you work with and the
things you do well. For example, if your colleagues always ask
for your advice on how to handle a particular situation, maybe
you want to write about it. If your unit is known for the work it
does with a particular type of patient, you may have publishable
information to share (US Department of the Health Professions,
pages 22-23). First time writers sometimes choose to write with
another person. Even if you want to write alone, it may help to
brainstorm with a colleague to come up with some ideas to
consider.
Albarran and Scholes (2006) suggest that before you go too far
down the path, you think about the type of journal, magazine or
newsletter you want to publish in. The information you will
provide and your writing style will vary depending upon the
audience. In addition, you will want to review recent issues of
the publications to see what topics have been covered over the
past year. You may not be able to get an article published if a
similar topic was recently covered. In addition, by looking
through publications you may find a call for articles on a
particular topic for a special focused edition of the publication.
Once you think you have found the right publication, it is
important that you check with the editor (Griffin-Sobel, J.
1999). By providing a brief description an editor can tell you if
there is interest in the topic and may be able to provide further
direction that will result in an acceptance of your manuscript.
Writing takes time and commitment and it is easy to put the
manuscript away and never pick it up again. Therefore, once
you have made a commitment to write an article, prepare a work
plan and timeline for yourself. This simple strategy will greatly
improve the likelihood of your success. In addition to
establishing deadlines, you should think about and plan for
when and where you will write and where you will find the
resources you will need to write the article. For example, you
may need to include a reference list or pictures. Pick a place
and time where you can write undisturbed. Make sure your
timelines is consistent with any deadlines you may receive from
the editor…a manuscript that is late, may not get published.
References
Albarran, John W., & Scholes, Julie (2005). How to Get
Published: Seven Easy Steps. British Association of Critical
Care, Nursing in Critical Care, 10(2), 72-77.
Cook, Ralph. (2000). The Writers Manual, Oxford: Radcliff
Medical Press
Doyle, Eva J, Coggins, Claudia, & Lanning, Beth (2004).
Writing for Publication in Health Education. American Journal
of Health Studies, 19(2), 100-109.
Duncan, Sarah Smith. Writing for Publication. (Retrieved from
the World Wide Web 10/27/06 at
http://www.library.jhu.edu/researchhelp/general/publishing.html
)
Griffin-Sobel, Joyce (1999). Writing for Publication, Clinical
Journal of Oncology Nursing, 9(1).
Sheriden Libraries. Writing for Publication: Tools for Getting
Started. (Retrieved from the World Wide Web 10/27/06, at
http://www.library.jhu.edu/researchhelp/general/publishing.html
)
St. James, Deborah (2001). Writing, Speaking &
Communication Skills for Health Professionals. New Haven:
Yale University Press.
US Department of the Health Professions, (2002). Washington
DC, Professional Development: Writing for Publication.
(Publication Number DHP365-Y)
PAGE
1

More Related Content

Similar to LISTINGS.txt345678 116900 0 80513-2918 Metro Brokers432395.docx

#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(c#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(cSilvaGraf83
 
#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(c#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(cSilvaGraf83
 
DATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDY
DATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDYDATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDY
DATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDYMalikireddy Bramhananda Reddy
 
Part APurposeThis laboratory provides some experience work.docx
Part APurposeThis laboratory provides some experience work.docxPart APurposeThis laboratory provides some experience work.docx
Part APurposeThis laboratory provides some experience work.docxdewhirstichabod
 
Program(Output)
Program(Output)Program(Output)
Program(Output)princy75
 
C++ Lambda and concurrency
C++ Lambda and concurrencyC++ Lambda and concurrency
C++ Lambda and concurrency명신 김
 
Higher-Order Components — Ilya Gelman
Higher-Order Components — Ilya GelmanHigher-Order Components — Ilya Gelman
Higher-Order Components — Ilya Gelman500Tech
 
RightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docx
RightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docxRightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docx
RightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docxjoellemurphey
 
Code Generation in PHP - PHPConf 2015
Code Generation in PHP - PHPConf 2015Code Generation in PHP - PHPConf 2015
Code Generation in PHP - PHPConf 2015Lin Yo-An
 
ch5_additional.ppt
ch5_additional.pptch5_additional.ppt
ch5_additional.pptLokeshK66
 
in this assignment you are asked to write a simple driver program an.pdf
in this assignment you are asked to write a simple driver program an.pdfin this assignment you are asked to write a simple driver program an.pdf
in this assignment you are asked to write a simple driver program an.pdfmichardsonkhaicarr37
 
package algs13;import stdlib.;import java.util.Iterator;im.docx
package algs13;import  stdlib.;import java.util.Iterator;im.docxpackage algs13;import  stdlib.;import java.util.Iterator;im.docx
package algs13;import stdlib.;import java.util.Iterator;im.docxgerardkortney
 
how to reuse code
how to reuse codehow to reuse code
how to reuse codejleed1
 
#include stdio.h#include stdint.h#include stdbool.h.docx
#include stdio.h#include stdint.h#include stdbool.h.docx#include stdio.h#include stdint.h#include stdbool.h.docx
#include stdio.h#include stdint.h#include stdbool.h.docxAASTHA76
 
Project fast food automaton
Project fast food automatonProject fast food automaton
Project fast food automatonvarun arora
 

Similar to LISTINGS.txt345678 116900 0 80513-2918 Metro Brokers432395.docx (20)

#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(c#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(c
 
#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(c#include Status.hnamespace sdds{StatusStatus(c
#include Status.hnamespace sdds{StatusStatus(c
 
C# labprograms
C# labprogramsC# labprograms
C# labprograms
 
DATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDY
DATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDYDATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDY
DATASTRUCTURES PPTS PREPARED BY M V BRAHMANANDA REDDY
 
Penjualan swalayan
Penjualan swalayanPenjualan swalayan
Penjualan swalayan
 
Part APurposeThis laboratory provides some experience work.docx
Part APurposeThis laboratory provides some experience work.docxPart APurposeThis laboratory provides some experience work.docx
Part APurposeThis laboratory provides some experience work.docx
 
Program(Output)
Program(Output)Program(Output)
Program(Output)
 
C++ Lambda and concurrency
C++ Lambda and concurrencyC++ Lambda and concurrency
C++ Lambda and concurrency
 
Higher-Order Components — Ilya Gelman
Higher-Order Components — Ilya GelmanHigher-Order Components — Ilya Gelman
Higher-Order Components — Ilya Gelman
 
week-16x
week-16xweek-16x
week-16x
 
RightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docx
RightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docxRightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docx
RightTrianglerightTriangle.cppRightTrianglerightTriangle.cpp.docx
 
Code Generation in PHP - PHPConf 2015
Code Generation in PHP - PHPConf 2015Code Generation in PHP - PHPConf 2015
Code Generation in PHP - PHPConf 2015
 
ch5_additional.ppt
ch5_additional.pptch5_additional.ppt
ch5_additional.ppt
 
DataTypes.ppt
DataTypes.pptDataTypes.ppt
DataTypes.ppt
 
in this assignment you are asked to write a simple driver program an.pdf
in this assignment you are asked to write a simple driver program an.pdfin this assignment you are asked to write a simple driver program an.pdf
in this assignment you are asked to write a simple driver program an.pdf
 
package algs13;import stdlib.;import java.util.Iterator;im.docx
package algs13;import  stdlib.;import java.util.Iterator;im.docxpackage algs13;import  stdlib.;import java.util.Iterator;im.docx
package algs13;import stdlib.;import java.util.Iterator;im.docx
 
Linked lists
Linked listsLinked lists
Linked lists
 
how to reuse code
how to reuse codehow to reuse code
how to reuse code
 
#include stdio.h#include stdint.h#include stdbool.h.docx
#include stdio.h#include stdint.h#include stdbool.h.docx#include stdio.h#include stdint.h#include stdbool.h.docx
#include stdio.h#include stdint.h#include stdbool.h.docx
 
Project fast food automaton
Project fast food automatonProject fast food automaton
Project fast food automaton
 

More from SHIVA101531

Answer the following questions in a minimum of 1-2 paragraphs ea.docx
Answer the following questions in a minimum of 1-2 paragraphs ea.docxAnswer the following questions in a minimum of 1-2 paragraphs ea.docx
Answer the following questions in a minimum of 1-2 paragraphs ea.docxSHIVA101531
 
Answer the following questions using scholarly sources as references.docx
Answer the following questions using scholarly sources as references.docxAnswer the following questions using scholarly sources as references.docx
Answer the following questions using scholarly sources as references.docxSHIVA101531
 
Answer the following questions about this case studyClient .docx
Answer the following questions about this case studyClient .docxAnswer the following questions about this case studyClient .docx
Answer the following questions about this case studyClient .docxSHIVA101531
 
Answer the following questions using art vocabulary and ideas from L.docx
Answer the following questions using art vocabulary and ideas from L.docxAnswer the following questions using art vocabulary and ideas from L.docx
Answer the following questions using art vocabulary and ideas from L.docxSHIVA101531
 
Answer the following questions in a total of 3 pages (900 words). My.docx
Answer the following questions in a total of 3 pages (900 words). My.docxAnswer the following questions in a total of 3 pages (900 words). My.docx
Answer the following questions in a total of 3 pages (900 words). My.docxSHIVA101531
 
Answer the following questions No single word responses (at lea.docx
Answer the following questions No single word responses (at lea.docxAnswer the following questions No single word responses (at lea.docx
Answer the following questions No single word responses (at lea.docxSHIVA101531
 
Answer the following questions based on the ethnography Dancing Skel.docx
Answer the following questions based on the ethnography Dancing Skel.docxAnswer the following questions based on the ethnography Dancing Skel.docx
Answer the following questions based on the ethnography Dancing Skel.docxSHIVA101531
 
Answer the following questions to the best of your ability1) De.docx
Answer the following questions to the best of your ability1) De.docxAnswer the following questions to the best of your ability1) De.docx
Answer the following questions to the best of your ability1) De.docxSHIVA101531
 
Answer the following questionDo you think it is necessary to .docx
Answer the following questionDo you think it is necessary to .docxAnswer the following questionDo you think it is necessary to .docx
Answer the following questionDo you think it is necessary to .docxSHIVA101531
 
Answer the following question. Use facts and examples to support.docx
Answer the following question. Use facts and examples to support.docxAnswer the following question. Use facts and examples to support.docx
Answer the following question. Use facts and examples to support.docxSHIVA101531
 
Answer the bottom questions  in apa format and decent answer no shor.docx
Answer the bottom questions  in apa format and decent answer no shor.docxAnswer the bottom questions  in apa format and decent answer no shor.docx
Answer the bottom questions  in apa format and decent answer no shor.docxSHIVA101531
 
Answer the following below using the EXCEL attachment. chapter 5.docx
Answer the following below using the EXCEL attachment. chapter 5.docxAnswer the following below using the EXCEL attachment. chapter 5.docx
Answer the following below using the EXCEL attachment. chapter 5.docxSHIVA101531
 
Answer the following prompts about A Germanic People Create a Code .docx
Answer the following prompts about A Germanic People Create a Code .docxAnswer the following prompts about A Germanic People Create a Code .docx
Answer the following prompts about A Germanic People Create a Code .docxSHIVA101531
 
Answer the following discussion board question below minumun 25.docx
Answer the following discussion board question below minumun 25.docxAnswer the following discussion board question below minumun 25.docx
Answer the following discussion board question below minumun 25.docxSHIVA101531
 
Answer the following questions about IT Project Management. What.docx
Answer the following questions about IT Project Management. What.docxAnswer the following questions about IT Project Management. What.docx
Answer the following questions about IT Project Management. What.docxSHIVA101531
 
Answer the following in at least 100 words minimum each1.Of.docx
Answer the following in at least 100 words minimum each1.Of.docxAnswer the following in at least 100 words minimum each1.Of.docx
Answer the following in at least 100 words minimum each1.Of.docxSHIVA101531
 
Answer the following questions(at least 200 words) and responses 2 p.docx
Answer the following questions(at least 200 words) and responses 2 p.docxAnswer the following questions(at least 200 words) and responses 2 p.docx
Answer the following questions(at least 200 words) and responses 2 p.docxSHIVA101531
 
Answer the following questions in a Word document and upload it by M.docx
Answer the following questions in a Word document and upload it by M.docxAnswer the following questions in a Word document and upload it by M.docx
Answer the following questions in a Word document and upload it by M.docxSHIVA101531
 
Answer the following questions in complete sentences. Each answer sh.docx
Answer the following questions in complete sentences. Each answer sh.docxAnswer the following questions in complete sentences. Each answer sh.docx
Answer the following questions in complete sentences. Each answer sh.docxSHIVA101531
 
ANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docx
ANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docxANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docx
ANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docxSHIVA101531
 

More from SHIVA101531 (20)

Answer the following questions in a minimum of 1-2 paragraphs ea.docx
Answer the following questions in a minimum of 1-2 paragraphs ea.docxAnswer the following questions in a minimum of 1-2 paragraphs ea.docx
Answer the following questions in a minimum of 1-2 paragraphs ea.docx
 
Answer the following questions using scholarly sources as references.docx
Answer the following questions using scholarly sources as references.docxAnswer the following questions using scholarly sources as references.docx
Answer the following questions using scholarly sources as references.docx
 
Answer the following questions about this case studyClient .docx
Answer the following questions about this case studyClient .docxAnswer the following questions about this case studyClient .docx
Answer the following questions about this case studyClient .docx
 
Answer the following questions using art vocabulary and ideas from L.docx
Answer the following questions using art vocabulary and ideas from L.docxAnswer the following questions using art vocabulary and ideas from L.docx
Answer the following questions using art vocabulary and ideas from L.docx
 
Answer the following questions in a total of 3 pages (900 words). My.docx
Answer the following questions in a total of 3 pages (900 words). My.docxAnswer the following questions in a total of 3 pages (900 words). My.docx
Answer the following questions in a total of 3 pages (900 words). My.docx
 
Answer the following questions No single word responses (at lea.docx
Answer the following questions No single word responses (at lea.docxAnswer the following questions No single word responses (at lea.docx
Answer the following questions No single word responses (at lea.docx
 
Answer the following questions based on the ethnography Dancing Skel.docx
Answer the following questions based on the ethnography Dancing Skel.docxAnswer the following questions based on the ethnography Dancing Skel.docx
Answer the following questions based on the ethnography Dancing Skel.docx
 
Answer the following questions to the best of your ability1) De.docx
Answer the following questions to the best of your ability1) De.docxAnswer the following questions to the best of your ability1) De.docx
Answer the following questions to the best of your ability1) De.docx
 
Answer the following questionDo you think it is necessary to .docx
Answer the following questionDo you think it is necessary to .docxAnswer the following questionDo you think it is necessary to .docx
Answer the following questionDo you think it is necessary to .docx
 
Answer the following question. Use facts and examples to support.docx
Answer the following question. Use facts and examples to support.docxAnswer the following question. Use facts and examples to support.docx
Answer the following question. Use facts and examples to support.docx
 
Answer the bottom questions  in apa format and decent answer no shor.docx
Answer the bottom questions  in apa format and decent answer no shor.docxAnswer the bottom questions  in apa format and decent answer no shor.docx
Answer the bottom questions  in apa format and decent answer no shor.docx
 
Answer the following below using the EXCEL attachment. chapter 5.docx
Answer the following below using the EXCEL attachment. chapter 5.docxAnswer the following below using the EXCEL attachment. chapter 5.docx
Answer the following below using the EXCEL attachment. chapter 5.docx
 
Answer the following prompts about A Germanic People Create a Code .docx
Answer the following prompts about A Germanic People Create a Code .docxAnswer the following prompts about A Germanic People Create a Code .docx
Answer the following prompts about A Germanic People Create a Code .docx
 
Answer the following discussion board question below minumun 25.docx
Answer the following discussion board question below minumun 25.docxAnswer the following discussion board question below minumun 25.docx
Answer the following discussion board question below minumun 25.docx
 
Answer the following questions about IT Project Management. What.docx
Answer the following questions about IT Project Management. What.docxAnswer the following questions about IT Project Management. What.docx
Answer the following questions about IT Project Management. What.docx
 
Answer the following in at least 100 words minimum each1.Of.docx
Answer the following in at least 100 words minimum each1.Of.docxAnswer the following in at least 100 words minimum each1.Of.docx
Answer the following in at least 100 words minimum each1.Of.docx
 
Answer the following questions(at least 200 words) and responses 2 p.docx
Answer the following questions(at least 200 words) and responses 2 p.docxAnswer the following questions(at least 200 words) and responses 2 p.docx
Answer the following questions(at least 200 words) and responses 2 p.docx
 
Answer the following questions in a Word document and upload it by M.docx
Answer the following questions in a Word document and upload it by M.docxAnswer the following questions in a Word document and upload it by M.docx
Answer the following questions in a Word document and upload it by M.docx
 
Answer the following questions in complete sentences. Each answer sh.docx
Answer the following questions in complete sentences. Each answer sh.docxAnswer the following questions in complete sentences. Each answer sh.docx
Answer the following questions in complete sentences. Each answer sh.docx
 
ANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docx
ANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docxANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docx
ANSWER THE DISCUSSION QUESTION 250 WORDS MINDiscussion Q.docx
 

Recently uploaded

How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxDr.Ibrahim Hassaan
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceSamikshaHamane
 
Quarter 4 Peace-education.pptx Catch Up Friday
Quarter 4 Peace-education.pptx Catch Up FridayQuarter 4 Peace-education.pptx Catch Up Friday
Quarter 4 Peace-education.pptx Catch Up FridayMakMakNepo
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfphamnguyenenglishnb
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementmkooblal
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........LeaCamillePacle
 
AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.arsicmarija21
 
ROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint PresentationROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint PresentationAadityaSharma884161
 

Recently uploaded (20)

How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptx
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in Pharmacovigilance
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Quarter 4 Peace-education.pptx Catch Up Friday
Quarter 4 Peace-education.pptx Catch Up FridayQuarter 4 Peace-education.pptx Catch Up Friday
Quarter 4 Peace-education.pptx Catch Up Friday
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of management
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........
 
AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.
 
ROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint PresentationROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint Presentation
 

LISTINGS.txt345678 116900 0 80513-2918 Metro Brokers432395.docx

  • 1. LISTINGS.txt 345678 116900 0 80513-2918 Metro Brokers 432395 150743 1 80512-2771 City Realty 353455 342522 2 34534-3454 Upper East 999999 99999 2 92130-1312 This Test 555555 555555 0 77777-7777 Final Test CHANGES.txt 432395 -25000 353455 -2500 221111 -1000 345678 +5000 HodellAssn#6.cpp //*************************************************** ********************** #include <iostream> #include <fstream>
  • 2. #include <string> #include <iomanip> #include <cctype> using namespace std; // Global structure definition enum availability { AVAILABLE, CONTRACT, SOLD }; struct propertiesRec { int mlsNum; double price; availability status; string zipCode; string realtor; };
  • 3. //FUNCTION PROTOTYPES SECTION - //Previous Lab#4 functions with linked list mods void IntroProgram (); char MenuOne(); char UserMenuChoices (); void Add_New_Listing (); int Existing_Listings (); int Get_Validate_MLS_Input (); double Get_Validate_Price_Input (); availability Get_Status_Entry(); string Status_Enum_Text ( int ); string Get_Validate_ZipCode_Input (); string Get_Validate_Realtor_Input (); int CountIntegers( int ); void Display_MLS_Numbers (); bool Does_File_Exist(const char *fileName); //Class Definition - New Lab#6 Functions
  • 4. class node { propertiesRec Xdata; node *next; public: //Default constructor used to initialize variable with values node() { next=0; } //Constructor with parameters node ( propertiesRec varibable ) { Xdata = varibable; next = 0; } void put_next ( node *n ) { next = n; } node *Get_Next ( ) { return next; } int Get_MLS ( ) { return Xdata.mlsNum; } double Get_AskingPrice ( ) { return Xdata.price; } int Get_ListingStatus ( ) { return Xdata.status; } string Get_ZipCode() { return Xdata.zipCode; } string Get_Realtor() { return Xdata.realtor; }
  • 5. void SetAskingPrice( double ); void Append_List( propertiesRec ); void Remove_Node(); void DisplayListings(); void WriteToFile(); void ChangeAskingPrice(); //Declaring two nodes: header and 'n' initialized to 0. } *header=0, *n=0; //Input data constants const int MAX_REALTY_NAME = 15; const int MAX_ZIPCODE = 10; const char Y_UPPERCASE = 'Y'; const char N_UPPERCASE = 'N'; const char ADD_LISTING = 'A'; const char REMOVE_LISTING = 'R'; const char DISPLAY_ALL = 'D';
  • 6. const char CHANGE_ASKING_PRICE = 'C'; const char EXIT_PROGRAM = 'E'; //*************************************************** ********************** // FUNCTION: main // DESCRIPTION: Main function will call various functions to read, input, // calculate and display per account the phone usage totals // CALLS TO: // IntroProgram //*************************************************** ********************** int main() { // variables int count;
  • 7. char additional; propertiesRec listings; bool exit=false; n = new node(); // Begin Program execution IntroProgram (); additional = MenuOne(); if (additional == Y_UPPERCASE) { Existing_Listings(); } else {
  • 8. Add_New_Listing (); } while( !exit ) { additional = UserMenuChoices (); switch ( additional ) { case DISPLAY_ALL: if ( header == 0 ) { cout << "No existing data - Please Add data" << endl; Add_New_Listing (); } else { n->DisplayListings(); }
  • 9. break; case ADD_LISTING: { Add_New_Listing(); } break; case REMOVE_LISTING: { n->Remove_Node(); } break; case CHANGE_ASKING_PRICE: { n->ChangeAskingPrice(); } break; case EXIT_PROGRAM:
  • 10. { n->WriteToFile(); exit = true; } } } return 0; } //*************************************************** ********************** // FUNCTION: Program Introduction // DESCRIPTION: Introduce user to Reality Listing Program // INPUT: None // OUTPUT: Display a introduction to the user of the program. //*************************************************** ********************** void IntroProgram (void)
  • 11. { cout << endl; cout << "Welcome to the Realtor's Association MLS Listing(s) Program" << endl; cout << endl; } //*************************************************** ********************** // FUNCTION: Menu One // DESCRIPTION: First menu that the user can use to make a choice. // INPUT: User input and error correction // OUTPUT: Returns an answer to the main function. //*************************************************** ********************** char MenuOne() { char answer; cout << endl;
  • 12. cout << "Load existing data from file (Y/N) " << endl;; cout << "Y - Existing MLS Listing(s)" << endl; cout << "N - Enter New Listing(s)" << endl; cout << "Enter choice: "; do { cin >> answer; answer = toupper(answer); if (answer != Y_UPPERCASE && answer != N_UPPERCASE) { cout << "invalid choice: re-entern"; } } while (answer != Y_UPPERCASE && answer != N_UPPERCASE); return answer; }
  • 13. //*************************************************** ********************** // FUNCTION: Existing Records // DESCRIPTION: Reads the LISTINGS.txt file into an linked list // INPUT: inputFile (LISTINGS.txt) are called for read from this // function, if there is no txt and error will be screened // and the user can either exit or add new data to the new // linked list. // OUTPUT: A return value countRec records and adds up the number of // records read into the array-struct. //*************************************************** ********************** int Existing_Listings() { int availabilityInt; char userAns;
  • 14. char filename[20]; cout << "Enter a filename: "; cin >> filename; struct propertiesRec listings; ifstream inputFile(filename); if (!inputFile) { cout<< "INPUT FILE DOES NOT EXISTS." << endl; } else { while ( !inputFile ) {
  • 15. cout << "No Existing file data available or Input file did not open." << endl; cout << "Would you like to (A)dd new listings or (E)xit?" << endl; cin >> userAns; userAns = toupper (userAns); if ( userAns == 'A' ) { Add_New_Listing(); return 0; } if ( userAns == 'E' ) { return 1; } } while ( inputFile >> listings.mlsNum )
  • 16. { inputFile >> listings.price >> availabilityInt >> listings.zipCode; getline ( inputFile, listings.realtor); listings.status = static_cast<availability>(availabilityInt); n->Append_List(listings); } } inputFile.close(); } //***************************************************
  • 17. ********************** // FUNCTION: (A)dd Records // DESCRIPTION: This function takes user input via keyboard and copies it // per member into a array-struct record. // INPUT: Take use input and also countRec (# of actual records at // that moment. It also calls verification functions to verify // the data being entered. // OUTPUT: Adds a new record the array-struct and asks if they would // like to continue or stop. //*************************************************** ********************** void Add_New_Listing () { char more; do { propertiesRec listings;
  • 18. listings.mlsNum = Get_Validate_MLS_Input(); listings.price = Get_Validate_Price_Input(); listings.status = Get_Status_Entry(); listings.zipCode = Get_Validate_ZipCode_Input (); listings.realtor = Get_Validate_Realtor_Input (); n->Append_List( listings ); // Appends the linked list cout << endl; cout << "More Listing(s) to add (Y)es or (N)o?"; cin >> more; } while ( toupper(more) != N_UPPERCASE ); }
  • 19. //*************************************************** ********************** // FUNCTION: Display Listings // DESCRIPTION: // INPUT: // OUTPUT: // //*************************************************** ********************** void node::DisplayListings() { // Header Display cout << setw(15) << "Asking" << setw(11) << "Listing" << endl; cout << "MLS" << setw(11) << "Price" << setw(11) << "Status" << setw(13) << "zipcode" << setw(13) << "Realtor" << endl; cout << "------ " <<"------- " << "--------- " << "-------- -- " << "------------ " << endl;
  • 20. node *q; for( q=header; q!= 0; q= q->Get_Next() ) { cout << q->Get_MLS() << setw(10) << q- >Get_AskingPrice() << setw(12); string status = Status_Enum_Text ( q- >Get_ListingStatus() ); if ( q->Get_ListingStatus() == 0 ) { cout << setw(12) << status; cout << setw(13) << q->Get_ZipCode(); cout << " " << left << setw(10) << q- >Get_Realtor() << right << endl; }
  • 21. if ( q->Get_ListingStatus() == 1 ) { cout << setw(11) << status; cout << setw(14) << q->Get_ZipCode(); cout << " " << left << q->Get_Realtor() << right << endl; } if ( q->Get_ListingStatus() == 2 ) { cout << setw(7) << status; cout << setw(18) << q->Get_ZipCode(); cout << " " << left << q->Get_Realtor() << right << endl; } } } //*************************************************** **********************
  • 22. // FUNCTION: User Menu Choices // DESCRIPTION: This is the central user menu where they can make choices. // INPUT: This function takes no input, but does error check what the // user enters. // OUTPUT: A menu with all the major takes that this program can accomplish. //*************************************************** ********************** char UserMenuChoices () { char answer; cout << endl; cout << "User Menu Choices:" << endl; cout << "------------------" << endl; cout << "D - Display All" << endl; cout << "A - Add Listing(s)" << endl;
  • 23. cout << "R - Remove Listing(s)" << endl; cout << "C - Change Asking Price" << endl; cout << "E - Exit Program" << endl; cout << "Please enter your choice "; cout << endl; do { cin >> answer; answer = toupper(answer); if ( answer != DISPLAY_ALL && answer != ADD_LISTING && answer != REMOVE_LISTING && answer!= CHANGE_ASKING_PRICE && answer != EXIT_PROGRAM ) { cout << "invalid choice: re-enter" << endl; } } while ( answer != DISPLAY_ALL && answer != ADD_LISTING &&
  • 24. answer != REMOVE_LISTING && answer!= CHANGE_ASKING_PRICE && answer != EXIT_PROGRAM ); return answer; } //*************************************************** ********************** // FUNCTION: Append_List // DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX // INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX // OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX //*************************************************** ********************** void node::Append_List( propertiesRec Xdata ) { node *q,*t; if( header == 0 )
  • 25. { header= new node ( Xdata ); } else { q = new node(); q = header; while( q->Get_Next() !=0 ) { q = q->Get_Next(); } t = new node( Xdata ); q->put_next( t ); } } //*************************************************** ********************** // FUNCTION: Remove_Node
  • 26. // DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX // INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX // OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX //*************************************************** ********************** void node::Remove_Node() { Display_MLS_Numbers(); int mls; cout << "Enter MLS to remove: "; mls = Get_Validate_MLS_Input(); node *q,*r; q = header; // If node to be deleted is the first node if( q->Get_MLS() == mls ) {
  • 27. header = q->Get_Next(); delete q; return; } //if node to be deleted is not the first node r = q; while( q!= 0 ) { if( q->Get_MLS() == mls ) { r->next=q->next; delete q; return; } r = q;
  • 28. q = q->Get_Next(); } cout << "MLS number " << mls << " not Found."; } //*************************************************** ********************** // FUNCTION: WriteToFile // DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX // INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX // OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX //*************************************************** ********************** void node::WriteToFile() { if ( header == NULL ) // End of list or not populated head node {
  • 29. cout << "No existing data - no data will be saved" << endl; } char ch; bool again= true; cout<<"Do you want to save the listing(y/n): "; cin>>ch; ch=toupper( ch ); if ( ch=='Y' ) { char filename[20]; cout<<"Enter file name to save: "; cin>>filename; do {
  • 30. if ( Does_File_Exist(filename) ) //if file already exists { cout << "this file already exists. Do you want to overwrite it (y/n): "; cin >> ch; ch = toupper( ch ); if ( ch == 'Y' ) { ofstream FileOutput; FileOutput.open( filename ); node *q; for( q= header; q!= 0; q= q- >Get_Next() ) { FileOutput << q->Get_MLS() << " " << q->Get_AskingPrice() << " " << q->Get_ListingStatus() << " ";
  • 31. FileOutput << q->Get_ZipCode() << " " << q->Get_Realtor() << endl; } FileOutput.close(); again=false; } else { cout << "Enter another file name to save the listing: "; cin >> filename; } } else //if file does not exists { ofstream FileOutput; FileOutput.open( filename ); node *q;
  • 32. //iterate from header to the end of the linked list for( q=header; q!= 0; q= q->Get_Next() ) { FileOutput << q->Get_MLS() << " " << q->Get_AskingPrice() << " " << q->Get_ListingStatus() << " "; FileOutput << q->Get_ZipCode() << " " << q->Get_Realtor() << endl; } FileOutput.close(); again= false; } } while( again ); } }
  • 33. //*************************************************** ********************** // FUNCTION: SetAskingPrice // DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX // INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX // OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX //*************************************************** ********************** void node::SetAskingPrice( double newPrice ) { Xdata.price = newPrice; } //*************************************************** ********************** // FUNCTION: ChangeAskingPrice // DESCRIPTION: XXXXXXXXXXXXXXXXXXXXXXX // INPUT: XXXXXXXXXXXXXXXXXXXXXXXXXX // OUTPUT: XXXXXXXXXXXXXXXXXXXXXXXX //***************************************************
  • 34. ********************** void node::ChangeAskingPrice() { ifstream inputFile; inputFile.open( "CHANGES.TXT" ); if ( !inputFile ) { cout << "ERROR: File 'Changes.txt' does not exists." << endl; return; } int mls; double price; node *q; bool found = false; cout << "MLS number" << setw(20) << "New Asking
  • 35. Price" << endl; cout<<"---------- " << " ----------------" << endl; while ( inputFile >> mls ) { inputFile >> price; for( q= header; q!= 0; q= q->Get_Next() ) { if ( q->Get_MLS() == mls ) { found= true; q->SetAskingPrice( q->Get_AskingPrice()- price ); cout << mls << setw(14) << q- >Get_AskingPrice() << endl; } }
  • 36. } inputFile.close(); if ( found == false ) { cout << "No matching MLS number found" << endl; } } //*************************************************** ********************** // FUNCTION: Enter MLS listing // DESCRIPTION: Gets and validates the MLS number from the user // INPUT: User input with error correction. // OUTPUT: Writes data back to add data function. //*************************************************** ********************** int Get_Validate_MLS_Input ()
  • 37. { int MAX_MLS_NUMBER = 6; int MIN = 100000; int MAX = 999999; int mlsNum; cout << endl; cout << "Enter MLS number (Between 100000 - 999999)"; cin >> mlsNum; int numIntegers = CountIntegers( mlsNum ); while (cin.fail()) { cin.clear(); cin.ignore(); cout << "not integer" << endl; cin.clear(); cin.ignore();
  • 38. cin>>mlsNum; } numIntegers = CountIntegers( mlsNum ); do { if ( numIntegers > MAX_MLS_NUMBER ) { cout << endl; cout << "Length of MLS too long - Only 6 Digits." << endl; cin >> mlsNum; numIntegers = CountIntegers( mlsNum ); } } while ( numIntegers > MAX_MLS_NUMBER ) ; while (! ( mlsNum > MIN ) || ( mlsNum > MAX ))
  • 39. { cout << "Invalid Entry - (Between 100000 - 999999)"; cin.clear(); cin.ignore(); cin>>mlsNum; } return mlsNum; } //*************************************************** ********************** // FUNCTION: Enter Price // DESCRIPTION: Gets and validates the price entered by the user. // INPUT: User input with error correction. // OUTPUT: Writes data back to add data function. //*************************************************** ********************** double Get_Validate_Price_Input ()
  • 40. { int MAX_Price_Length = 6; int MIN = 1; int MAX = 999999; int price; cout << endl; cout << "Enter Price (Between 1 - 999999)"; cin >> price; int numIntegers = CountIntegers( price ); while ( cin.fail() ) { cin.clear(); cin.ignore(); cout << "not integer" << endl;
  • 41. cin>>price; } numIntegers = CountIntegers( price ); do { if ( numIntegers > MAX_Price_Length ) { cout << endl; cout << "Length of Price too long - Only 6 Digits." << endl; cin >> price; numIntegers = CountIntegers( price ); } } while (( numIntegers > MAX_Price_Length ) && ( cin.fail()) );
  • 42. return price; } //*************************************************** ********************** // FUNCTION: Count Number of Integers // DESCRIPTION: counts the numbers // INPUT: Enter price function inputs the user data. // OUTPUT: Returns the actual numbers entered by the user to the calling // function. //*************************************************** ********************** int CountIntegers( int number ) { if ( number < 10 ) { return 1; }
  • 43. int countInt = 0; while ( number > 0 ) { number /= 10; countInt++; } return countInt; } //*************************************************** ********************** // FUNCTION: Enter ZipCode // DESCRIPTION: Gets and validates the zipCode number. // INPUT: User input with error correction. // OUTPUT: Writes data back to add data function. //*************************************************** **********************
  • 44. string Get_Validate_ZipCode_Input () { string zipCode; bool valid = true; do { valid = true; cout << "Enter Zipcode (XXXXX-XXXX)" << endl; cin >> zipCode; if ( zipCode.length() <10 || zipCode.length() > MAX_ZIPCODE ) { cout << "Invalid ZipCode - Zip code length must be 10 " << endl; valid = false; } else if ( zipCode[5] != '-' )
  • 45. { cout << "Invalid ZipCode - '-' is not at correct position" << endl; valid = false; } else { for ( int counter = 0; counter <= 4; counter++ ) { if ( !isdigit(zipCode[counter]) ) { cout << "Invalid ZipCode - all must be digits" << endl; valid = false; } } for ( int counter = 6; counter <= 9; counter++ ) { if ( !isdigit(zipCode[counter]) )
  • 46. { cout << "Invalid ZipCode - all must be digits" << endl; valid = false; } } } }while ( valid == false ); return zipCode; } //*************************************************** ********************** // FUNCTION: Enter Realty Company Name // DESCRIPTION: Gets and validates the propertiesRec name // INPUT: User input with error correction. // OUTPUT: Writes data back to add data function. //***************************************************
  • 47. ********************** string Get_Validate_Realtor_Input () { string propertiesRec; int counter; bool valid = true; do { cout << endl; cout << "Enter propertiesRec Name, only letter(s) and spaces allowed " << endl; cin.ignore(); getline( cin, propertiesRec ); if ( propertiesRec.length() > MAX_REALTY_NAME ) { cout << "Invalid propertiesRec Name"
  • 48. << endl; getline( cin, propertiesRec ); } } while ( propertiesRec.length() > MAX_REALTY_NAME ); // This tests for letters for ( int counter = 0; counter < propertiesRec.length(); counter++ ) { if ( !isalpha(propertiesRec[counter]) && valid == true ) { cout << "Invalid propertiesRec Name" << endl; getline( cin, propertiesRec ); } // This is the first letter Capitializer
  • 49. for (int counter = 0; counter < propertiesRec.length(); counter++) { if ( isalpha(propertiesRec[counter]) && valid == true ) { propertiesRec[counter] = toupper( propertiesRec[counter] ); valid = false; } else if (isspace ( propertiesRec[counter]) ) valid = true; } } return propertiesRec; }
  • 50. //*************************************************** ********************** // FUNCTION: Get Status Entry // DESCRIPTION: Takes user input and enters the status via switch. // INPUT: User input with error correction. // OUTPUT: Outputs the data into the array-struct via add data function. //*************************************************** ********************** availability Get_Status_Entry() { int entry; cout << "Enter the listing's status ( 0 - Available; 1 - Contract, 2 - Sold): "; while ( !(cin >> entry) || entry < 0 || entry > 2 ) { cout << "Invalid listing status, please enter 0 - Available, 1 - Contract, or 2 - Sold." << endl; cout << "Try again: ";
  • 51. cout << endl; } switch (entry) { case 0: return AVAILABLE; case 1: return CONTRACT; case 2: return SOLD; default: break; } } //*************************************************** ********************** // FUNCTION: Status Enum to Text
  • 52. // DESCRIPTION: Converts from cell integer to enumuration for display // INPUT: Is call by the display all function. // OUTPUT: Returns the correct converted enumeration status type. //*************************************************** ********************** string Status_Enum_Text (int status) { switch (status){ case 0: return "AVAILABLE"; case 1: return "CONTRACT"; case 2: return "SOLD"; default: break;
  • 53. } } //*************************************************** ****************** // FUNCTION: Display MLS Numbers // DESCRIPTION: Displays MLS list from the Linked-list. Checks first if // there are any MLS records. // INPUT: Reads the Linked-list // OUTPUT: Outputs to screen a header and list of current MLS#. //*************************************************** ******************* void Display_MLS_Numbers () { node *q; if ( header == NULL ) {
  • 54. cout << "There are no Listings stored." << endl; } else { cout << "MLS#" << endl; cout << "------" << endl; //Work through head node to null node for( q= header; q!= 0; q= q->Get_Next() ) { cout << q->Get_MLS() << endl; } cout << endl; } } //*************************************************** ****************** // FUNCTION: Does_File_Exist
  • 55. // DESCRIPTION: Performs a check on the existence of the user inputed // file name. // INPUT: // OUTPUT: // //*************************************************** ******************* bool Does_File_Exist ( const char *fileName ) { ifstream inputFile( fileName ); bool exists = false; if ( inputFile ) exists= true; return exists;
  • 56. } APA Assignment Instructions Attached you will find the following sections of a formal paper written using APA format: · Title Page · Abstract · First two pages of Chapter 1 · Reference List Unfortunately, this paper contains multiple common formatting errors. To complete this assignment you must correct the errors in each of the above sections and return the assignment for evaluation. Errors include omissions as well as commissions. For example, when looking at the title page you want to observe for omission errors by checking to see that all necessary components have been included and commission errors by determining whether or not the information that has been provided is in the right place on the page. If you do not have a copy of the 6th Edition of the APA Manual, you can use one of the APA Web sites listed in Module 5. Please note: This assignment only contains selected sections of a formal paper. Other required sections (for example, a table of contents) have been omitted. For the purpose of this assignment, you only need to address the sections provided. You also do not have to correct any grammar errors you may find. Title Page Writing for Publication
  • 57. Abstract Writing for publication is more than opportunity for professional development. It is a responsibility of all health care professionals. Unfortunately, many health care professionals, especially those outside of academia are unfamiliar with the publication process. The purpose of this paper is to provide a detailed description of the publication process from conception of the idea through actual publication. The topics addressed include finding a publishable idea, finding the right journal for publication, contacting the editor and preparing and submitting a manuscript. The paper will also discuss actual and perceived obstacles to publication. Chapter 1 Introduction In this world of evidence based practice, it is becoming more and more important for health care professionals to share their clinical successes and their failures. Health care professionals have a responsibility to themselves, their colleagues and their patients to read what others are saying, to evaluate the relevance of what they are reading and to write so that their successes can be implemented by others. The opportunities to be published are growing every year. “In the past two decades there has been a phenomenal rise in the number of peer reviewed publications, either as paper-print or as online journals, and this has been in response to the growing demand for information, research activity and the necessity to apply empirical findings to the delivery of patient care (Albarran, J. & Scholes, J. 2005, page 72)”. For the novice writer, writing for publication can appear to be a daunting task and many fear that they haven’t the time, skill or experience to undertake the challenge (Albarren, J., & Scholes, J. 2005; Doyle,E., et. al., 2004). However, writing for publication is not the “Mount Everest” most fear and the process is one that can be learned. Although writing requires a commitment, it is a doable task that can be enjoyable and
  • 58. rewarding. GETTING STARTED Making the decision to try your hand at publication is the first hurdle. Once the decision has been made, an idea needs to be formulated and a work plan established. When choosing a topic, experts agree that you should begin by writing about a topic that you know well (Cook, R. 2000). “Ideas for a journal article are everywhere. Start with your area of practice. Think about the type of work you do, the types of clients you work with and the things you do well. For example, if your colleagues always ask for your advice on how to handle a particular situation, maybe you want to write about it. If your unit is known for the work it does with a particular type of patient, you may have publishable information to share (US Department of the Health Professions, pages 22-23). First time writers sometimes choose to write with another person. Even if you want to write alone, it may help to brainstorm with a colleague to come up with some ideas to consider. Albarran and Scholes (2006) suggest that before you go too far down the path, you think about the type of journal, magazine or newsletter you want to publish in. The information you will provide and your writing style will vary depending upon the audience. In addition, you will want to review recent issues of the publications to see what topics have been covered over the past year. You may not be able to get an article published if a similar topic was recently covered. In addition, by looking through publications you may find a call for articles on a particular topic for a special focused edition of the publication. Once you think you have found the right publication, it is important that you check with the editor (Griffin-Sobel, J. 1999). By providing a brief description an editor can tell you if there is interest in the topic and may be able to provide further direction that will result in an acceptance of your manuscript. Writing takes time and commitment and it is easy to put the manuscript away and never pick it up again. Therefore, once you have made a commitment to write an article, prepare a work
  • 59. plan and timeline for yourself. This simple strategy will greatly improve the likelihood of your success. In addition to establishing deadlines, you should think about and plan for when and where you will write and where you will find the resources you will need to write the article. For example, you may need to include a reference list or pictures. Pick a place and time where you can write undisturbed. Make sure your timelines is consistent with any deadlines you may receive from the editor…a manuscript that is late, may not get published. References Albarran, John W., & Scholes, Julie (2005). How to Get Published: Seven Easy Steps. British Association of Critical Care, Nursing in Critical Care, 10(2), 72-77. Cook, Ralph. (2000). The Writers Manual, Oxford: Radcliff Medical Press Doyle, Eva J, Coggins, Claudia, & Lanning, Beth (2004). Writing for Publication in Health Education. American Journal of Health Studies, 19(2), 100-109. Duncan, Sarah Smith. Writing for Publication. (Retrieved from the World Wide Web 10/27/06 at http://www.library.jhu.edu/researchhelp/general/publishing.html ) Griffin-Sobel, Joyce (1999). Writing for Publication, Clinical Journal of Oncology Nursing, 9(1). Sheriden Libraries. Writing for Publication: Tools for Getting Started. (Retrieved from the World Wide Web 10/27/06, at http://www.library.jhu.edu/researchhelp/general/publishing.html ) St. James, Deborah (2001). Writing, Speaking & Communication Skills for Health Professionals. New Haven: Yale University Press. US Department of the Health Professions, (2002). Washington
  • 60. DC, Professional Development: Writing for Publication. (Publication Number DHP365-Y) PAGE 1