Thursday, October 22, 2015

Customize the Windows 7 Logon Screen

It's only been 3 years.  Perhaps I should create an update!

How about how to set your own image for your Windows 7 log on screen?  Yes.  I'm still working with Windows 7, so have no idea if this works on 8 or 10.  Sorry for any inconvenience.


Basically, this is for non-domain systems and/or systems where the group policy doesn't interfere.  Insert the following into a text file and rename it, e.g. custom_background.reg:
(omit the --- lines at the top and bottom)

----
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI\Background]
"OEMBackground"=dword:00000001
---

That will ensure the OEMBackground value is set to '1' (as shown above) and if your theme or GP (group policy) resets it, you can easily re-run the file to update it to '1' again.

Next, navigate over to C:\Windows\System32\oobe\info\backgrounds\ (you may need to create the \info\backgrounds folder if it does not already exist) and replace your backgrounddefault.jpg file with one of your choice.  Being sure to match the resolution of your display.  Also, there are a number of naming conventions for the files contained within this folder for purposes of matching various resolutions, which is beyond the scope of this tutorial.

There are a number of small programs that will handle this task for you.  Here is one of themHere is an alternate tutorial covering Windows 7 through 10.

That's it, folks!

Wednesday, January 19, 2011

MS SQL: Updating columns to match another column (different tables)

Updating can be kind of tricky and time consuming if there are a lot of rows being affected.  The task is especially cumbersome, or seems so, when updating a particular column from one table with data in a column from another table.

The simple SQL query to accomplish this is:


update t1
set t1.c1=t2.c1,
t1.c2=t2.c2
from table1 t1
inner join table2 t2
on t1.col=t2.col

In this script example, we are updating table 1 (t1) by setting a column (t1.c1) to the value of the column of table 2's column (t2.c1) - the next line shows another column being updated with the same table two, but using a different column.


Next, we are telling it to take this information from table 1 t1 - the t1 is the alias of table 1.  Then we join table 2 (t2) into the query with the INNER JOIN statement.  The join basically says that table2 is using alias "t2" and that we want column 1 in table 1 to equal column 1 in table 2 for our equality condition to be met.  So, if column 1 in table 1 is apples and column 1 in table 2 is apples and the column we are updating is "price", then we would see something like this:


update t1
set t1.price = t2.price
from table1 t1
inner join table2 t2
on t1.apples=t2.apples

Pretty simple stuff.  Drop me a comment if you have any questions.

Sunday, July 04, 2010

DBCC INDEXDEFRAG and DBREINDEX

DBCC commands are some of the most misunderstood, yet essential to anyone maintaining a MSSQL database.

I work with MSSQL databases daily and found http://blogs.msdn.com/b/teamcenteronsql/ to be indispensable when trying to determine to use DBCC INDEXDEFRAG or DBCC DBREINDEX.

There are some main points to this MSDN blog...

DBREINDEX works to resolve "extent" or physical fragmentation
DBREINDEX uses shared locking, so only SELECT statements can be used
INDEXDEFRAG works to resolve logical fragmentation, but does nothing for physical or "extents"
Physical disk, i.e. the hard drive, defragmentation can cause "extent" fragmentation in the database, so if we are to scan a disk for fragments and decide to defragment that disk, be sure to run DBCC SHOWCONTIG afterwards to see how the "extent" fragmentation holds up and if you will then need to run DBREINDEX to resolve the issues cause by defragmenting the hard disk.

This information helped me and I hope someone else finds it equally useful.

Saturday, February 13, 2010

Rebuilding a MSSQL 2005+ Master Database

When you find yourself unable to log into your Microsoft SQL database - first check that the service is running. If the service is not running, then you might have a corrupt MASTER system database. So then you ask... How do I fix that?

In MSSQL 2000, the task is a bit different because there is a utility in the binn folder that is not present in MSSQL 2005 or greater. To fix/rebuild the master system database, one has to go through the setup process instead.

I've explained how to do this with a command-line command at my www.enkognedo.com site. Just visit there and you will find what I had to do, why most of the on-line resources miss the target a bit, and a resource link to Microsoft that gives more detail.

Here is the link: http://bit.ly/diWPv5

Friday, March 13, 2009

AOL and OpenID

I am not sure why it is so difficult to find the format for using AOL and OpenID or any OpenID for that matter. Not even Wikipedia has this information.

To sign in to a site supporting OpenID with AOL screename credentials, simply use the following format:

openid.aol.com/username

It really is just that simple. Too bad most sites talking about OpenID talk about how to setup your own OpenID - mostly developer speak, but nothing on how to actually login - unless you really dig for it.

Thursday, March 12, 2009

Checking Database Integrity

There are at least two commands one can run to check the integrity of a MSSQL database. They are:

