Thursday, December 28, 2006

youtube rocks...

You never gonna guess who this is...

One of the greatest guitarist of all time... Jimmy Page at age 14. This legend is a real master in making unique sounds and glorious music from guitars that no other human can even invent. When I first started listening to Led Zeppelin... figure I was around 10 years old then... there was instant joy and happiness. Some people say you are happy when in awe... like standing in front of a waterfall ... or admiring the amazing art work in the Louvre. I get that same feeling listening to Led Zeppelin over... and over… and over… again. Am gonna be 32 in 2007, their music still inspires.





This one is another classic. Johnny Cash and his wife June on the Tonight Show with Carson. This is really a cool time for musicians and fans .. the 70s and 80s. Just look how she talks... not like the Britneys or Paris we have today. Most pop female singers (ok... lets throw in male rappers, crappers and boy bands) today have no talent and zero brains. Even the girls with awesome talent like Gwen Stefani has jumped ship... sad times we live in.



Labels:

Wednesday, December 20, 2006

beauty in the eyes of the beholder...

Artists since the beginning of time try their very best to capture and paint the beauty of the female face. Somehow potraits are just plain potraits cause they only try to capture the best facial features of the subject model. A master artist on the other hand.... captures the emotions, sadness, trauma, silence, pain, joy, happiness and inner desires in their painting... this is a skill Picasso and Da Vinci have... and thats why their works are priceless.

This is what we are faced with today... artificial beauty.. click play.


Labels:

Wednesday, December 13, 2006

point decimal.. code

In ArcGIS 9.1 ... its kinda hard to select a point and display the coordinates in complete decimals... cause it gets truncated. You can try to use edit sketch to see the points... but the decimal placings is not complete.

Here is an ArcObject code that can do both:

Private Sub MovePointTo()
Dim pInput As String
Dim pOrigPoint As IPoint
Dim pFeat As IFeature
Dim pEnum As IEnumFeature
Dim pX As Double
Dim pArea As IArea
Dim pEnv As IEnvelope
Dim pY As Double
Dim pDestPoint As IPoint
Dim pMx As IMxDocument
Set pMx = ThisDocument
If pMx.FocusMap.SelectionCount = 0 Or pMx.FocusMap.SelectionCount > 1 Then
MsgBox "select only one point feature"
Exit Sub
End If
Set pEnum = pMx.FocusMap.FeatureSelection
Set pFeat = pEnum.Next
Set pOrigPoint = pFeat.Shape
pInput = InputBox("Enter XY coordinates separated by space: Ex 100 -100")
pVal = Split(pInput, " ", -1, vbTextCompare)
If UBound(pVal) > 1 Then
MsgBox "Enter only XY: Example 212.55 522.11"
Exit Sub
Else
pX = pVal(0)
pY = pVal(1)
Set pDestPoint = New point
pDestPoint.PutCoords pX, pY
Set pFeat.Shape = pDestPoint
pFeat.Store
Set pArea = pFeat.Shape.Envelope
Set pEnv = pMx.ActiveView.Extent
pEnv.CenterAt pArea.Centroid
pMx.ActiveView.Extent = pEnv
pMx.ActiveView.Refresh
End If
End Sub

Private Sub UIButtonControl1_Click()
MovePointTo
End Sub

Labels:

Monday, December 11, 2006

object oriented dotNet apps

Bonjour... over the years there has been a lot of confusion and also misunderstanding of what is object-oriented programming. Many consultants and programmers claim to know object-oriented programming... but its so easy to get distracted. Here is a good anology of what it means in lay man's term:

Object -
Consider that a Car is an object. It has fields and properties, such as Color, Make, Model, Age, GasLevel, and so on. These are the data that describe the state of the object. A Car object might also expose several methods, such as Accelerate, ShiftGears, or Turn. The methods represent behaviors the object can execute. And events represent notifications. For example, a Car object might receive an EngineOverheating event from its Engine object, or it might raise a Crash event when interacting with a Tree object. See... that describes members, methods and events of an object.

Encapsulation -
Returning to the Car example. If a Car object interacts with a Driver object, the Car interface might consist of a GoForward method, a GoBackward method, and a Stop method. This is all the information that the Driver needs to interact with the Car. The Car might contain an Engine object, for example, but the Driver doesn’t need to know about the Engine object—all the Driver cares about is that the methods can be called and that they return the appropriate values. Thus, if one Engine object is exchanged for another, it makes no difference to the Driver as long as the interface continues to function correctly.

Polymorphism -
For example, a Driver object can interact with a Car object through the Car public interface. If another object, such as a Truck object or a SportsCar object, exposes the same public interface, the Driver object can interact with them without regard to the specific implementation of that interface.

Simple huh... its easier to understand this way.

Labels:

Sunday, December 03, 2006

members... types... in DotNet

Halo again... am writting a bit more on .Net variables and data types this time. Its the bits and pieces of programming that makes up a good application. Banking, National Registration, E-Commerce, E-Mails or even computer games at the most basic level uses variables. In any programming language, the result of the application or algorithm requires some user input.... it can be your credit card details, addresses, calculations, pictures, movies, music and much more.

To process or keep this information a smart programmer must know how to manipulate the data correctly. I mean... almost all applications need data to run... and this data comes in many forms and shapes. At the end it all boils down to bits and bytes for the processor to run.

The .NET Framework provides a robust, strongly typed data system. Different types represent integer numbers, floating-point numbers, Boolean values, characters, and strings.

In Visual Basic .NET, Option Strict On enables type checking at design time and prevents type mismatch bugs that could be time-consuming to find otherwise. Whenever possible, you should develop with Option Strict On.

The .NET types provide built-in functionality specific to the type. The Parse method is implemented by all the built-in value types and is useful for converting strings to value types. The String class exposes several useful functions that allow you to easily manipulate strings.

Some samples of number types:

System.Byte - Byte - 8-bit unsigned integer (0 to 255)

System.Int16 - Short - 16-bit signed integer (-32768 to 32767)

System.Int32 - Integer - 32-bit signed integer

System.Int64 - Long - 64-bit signed integer

These store values which are numbers and some of them can be signed (that means positive and negative).

Labels: