Sunday, 22 January 2017


HL7 Class (version 0.3) Beta


.NET Framework

This class is not certified to be used in a production environment working with live patient data.

Class to manipulate HL7 messages, updating values at specified positions, and reading patient data from the message.  

Namespace:   Assembly:   (in .dll)Copy

Syntax

public HL7_Edit(

            string HL7_Body)

Parameters


HL7_Body

The HL7 message body

Constructors


Name
Description
HL7_Edit()
Initializes a new instance of the HL_Edit class.
HL7_Edit(String)
Initializes a new instance of the HL7_Edit class with the specified argument.

Properties


Name
Description
PatNames
Gets PID:xxx information 
PatAddress
Gets a patient address (PID:xxx)
PatIDs
Gets a list of all patient IDs in the message (PID:xxx)
LocalID
Gets patient’s hospital number
NationalID
Gets patient’s national patient ID, eg UK’s NHS number
GN
Gets patient’s given name
FN
Gets patient’s family name
MN
Gets patient’s middle name
Title
Gets patient’s title
Addr1
Gets address line 1
Addr2
Gets address line 1
Addr3
Gets address line 1
Addr4
Gets address line 1
Addr5
Gets address line 1
Postcode
Gets postcode
PatGender
Gets the patients gender directly from the message
DoB
Gets the unformatted date of birth







Methods


Name
Description
searchForPosition( string, int)
Returns the value from the HL7 messages at the specified position
updateValue(string, int, string)
Updates value at the specified position
returnMessage()
Returns the HL7 message with any updated added by updateValue()
add()
Updates HL7





Remarks


Class is currently in Beta format. 
For a copy of the HL7_Edit class send an email from a healthcare email address to Pablo.BluesteelS@outlook.com

Examples


Simplified user control formatted as a common page header example.  Additional properties can be added to provide the required patient information. 
C#/XAML

<UserControl

    x:Class="HL7___UA.patientDetailsHeader"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:local="using:HL7___UA"

    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"

    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

    mc:Ignorable="d"

    d:DesignHeight="100"

    d:DesignWidth="1280">



    <Grid>

        <Grid x:Name="LayoutRoot" Background="#555555" Width="1280" Height="70">

            <Grid.ColumnDefinitions>

                <!--patient national number-->

                <ColumnDefinition Width="Auto" MinWidth="100" />



                <!--patient local number-->

                <ColumnDefinition Width="Auto" MinWidth="100" />



                <!--patient FN-->

                <ColumnDefinition Width="Auto" MinWidth="100"  />



                <!--patient GN-->

                <ColumnDefinition Width="Auto" MinWidth="100" />

            </Grid.ColumnDefinitions>

            <Grid.RowDefinitions>

                <RowDefinition Height="75" />

            </Grid.RowDefinitions>

            <TextBlock Name="nationalNumberText" Text="National Number" Grid.Column="0" Margin="10,10,0,26" HorizontalAlignment="Center" VerticalAlignment="Center" IsDoubleTapEnabled="False" IsHoldingEnabled="False" IsTapEnabled="False" IsRightTapEnabled="False"/>

            <TextBlock Name="localNumberText" Text="Local Number" Grid.Column="1" Margin="10,10,0,26" HorizontalAlignment="Center" VerticalAlignment="Center"  IsDoubleTapEnabled="False" IsHoldingEnabled="False" IsTapEnabled="False" IsRightTapEnabled="False"/>



            <TextBlock Name="patientGN" Text="Patient Given Name " Grid.Column="2" Margin="10,10,0,26" HorizontalAlignment="Center" VerticalAlignment="Center"  IsDoubleTapEnabled="False" IsHoldingEnabled="False" IsTapEnabled="False" IsRightTapEnabled="False"/>

            <TextBlock Name="patientFN" Text="Patient Family Name" Grid.Column="3" Margin="10,10,0,26" HorizontalAlignment="Center" VerticalAlignment="Center"  IsDoubleTapEnabled="False" IsHoldingEnabled="False" IsTapEnabled="False" IsRightTapEnabled="False"/>



        </Grid>

    </Grid>

  

</UserControl>



/// <summary>

///

/// </summary>

/// <param name="natNumber"></param>

/// <param name="localNumber"></param>

/// <param name="GN"></param>

/// <param name="FN"></param>

public patientDetailsHeader(string natNumber, string localNumber, string GN, string FN)

        {

            this.InitializeComponent();

            nationalNumberText.Text = natNumber;

            localNumberText.Text = localNumber;

            patientGN.Text = GN;

            patientFN.Text = FN;


        }

 

    }

See Also

No comments:

Post a Comment