Saturday, 11 June 2016

MAX HealthCare using ASP.NET and Bootstrap

MAX Health Care using ASP.NET and Bootstrap

Max Health care is an online hospital management system using Asp.net and bootstrap which has the following management features:

User Roles Login i.e Admin and user authentication log in page.
User registration/signup page
Admin user management and database modification page.


This Project was developed using Asp.Net (html and css) and bootstrap for it FRONT END and
C# with MSSQL for its BACK END.

full source code for the project will be give upon request but below are some code snippet with print screen of the system

Below is the default homepage of Max Healthcare using ASP.NET and Bootstrap FRONT END.






The above screen shots and code snippet only shows the front end of the web site including the HTML code show.. The addition of bootstrap and CSS styling was used to give the rich design of the website making it responsive to all devices sizes as shown below.



The second part is the login page which redirects users based on user roles.. can be admin or the patients who registered to make a booking for the service of the doctor.


As seen from the above screen to every page being navigated the page nav button is being highlighted to identify and allow users to know the exact page they are navigating at that point in time.

So simple and easy to understand.. the login page has its own security measure to allow or reject unauthorized users and also allow users to remember username and password in the case of users who like to make it easy for login on navigation to the log in page.



C# BACK END CODE FOR LOGIN PAGE.



as show above is the login page authenticating users based on their roles.. the full source code will be given on request and maybe some suggestions will be high appreciated and accepted.


Wednesday, 25 May 2016

SIMPLE LETTER COUNTING IN ANDROID STUDIO Complete Part

This part completes the letter counting game showing the user interaction and results as seen in the images shown below.


STEPS: As shown in the images below, a user needs to enter his/her name to be able to play this game and only with the use of the menu bar will the game start by creating another page where alphabetical values (array of names) are shown for counting.

ACTIVITY_MAIN.XML

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="#4ba9f5"
    android:paddingBottom="@dimen/activity_vertical_margin"
    android:paddingLeft="@dimen/activity_horizontal_margin"
    android:paddingRight="@dimen/activity_horizontal_margin"
    android:paddingTop="@dimen/activity_vertical_margin"
    app:layout_behavior="@string/appbar_scrolling_view_behavior">

    <TextView
        android:id="@+id/textView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_centerHorizontal="true"
        android:text="Game Central"
        android:textAppearance="?android:attr/textAppearanceLarge" />

    <TextView
        android:id="@+id/player_name"
        android:layout_width="100dp"
        android:layout_height="70dp"
        android:layout_alignParentLeft="true"
        android:layout_alignParentStart="true"
        android:layout_below="@+id/textView"
        android:layout_marginTop="50dp"
        android:gravity="center"
        android:text="Player Name" />

    <EditText
        android:id="@+id/Pname"
        android:layout_width="100dp"
        android:layout_height="60dp"
        android:layout_alignEnd="@+id/textView"
        android:layout_alignRight="@+id/textView"
        android:layout_alignTop="@+id/player_name"
        android:layout_toRightOf="@+id/player_name" />

    <TextView
        android:id="@+id/current_score"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerHorizontal="true"
        android:layout_centerVertical="true"
        android:text="Current Score"
        android:textAppearance="?android:attr/textAppearanceLarge" />

    <TextView
        android:id="@+id/score"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_below="@+id/current_score"
        android:layout_centerHorizontal="true"
        android:layout_marginTop="48dp"
        android:text="0/0" />

</RelativeLayout>

MAIN_ACTIVITY.JAVA

package com.example.jeffery.BJ1616939Task3;

import android.content.Intent;
import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.view.Menu;
import android.view.MenuItem;
import android.widget.EditText;

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
        setSupportActionBar(toolbar);

        //EditText et = (EditText) findViewById(R.id.Pname);

        FloatingActionButton fab = (FloatingActionButton) findViewById(R.id.fab);
        fab.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Snackbar.make(view, "Replace with your own action", Snackbar.LENGTH_LONG)
                        .setAction("Action", null).show();
            }
        });
    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        // Inflate the menu; this adds items to the action bar if it is present.
        getMenuInflater().inflate(R.menu.menu_main, menu);
        return true;
    }

    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        // Handle action bar item clicks here. The action bar will
        // automatically handle clicks on the Home/Up button, so long
        // as you specify a parent activity in AndroidManifest.xml.
        int id = item.getItemId();
        EditText et = (EditText) findViewById(R.id.Pname);

        //noinspection SimplifiableIfStatement
        if (id == R.id.Letter_counting) {
            Intent intent = new Intent(MainActivity.this, Counting_Game.class);
            intent.putExtra("Welcome", et.getText().toString());
            startActivity(intent);
            return true;
        }

        return super.onOptionsItemSelected(item);
    }
}

COUNTING_GAME.XML

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="#4ba9f5">

    <TextView
        android:id="@+id/users"
        android:layout_width="100dp"
        android:layout_height="wrap_content"
        android:layout_marginTop="43dp"
        android:text="User"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:layout_alignParentTop="true"
        android:layout_toRightOf="@+id/textView3"
        android:layout_alignRight="@+id/textView5"
        android:layout_alignEnd="@+id/textView5" />

    <TextView
        android:id="@+id/textView4"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_below="@+id/users"
        android:layout_centerHorizontal="true"
        android:text="I will choose a random number"
        android:textSize="20dp"/>

    <TextView
        android:id="@+id/textView5"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_below="@+id/textView4"
        android:layout_centerHorizontal="true"
        android:text="how many letters are in it?"
        android:textSize="20dp"/>

    <TextView
        android:id="@+id/textView6"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="VALUES"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:layout_above="@+id/editText2"
        android:layout_centerHorizontal="true" />

    <EditText
        android:id="@+id/editText2"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_centerHorizontal="true"
        android:layout_marginBottom="175dp" />

    <ImageView
        android:id="@+id/imageView"
        android:layout_width="130dp"
        android:layout_height="wrap_content"
        android:src="@drawable/counting"
        android:layout_below="@+id/textView5"
        android:layout_centerHorizontal="true" />

    <Button
        android:id="@+id/button"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignTop="@+id/editText2"
        android:layout_centerHorizontal="true"
        android:layout_marginTop="66dp"
        android:text="Check" />

    <TextView
        android:id="@+id/textView7"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_below="@+id/button"
        android:layout_centerHorizontal="true"
        android:text="No Value" />

    <TextView
        android:id="@+id/textView3"
        android:layout_width="150dp"
        android:layout_height="wrap_content"
        android:text="Welcome"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:layout_above="@+id/textView4"
        android:layout_toLeftOf="@+id/editText2"
        android:layout_alignLeft="@+id/textView5"
        android:layout_alignStart="@+id/textView5" />
</RelativeLayout>


COUNTING_GAME.JAVA

package com.example.jeffery.BJ1616939Task3;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;

/**
 * Created by JEFFERY on 4/27/2016.
 */
public class Counting_Game extends Activity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.counting_game);

        TextView userView = (TextView)findViewById(R.id.users);
        userView.setText(getIntent().getExtras().getString("Welcome"));


        final EditText userguess = (EditText) findViewById(R.id.editText2);
        final TextView tvInput = (TextView) findViewById(R.id.textView6);
        final TextView tvOutput = (TextView) findViewById(R.id.textView7);
        Button btcheck = (Button)findViewById(R.id.button);

        String[] myNames ={"emmanuel", "Mary", "Patrick", "Janet"};
        int rando = (int)(Math.random()*4);
        tvInput.setText(myNames[rando]);

        btcheck.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {

                int rando;
                rando = Integer.parseInt(userguess.getText().toString());
                if (tvInput.length() == rando) {
                    tvOutput.setText("Correct Value");
                }else if (tvInput.length()!= rando){
                    tvOutput.setText("Wrong Value");
                }else {
                    tvOutput.setText(null);
                }
            }
        });


    }
}

MENU_MAIN.XML

<menu xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    tools:context="com.example.jeffery.BJ1616939Task3.MainActivity">
    <item
        android:id="@+id/Letter_counting"
        android:orderInCategory="100"
        android:title="@string/Letter_Counting"
        app:showAsAction="never" />
    <item
        android:id="@+id/Game_Holder_2"
        android:orderInCategory="101"
        android:title="@string/Game_Holder_2"
        app:showAsAction="never"/>

    <item
        android:id="@+id/Game_Holder_3"
        android:orderInCategory="101"
        android:title="@string/Game_Holder_3"
        app:showAsAction="never"/>

    <item
        android:id="@+id/Game_Holder_4"
        android:orderInCategory="101"
        android:title="@string/Game_Holder_4"
        app:showAsAction="never"/>
