Gemini Personality traits
This is the chat sign. They love to talk and will even do so with strangers standing in line at the grocery store. Communication is a need for this adaptable individual. They are witty and intellectual. Some might even consider them eloquent. Able to keep up with younger people, they are seen as youthful and lively.
Gemini’s tend to know a little about everything. Their quick ability to assimilate knowledge makes them easily bored and ready to move onto another project. This sign needs spice to their life. They are very logical, rational people.
Needing lively, intellectual rapport with love partners, they look for more educated people. These partners can be educated formally or by experience. Gemini’s lover should express definite opinions. Otherwise, they can be run over by the Gemini who loves to argue and express their own opinions. Geminians have problems trusting their emotions entirely. Their logical, rational minds come into play any time they are overwhelmed by emotion.
Versatility in communicative skills should be the place a Geminian looks for work. The media, sales, department stores, advertising and commercial travelers are all good careers for the witty Geminian. If you put the Gemini personality into a job that does not challenge him in a different way each day, you have a very unhappy person indeed.
Unafraid to take advice from others who have done their jobs before, they actively seek counsel. Geminians are not overly ambitious but seem to be where money is to be made. Their imagination acts as a catalyst for whatever they want. In short, they enjoy success before it is really achieved.
A Gemini, even in retirement, is anything but retired. They want to keep busy and generally do with something to keep their interest.
This sign has loads of nervous energy and need something on which to burn it off. They are not the strongest of signs in the Zodiac but they are forever young. Gemini rules the lungs and as such should watch anything having to do with breathing such as a chest cold or bronchitis. People born under this sign should never smoke.
Gemini Keywords
Adaptable
Versatile
Communicative
Witty
Intellectual
Eloquent
Youthful
Lively
Nervous
Tense
Superficial
Inconsistent
Cunning
Inquistive
Gemini Symbol
Twins
Gemini Planet
Mercury
Gemini Part of the body it rules
The Lungs
Gemini Gemstone it rules
Agate
Flowers it rules
Lily of the Valley
Lavender
Maidenhair
Myrtle
Fern
Color it rules
Yellow
What is your zodiac?
One of computer books that I really like is Andrew Hunt and Dave Thomas' book, "The Pragmatic Programmer: From Journeyman to Master." Below is the characteristic of a pragmatic programmer, excerpt from the book:
Each developer is unique, with individual strengths and weaknesses, preferences and dislikes. Over time, each will craft his or her own personal environment. That environment will reflect the programmer's individuality just as forcefully as his or her hobbies, clothing, or haircut. However, if you're a Pragmatic Programmer, you'll share many of the following characteristics:
* Early adopter/fast adapter. You have an instinct for technologies and techniques, and you love to trying things out. When given something new, you can grasp it quickly and integrate it with the rest of your knowledge. Your confidence is born of experience.
* Inquisitive. You tend to ask questions. That's neat--how did you do that? Did you have problems with that library? What's this BeOS I've heard about? How are symbolic links implemented? You are a pack rat for little facts, each of which may affect some decision years from now.
* Critical thinker. You rarely take things as given without first getting the facts. When colleagues say "because that's the way it's done," or a vendor promises the solution to all your problems, you smell a challenge.
* Realistic. You try to understand the underlying nature of each problem you face. This realism gives you a good feel for how difficult things are, and how long things will take. Understanding for yourself that a process should be difficult or will take a while to complete gives you the stamina to keep at it.
* Jack of all trades. You try hard to be familiar with a broad range of technologies and environments, and you work to abreast of new developments. Although your current job may require you to be a specialist, you will always be able to move on to new areas and new challenges.
Are you a pragmatic programmer?
There is a company that ask their candidates to answer a puzzle before applying for their opening job. You can find the puzzle here.
Well, I just want to trying to have a nostalgia with my past time when I was in college. So, I wrote 3 type of the solutions using JavaScript, here they are:
<script class="Solution1" language="javascript">
var agroup = ""
var nextCounterToPrint = 5;
var currentCounter = 0; //just for increasing speed
for(var i = 1; i <= 1000; i++){
agroup += i.toString();
currentCounter++;
if(currentCounter == nextCounterToPrint){
nextCounterToPrint = (nextCounterToPrint == 5) ? 3 : 5;
currentCounter = 0;
if(!isFirstTime(i)){
agroup = "*" + agroup;
}
document.write(agroup);
agroup = ""
}
}
function isFirstTime(i){
return (i == 5);
}
</script >
<script class="LineBreak" language="javascript">
document.write("<BR>");
</script >
<script class="Solution2" language="javascript">
var printed = 0;
var toggled = false;
for(var i = 1; i <= 1000; i++){
document.write(i);
printed++;
if(printed == 5 && !toggled)
{
document.write("*");
printed = 0;
toggled = true;
}
else if(printed == 3 && toggled && i < 1000){
document.write("*");
printed = 0;
toggled = false;
}
}
</script >
<script class="LineBreak" language="javascript">
document.write("<BR>");
</script >
<script class="Solution3" language="javascript">
var lists = [5,8,13,16,21,24,29,32,37,40,45,48,53,56,61,64,69,72,77,80,85,88,93,96,101,104,109,112,117,120,125,128,133,136,141,144,149,152,157,160,165,168,173,176,181,184,189,192,197,200,205,208,213,216,221,224,229,232,237,240,245,248,253,256,261,264,269,272,277,280,285,288,293,296,301,304,309,312,317,320,325,328,333,336,341,344,349,352,357,360,365,368,373,376,381,384,389,392,397,400,405,408,413,416,421,424,429,432,437,440,445,448,453,456,461,464,469,472,477,480,485,488,493,496,501,504,509,512,517,520,525,528,533,536,541,544,549,552,557,560,565,568,573,576,581,584,589,592,597,600,605,608,613,616,621,624,629,632,637,640,645,648,653,656,661,664,669,672,677,680,685,688,693,696,701,704,709,712,717,720,725,728,733,736,741,744,749,752,757,760,765,768,773,776,781,784,789,792,797,800,805,808,813,816,821,824,829,832,837,840,845,848,853,856,861,864,869,872,877,880,885,888,893,896,901,904,909,912,917,920,925,928,933,936,941,944,949,952,957,960,965,968,973,976,981,984,989,992,997];
for(var i = 1; i <= 1000; i++){
document.write(i);
if(i == lists[0]){
lists.shift();
document.write("*");
}
}
</script >
Which one do you think is the best one? Or maybe you have another solution, please share!
OK! You want to know how to merge GridView header? There are many ways to do that, you can inherit the GridView control and override its render method or you can override the render method directly without subclassing it like this one.
There is another way, the JavaScript way :). Let's say you have this grid:
You want to merge it cells into this one:
Here you goes:
1. Add a new GridView into your aspx
<asp:GridView ID="GridView1" runat="server" BackColor="LightGoldenrodYellow" BorderColor="Tan"
BorderWidth="1px" CellPadding="2" ForeColor="Black" GridLines="None">
<FooterStyle BackColor="Tan" />
<SelectedRowStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
<PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
<HeaderStyle BackColor="Tan" Font-Bold="True" />
<AlternatingRowStyle BackColor="PaleGoldenrod" />
</asp:GridView>
2. Bind it to a data source
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
GridView1.DataSource = getDataSource();
GridView1.DataBind();
}
}
private object getDataSource()
{
DataTable dt = new DataTable();
dt.Columns.Add("NIM");
dt.Columns.Add("First Name");
dt.Columns.Add("Middle Name");
dt.Columns.Add("Last Name");
dt.Columns.Add("High School");
DataRow dr = dt.NewRow();
dr["NIM"] = "0331970399"
dr["First Name"] = "Irwansyah"
dr["Middle Name"] = ""
dr["Last Name"] = "Irwansyah"
dr["High School"] = "SMAN 16 Palmerah"
dt.Rows.Add(dr);
return dt;
}
3. And these is the trick code, make sure to put it below the GridView
<script language="javascript">
//this pageLoad will only works if you are using ASP.Net AJAX
//if you're not, you can use the other way.
function pageLoad(){
var grid = document.getElementById('<%=GridView1.ClientID %>');
var firstRowHeaderClone = grid.tBodies[0].rows[0].cloneNode(true);
grid.tBodies[0].insertBefore(firstRowHeaderClone, grid.tBodies[0].rows[0]);
//get a reference to first and second row header
var firstRowHeader = grid.tBodies[0].rows[0];
var secondRowHeader = grid.tBodies[0].rows[1];
//delete the NIM cell in second row header
secondRowHeader.deleteCell(0);
//merge the NIM cell in the first row header
//to the cell below it
firstRowHeader.cells[0].rowSpan = 2;
//delete the First Name and Middle Name cell
//in the first row header
firstRowHeader.deleteCell(1);
firstRowHeader.deleteCell(1);
//merge the Last Name cell with two cells behind it
firstRowHeader.cells[1].colSpan = 3;
//change the new merged cell's text
firstRowHeader.cells[1].innerText = "Name"
//delete the High School cell from the second row header
secondRowHeader.deleteCell(3);
//merge the High School cell from the first row header
//with cell underneath
firstRowHeader.cells[2].rowSpan = 2;
}
</script>
This trick works with Firefox 2.0.2 and IE 6.0. I have tested it by myself. OK. Its time to say thanks to JavaScript :).