DBCC CHECKCONSTRAINTS

and

DBCC CHECKDB

The latter actually runs the following inclusively, so unless you want to be extremely granular about your process, you only need run DBCC CHECKDB:

  • Runs DBCC CHECKALLOC on the database.
  • Runs DBCC CHECKTABLE on every table and view in the database.
  • Runs DBCC CHECKCATALOG on the database.


Here is Microsoft's excellent reference:
http://msdn.microsoft.com/en-us/library/ms188796.aspx

Friday, May 30, 2008

HostMonster.com

It is fairly obvious there are a great many web hosts to choose from out there. Some better than others. Some with more or less options than the other, but most don't offer unlimited domains for $6.95 a month! Some might, but they typically sacrifice another feature that may be important to you. Before this month ends, I want to recommend HostMonster.com for your hosting needs. Give them a run and you'll see the difference!

Monday, May 05, 2008

Firebug can make Gmail slow

Here is a tip from the Gmail help site about editing your Firebug settings to work better with their Gmail application and other Ajax intensive sites:


Firebug can make Gmail slow

For the best Gmail performance, we suggest disabling Firebug for www.google.com.

Windows or Linux Users

To disable Firebug:

1. Click the green or red icon in the bottom right corner of the browser window to open Firebug.
2. Click the bug icon in the top left corner of Firebug and select 'Disable Firebug for mail.google.com.'

If you'd like to keep Firebug running, you may improve Gmail performance by following these steps:

1. Click the green or red icon in the bottom right corner of the browser window to open Firebug.
2. Click the Console tab.
3. Select Options.
4. Uncheck Show XMLHttpRequests.
5. Click the Net tab.
6. Select Options.
7. Check Disable Network Monitoring.

Mac Users

To disable Firebug:

1. Click the green or red icon in the bottom right corner of the browser window to open Firebug.
2. Click the bug icon in the top left corner of Firebug and select 'Disable Firebug for mail.google.com.'

If disabling Firebug for Gmail doesn't improve performance results, you may have to entirely disable Firebug.

Wednesday, April 09, 2008

Using sedo.com to advertise domains for sale

I signed up with Sedo.com's free domain parking service the other day. Of course, the hope is that they will advertise my parked sites enough to spark some buying interest. There are so many site out there these days, I'm not sure they will ever move off the "shelf".

Here is what I'm selling:

Wednesday, January 23, 2008

Creating an Ajax capable database using mySQL (Part 1)

I'm not going to spend a lot of time explaining how this works up front, however, if any of you reading this would like more information, please let me know. The first set of code belongs to your main page. I'm using .php extensions, so, everything except for the javascript code ends that way. You'll find some of the code is not relevant to the database itself, such as the W3C xhtml and CSS validations. Here is the index.php code:

<div id="container">
<div id="form1">
<form id="myForm" action="">
<fieldset>
<legend>Movie Database</legend>
<p>
<label>Title:</label>
<input tabindex="1" type="text" name="title" id="title" accesskey="T"/>
</p>
<p>
<label>Genre:</label>
<select tabindex="2" name="genre">
<option value="Unassigned">Unassigned</option>
<option value="Action">Action</option>
<option value="Comedy">Comedy</option>
<option value="Dark Comedy">Dark Comedy</option>
<option value="Docu/Edu">Docu/Edu</option>
<option value="Drama">Drama</option>
<option value="Family">Family</option>
<option value="Fantasy">Fantasy</option>
<option value="Horror">Horror</option>
<option value="Romance">Romance</option>
<option value="Sci-fi">Sci-fi</option>
<option value="Suspense">Suspense</option>
<option value="Thriller">Thriller</option>
</select>
</p>
<p>
<label>Release Date:</label>
<input tabindex="3" type="text" name="release" />
[yyyy]</p>
<p>
<label>Run Time:</label>
<input tabindex="4" type="text" name="run" />
[minutes]</p>
<p>
<label>Rating:</label>
<select tabindex="5" name="rating">
<option value="Unassigned">--</option>
<option value="NR">NR</option>
<option value="G">G</option>
<option value="PG">PG</option>
<option value="PG-13">PG-13</option>
<option value="R">R</option>
</select>
</p>
<p>
<label>Format:</label>
<select tabindex="6" name="format">
<option value="DVD">DVD</option>
<option value="HD DVD">HD DVD</option>
<option value="VHS">VHS</option>
</select>
</p>
<p>
<label>Notes:</label>
<input tabindex="7" type="text" name="notes" />
</p>
<p class="submit">
<input tabindex="8" type="button" value="Submit" onclick="postForm('myForm');" accesskey="S" />
</p>
<p class="clearform">
<input tabindex="9" type="reset" value="Reset" id="reset" accesskey="R"/>
</p>
</fieldset>
</form>
<form action="inv_query.php" method="get">
<p class="query">
<input tabindex="10" name="Query" type="submit" id="Query" value="Movie Inventory" />
</p>
</form>
</div>
<div id="search_form">
<form action="">
<fieldset id="fieldset2">
<legend>Database Query</legend>
<p><label>Title search:</label>
<input tabindex="11" type="text" id="title_search" onkeyup="showTitle(this.value)"/>
</p>
</fieldset>
</form>
<br />
<div id="txtHint"></div>
</div>
</div>
<div id="w3c1">
<ul><li> <a href="http://validator.w3.org/check?uri=referer"><img
src="images/2valid-xhtml10-blue.gif"
alt="Valid XHTML 1.0 Transitional" border="0"/></a></li>
<li>
<a href="http://jigsaw.w3.org/css-validator/">
<img style="border:0"
src="images/2valid-css2-blue.gif"
alt="Valid CSS!" />
</a></li>
</ul>
</div>
<script type="text/javascript" language="JavaScript">
document.forms['myForm'].elements['title'].focus();
</script>

