Search This Blog

Thursday, March 1, 2012

Privacy, privacy! Where's my privacy?!

Okay, we have heard about Google in the news and the invasion of our privacy. The funny thing is, that I am going to help you but wonder if my blog will be taken down.

I got an email and tried it on a Google Gmail account and it worked nicely. According to Jason Rosenbaum, PCCC Internet Freedom Campaigner: "In just a few hours, new policies will take effect at Google, endangering your privacy.  Tech publication Gizmodo reports, "things you could do in relative anonymity today [like your web searches], will be explicitly associated with your name, your face, your phone number come March 1st." And this applies retro-actively if you don't act by midnight." You can protect yourself in just 1 minute! Click here for a step-by-step guide to protecting your privacy from Google's changes. 

I also use Privacy Guardian and C-Cleaner. Both are free downloads from Cnet.com.

I like Privacy Guardian for its secure file shredder. Instead of deleting files and emptying my recycle bin, I use the free Shredder with Privacy Guardian to perform a Department of Defense type wipe on deleting files. Basically, you right click on the file and select "Shred with Privacy Guardian". I liked the program so much, I purchased it for additional functionality. Although there are some glitches, I will try logging onto the PC Tools site and reinstall the product. I also use it to clean up traces of activity on my browsers.

C-Cleaner will free up hard disk space on your computer, clean your registry for optimal PC performance, as well as let you COMPLETELY uninstall computer programs (better than the Control Panel in Windows). The best way to uninstall is to use the program's CD but if you don't have it, this is the next best thing. It does clean up the temporary Internet files more thoroughly than Privacy Guardian.


Hope this helps! So relax, don't let the computer bugs bite and enjoy your net surfing!


Saturday, February 18, 2012

Creating Pop-Up Windows and Command Buttons in Excel 2007 and 2010

I have made two instructional videos on how to do this on You Tube.

Here is the link for the code explanation: www.youtube.com/watch?v=Pe8NdYXjBNQ&feature=channel

Here is the link for the button explanation: http://www.youtube.com/watch?v=7_rXqoZxb4k&feature=youtu.be

Tuesday, May 10, 2011

ASP.Net 3.5 with C#/ SQL Server Express - My Summer Project

The SQL Server Express application is still not functioning. Having problems with installation. BUT the ASP.Net/C# goal is progressing nicely. I just finished a chapter where I had to create a shopping cart. Four pages (2 ASP.Net and 2 C# pages), a database, two classes, and multiple images were provided from the author's website. I wrote and debugged the CheckOut.aspx (ASP.Net), CheckOut.aspx.cs (C#), and Customer.cs (Customer Class). I also set up validation and went a step further to provide proper email validation by searching for code on the internet:

ValidationExpression="^[\w-]+@[\w-]+\.(com|net|org|edu|mil)$"

I am using Murach's ASP.Net 3.5 with C# 2008 book. I really enjoy using it. I was struggling with it for awhile but as a result of just finishing a class on C++, C# is a bit similar to C++ and also similar to classic asp, using this book finally clicked with me since the author said that you need to be familiar with C# before starting the book. Leave it to me to do things backwards. : )

I think my next project will involve making a login page or using SQL in a project if I can get away without using the SQL Server I am trying to install. So I will skip around a bit in the book. I will just have to figure it out with the Internet and the two new C# books I bought from Amazon. If stuck, I can always go to Dream In Code for help.

Here are some screen shots of the project: (Click to enlarge)


 
Here is what the Visual Studio 2008 dashboard looks like: (Click to enlarge)
Here is the code for "CheckOut.aspx":
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="CheckOut.aspx.cs" Inherits="CheckOut" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Check Out</title>
    </head>
<body>
    <form id="form1" runat="server">
    <div>
   
        <asp:Label ID="Label1" runat="server"
            Text="Please enter the following information:"></asp:Label>
        <br />
       
        <br />
   
        <asp:Label ID="lblFirstName" runat="server" Text="First Name:" Width="110px"
            style="text-align: right"></asp:Label>
&nbsp;<asp:TextBox ID="txtFirstName" runat="server" Width="110px"></asp:TextBox>
        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server"
            ControlToValidate="txtFirstName" Display="Dynamic"
            ErrorMessage="First Name is a required field.">
        </asp:RequiredFieldValidator>
        <br />
        <asp:Label ID="lblLastName" runat="server" Text="Last Name:" Width="110px"
            style="text-align: right"></asp:Label>
&nbsp;<asp:TextBox ID="txtLastName" runat="server"
            Width="110px"></asp:TextBox>
        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server"
            ControlToValidate="txtLastName" Display="Dynamic"
            ErrorMessage="Last Name is a required field."></asp:RequiredFieldValidator>
        <br />
        <asp:Label ID="lblEmail" runat="server" Text="Email:" style="text-align: right"
            Width="110px"></asp:Label>
&nbsp;<asp:TextBox ID="txtEmail" runat="server" 
            Width="110px"></asp:TextBox>
&nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server"
            ControlToValidate="txtEmail" Display="Dynamic"
            ErrorMessage="Email is a required field."></asp:RequiredFieldValidator>
&nbsp;<asp:RegularExpressionValidator ID="ValidEmailRegExp" runat="server"
            ControlToValidate="txtEmail" Display="Dynamic"
            ValidationExpression="^[\w-]+@[\w-]+\.(com|net|org|edu|mil)$"
            ErrorMessage="Please enter a valid email address"></asp:RegularExpressionValidator>
&nbsp;<br />
        <br />
        <asp:Button ID="btnContinue" runat="server" Text="Continue Shopping"
            Width="166px" onclick="btnContinue_Click" />
&nbsp;<asp:Button ID="btnCancel" runat="server" Text="Cancel" Width="166px"
            onclick="btnCancel_Click" />
        <br />
        <br />
   
    </div>
    </form>
</body>
</html>

 Here is the code for "CheckOut.aspx.cs": (It looks very similar to C++)
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

public partial class CheckOut : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void btnCancel_Click(object sender, EventArgs e)
    {
        Response.Redirect("Order.aspx");
        txtFirstName.Text = "";
        txtLastName.Text = "";
        txtEmail.Text = "";
    }

    protected void btnContinue_Click(object sender, EventArgs e)
    {
        Response.Redirect("Order.aspx");
    }
}

Monday, May 9, 2011

C++ Backward String Program


Backward String 

Write a function that accepts a C-string as an argument and displays its contents backwards. For instance, if the string argument is “Gravity” the function should display “ytivarG”. Demonstrate the function in a program that asks the user to input a string and then passes it to the function. 

Here is the output: (Click to enlarge)
Here is the code:
// Kim Pestana C++, Chapt. 11, Backward String
// Backward String
// Write a function that accepts a C-string as an argument and
// displays its contents backwards. For instance, if the string argument is “Gravity”
// the function should display “ytivarG”. Demonstrate the function in a program
// that asks the user to input a string and then passes it to the function.

#include <iostream>
#include <iomanip>
#include <fstream>
#include <string>
#include <cstring>

// Not sure if I need all libraries but it can't hurt. :)

using namespace std;


// C-String handling function
void Backward (char *);

int main()
{
// define array for letters in a word entered       
char word[41];

// ask user for input
cout << "This program will display the letters of a word entered in backwards order"
       "follwed by a period." << endl;
cout << "Please enter a word not over 40 letters:" << endl;

// display word entered backwards
cin >> word;

cout << "The entered word displayed in reverse is: " << word << endl;

Backward(word);

cout << endl;

       system("Pause");
       return 0;
}


void Backward (char *sentencePtr)

{

       char *p = sentencePtr;
       while ( *p != '\0' )

             ++p;

       while ( p != sentencePtr )

             cout.put ( *--p );
      

}