</menu>

MANIFEST.XML

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.example.jeffery.BJ1616939Task3">

    <application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">
        <activity
            android:name="com.example.jeffery.BJ1616939Task3.MainActivity"
            android:label="@string/app_name"
            android:theme="@style/AppTheme.NoActionBar">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity android:name="com.example.jeffery.BJ1616939Task3.Counting_Game">

        </activity>
    </application>

</manifest>


As shown above in the above code of the counting game comprises of two pages connected with menu intent. so once the player name is input with the help of the menu bar, the game can be started . below are the image views of the game accordingly.





Note: This is a simple counting game...!!!

















Monday, 25 April 2016

HOSPITAL BILLING SYSTEM (Using ECLIPSE JFRAME AND MYSQL)

This is an overview of a Hospital billing system with few functionalities.


Above is he GUI for the Login Page.

GUI Admin Page as shown

GUI Main Page

GUI for Manage Patient

GUI for Doctor prescription

GUI for Billing

As seen above are the screen shots of the systems Graphical user interface.. Below you can dowload the source code to this system.








Wednesday, 9 March 2016

SIMPLE LETTER COUNTING IN ANDROID STUDIO

Name counting Game in Android Studio.



The above images shows a name name PATRICK picked at launch of application using geny motion emulator.



As show is another name which required input of correct number to identify the number of letters as given. when the wrong value is given, it indicated below as wrong value since it didnt match the amount of letters given.


As seen when correct value is given, it shows the correct Value.


Tuesday, 26 January 2016

Fanduel Affliate Webpage using PHP Part 2

FANDUEL WEBPAGE LOGIN AND REGISTRATION USING PHP AND MYSQL DATABASE.

Part 11 CREATING OF REGISTRATION PAGE AND CONNECTION TO DATABASE



As per the PART 1 of this project, understanding how to create a database by simple downloading the Xampp server and access PHPMYADMIN page is very vital. But firstly below is the basic HTML design for the registration form. 


The above shows the design of the registration form using tables and giving the input and names as require.

Note: The form would be properly designed and arrange with the help of CSS styling.

Connecting form to the Database.
once value is input it records in the database create with the database named TEST and table name reg_details.

CREATING OF LOGIN PAGE AND CONNECTION TO DATABASE


Above is the overview of the Login Page and below is the code snippet showing hot to create the login tables and retrieving data stored from the registration form in the database.



As seen above is the snippet showing how the username and password can be retrieved from the database. This is just a sample project on inserting and retrieving data from the database using PHP.

Tuesday, 19 January 2016

Fanduel Affliate Webpage using PHP

CREATING FANDUEL WEBPAGE USING PHP AND MYSQL DATABASE

PART 1 Creating Home Page




STEPS:


  1. Download an Apache Server from link to suit your PC specification (i.e x86 or x64).
  2.  Install desired Apache Server on PC and and you are ready to go.
  3. At the time of this project, i download 32bit Xampp 7.0.2 server.
  4. After installation, run the application, then click start on Apache and MYSQl to run the application as shown below in FIG 1. ( it is also important to make sure MYSQL is running properly by opening an internet explore and typing localhost/PHPMYADMIN as seen in FIG 11)
FIG 1

FIG 11

Note: In order to View Pages on the web explorer, all files need to be saved in the server directory named htdocs. you can find this by simply following this step. C:\xampp\htdocs and there you can save files with .PHP ending file name.

Below are the Code Snippet for the HomeScreen of Fanduel Affiliate page.

INDEX.php


The Home page is divided intro three section and with the index.php page, i could used the include function to call the overview page which will run the hope page on start up using localhost/project where project is the name of the folder where the php files are being saved.

HEADER.php


This section is basically HTML and CSS scripting 


OVERVIEW.php


If you can see the right side of the image above is cut short, but it doesn't affect the code in anyway because it is just a descriptive text

Conclusion:

This is just a simple view for a homepage using PHP and i would appreciate any correction or comments on this project.. Thanks