Sunday, October 28, 2007

What is the purpose of this blog?

The main purpose is to share what I learn about varying elements of web development and possibly some programming or maybe script programming. Writing about what I learn helps me to think through the intricacies more deeply and fully grasp that which I recently read.

During the last several years, I've been studying a Computer Information Management curriculum that recently brought me to Visual Basic 6.0. The course instructor is quick to admit that Visual Basic is not a hugely powerful programming language, but is being taught first as it is easier to learn and will build a solid foundation and strong habits for learning more complex programming languages.

As I delve further into the basics of Visual Basic - no pun intended -, I am starting to see a lot of applications for it. I love how the book explains each step in extremely basic steps. The fluidity of the examples and lessons is unsurpassed, as it offers a meaningful approach. I'm at work, or I'd give kudos to the title and author of the course, which currently escapes me.

I'll certainly keep everyone up-to-date with my progress and share some examples of what I've mastered. Please feel free to share yours.

What does the blog title "mean"?

I pondered changing the title of this blog today to eliminate the word "partial", however, I find it fitting after some thought. Normally, one would see "Your perception is my reality" or some mix thereof. I disagree with this, in that, as I'm suggesting this: What you perceive is another individuals' reality or is it? What you see may only be part of the truth, all of it, or none of it. With this said, there is no logical basis to calculate the validity of one's perception over that of an individual standing, say, across the street that you have never met.

So, as we can see, there are many variables to determine the reality of another. My reality is an assessment of that which I think I know. Since there really isn't a method to give absolutes to an assessment without actually engaging the subject, then there is no surety to be had. One can only surmise by the factors surrounding the object in question as to what is really happening or what attributes appear to affect it by such reality we have learned based on our own bias.

With significant certainty, we can now implicate the term "partial" into our objective hypothesis by stating "Perception *is* partial reality" given it "fits" what we can say we know, but may not necessarily know.

Now here is a question for you: What do you think the title "Perception is partial reality" means, or more precisely, what does it mean to you?

Wednesday, August 22, 2007

Nesting and Centering div elements

Designers struggle frequently with proper nesting and centering of div elements. I've found, from reading many sources, the best way to take control of your elements is to surround them completely with a div container.

Div containers can be centered and manipulated just about anyway you see fit. Once the "container" is established, one can have seemingly perfect control of design - whether location of internally nested divs, centering, colors, the list goes on.

I've written about centering before. Recently, for whatever reason, I've had much better success with using this style for centering: margin: 0 auto (this means to make the margin equal 0 on the top and bottom and for the sides (left/right) to be auto aligned. Keeping in mind the clockwise approach to remembering single-line declarations, so the above style can also be written as margin: 0 auto 0 auto, more clearly, margin: W X Y Z, where W=top, X=right-side, Y=bottom, and Z=left-side.

Saturday, May 27, 2006

CSS, XHTML, and Centering your Web

Centering your web page can be an issue. I looked around the web to find a myriad of information about how to use auto margins and, frankly, hacks that will only work in one browser and maybe another. As an avid MySpace user, I used MySpace as a resource to find how to change my blog look and found a blog there that gave me invaluable insight on how to center a web page. It's really fairly simple; you will be as surprised as I was.
First, I'm going to show you the HTML/XHTML code. I'm not going to show ALL of the code, just what you need to mess with in order to get the page centered. You will start with the <body> tag and then follow with <div> tags. You will normally have more than one <div> element (this is important) that is "contained" by a single "container" <div> element; as follows:
<body>
<div class="container"> <!-- this is your container DIV -->
<!-- below are the rest of your DIV elements -->
<div>
<p>Content Here</p>
</div>
<div>
<p>More Content Here</p>
</div>
<div>
<p>Even MORE Content Here!!</p>
</div>
</div> <!--this final closing DIV closes the first DIV with a class of "container" -->
</body>
So, you have 3 different DIV elements within a single DIV "container". This is how we affect the alignment of ALL the contained DIVs. I do not recommend using table tags at all. Tables are being deprecated with exception only to tabular data. There's nothing you can't do with XHTML/CSS, so I encourage you to use it.
The following is the important code to use with CSS to make your page center. It may seem confusing at first, but it's really very, very simple! You must define a width of the page, say, width: 700px. Then, you need to bring the whole container back HALF the size of the width using the margin-left attribute; margin-left: -350px. Next, you will tell the screen to position itself 50% of whatever the resolution is (the beauty of this is, no matter what the resolution is of the viewer, your page will always be centered. You do this using the left: attribute and assigning it as such: left: 50%. Here's the CSS:
body {
margin: 0;
padding: 0px;
background: #000;
color: #fff;
border-style: none;
}
div.container {
margin: 0;
padding: 0;
width: 700px;
margin-left: -350px;
left: 50%;
position: absolute;
}
//*then the rest of your CSS code for your other DIVs may follow - Remember, you should assign a "class" to all DIVs you wish to affect separately, otherwise, simply putting div { whatever in }, will result in ALL unclassed DIVs taking on the SAME format, positioning, etc... *//



Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. Great rates starting at 1¢/min.

Sunday, April 16, 2006

Web page structure - the beginning.

Here's how it all begins. Once you have chosen a DTD (document type definition), you will add several things called tags to your page to layout the page for you to begin inserting html or xhtml code giving your page a distinct look.

Let's build from the last post. I am going to use notepad for this demonstration, but remember, any text editor that doesn't insert any special formatting codes will work.

<?xml version="1.0" encoding="utf-8"?>
<!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" xml:lang="en" lang="en">

<head>

<title>Insert your page title here</title>
<meta http-equiv="content-type"
content="text/html;charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
</head>

<body>

<p>---Create Your Page In This Area---</p>

</body>
</html>


Where the <p> tag is used above, can also be used a <div> tag. I try to use <div> tags wherever possible for page layout and design.

Saturday, April 15, 2006

XHTML - Where to begin.

When you're creating a web page, one of the easiest ways to create a lean and clean set of xhtml code is to begin with your "doctype". The doctype declares to the reading browser (the browser you are using to view your pages) what to expect and how to interpret it. So, if you don't tell the browser anything at all, it reads everything in what is called "quirks" mode, which may or may not display your pages as intended. Bottom line - always use a doctype. And why xhtml? Because it is where everything is going or has gone. There are some basics you should know about xhtml, so you may wish to visit the w3schools site, which will provide you with all and more than you ever wanted to know about xhtml, css, and html.

I typically use the transitional form of the doctype, as follows:

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


For more information on choosing a doctype, follow the links below:
http://www.htmlhelp.com/tools/validator/doctype.html

http://www.w3.org/QA/2002/04/valid-dtd-list.html





After choosing a doctype, open your favorite text editor and insert it as the first line. Be sure you are not using an editor that may insert its own code after saving the file and when you do save the file, choose "save as..." and create a name of your choosing and extend it with .html, i.e., your_filename.html.

CSS, XHTML, and how it all started for me.

For years I envied web pages and especially personal ones. I wanted to create my own, but was always too busy to even fathom where to begin. Up until the last six to nine months, I knew little if anything about creating a web page. Now, I have a simple web page I created with the help of Macromedia Studio 8, a lot of reading, tutorials, and more reading. I haven't finished all the books I bought. Most of the help I've gotten are from reading pages and pages of blogs and help sites for web design. The web has proven to be an invaluable resource which jumpstarted me to where I am now.

Like so many others out there, I want to write a few pages, at least, about web design to help you jumpstart your design ideas. One thing I know for sure, most of the design it with your creative talent. If you don't think you're creative, just try a few things with some code from already created pages and soon you'll come up with your own ideas to implement.

Stay tuned for some real basics on where to begin.

New beginnings

Maybe I'll actually do a little something with this new blog. For some reason "blogger.com" has managed to evade my spurious web surfing. It looks cool and a blogring over at Xanga brought me here. I signed up for an HTML, XHTML, & CSS blog on Xanga and one of the users, who hasn't posted anything since 2004, commented Xanga didn't give enough flexibility to allow full use of XHTML. I've found XHTML use with Xanga is relative to the use of div tags and inserting the proper header information, i.e., inputting your own header. I'll write more later. Stay tuned.