Recently, I was looking around for cars.
Lol, not those looking around at cars but me wanting to buy a car.
It's about time for a 23 year old working guy to get a car of his own, don't you think?
I've been scouting around but some car dealers are quite stuck-up, if you know what I mean.
I walked into most showrooms and the salesman would give a me "can-you-afford-it" look.
Well, if they have that kind of attitude, then sorry, they will not have my business.
I mean, if I can't afford a car, why would I go and look for one, right?
So I was telling my friend about my car search experience and he told me, why the hassle?
He recommended me a website with a comprehensive Malaysia cars catalogue in it.
For me, it was so convenient. At least I do not have to face some crappy attitude.
This website contains over 1,400 cars which are available in Malaysia.
Like I've said, it is comprehensive and also a user-friendly website.
The website is simple with a categorized car manufacturer menu at the side to allow faster searching.
Users are also able to filter which area/state they are looking for cars in.
Additionally, people who wishes to sell off their car, they could register with them and post their car advertisement on the website.
For those who are looking to buy a car, like me.
If I would like to know more about the car, all I have to do is click on the "more info" link at the bottom right of the car which I find to my liking, and I would be brought to a page which contains a more detailed info of the selected car.
Here are a few screenshot of the website:
Note: Click on the picture to view a larger version.
The website even have a Facebook page to allow users who have a Facebook account to keep themselves up-to-date with the latest happenings.
Top Car Website in Malaysia
Find Room Rentals in Malaysia
There are many reasons for a person to want to find a room to rent. Whatever the reason may be, the good thing is there is plenty of rooms for rent here in Malaysia.
Personally, I’ve rented and still renting a place. I’ve rented a RM 700 bungalow room and now a RM 1200 condominium with my friend.
If you’re here to find room rental, then it’s the right place. Just click on the link. The website provides a lot of good and decent information for users to find their required room rental specification. There are nearly 30,000 rooms listed in there.
It has a list of most desired places which most people would like to rent a room at. All you need to do is click on the ‘Rooms’ tab and begin searching for your room specifications or you could just click on the links which are provided at the left of the screen in the ‘Rooms’ tab to filter which location you would desire. Is that simple!
If you’re from the outskirts of Malaysia, I would recommend to search central places like PJ or Damansara. If you’re a student, then obviously you would want to rent somewhere near your campus. Whatever your requirement is, the website is the place to start! Cheers all!
New Prospects
It's been 3 months since I joined Panasonic and things had turned out to be great.
[ASP.NET] [C#] Switching MasterPage Dynamically
Have you ever wanted to changed a MasterPage of an ASPX webpage dynamically when your website is running? Well, I’ve recently encountered this problem myself too and found a solution to it. So without further ado, I present the solution to you!
First go to your code-behind page of the .aspx page which you wish to have its MasterPage changed dynamically. Let’s say for example, you want your example01.aspx to change its MasterPage dynamically, you have to open the example01.aspx.cs page.
Ok here’s the step-by-step walkthrough.
Step 01:
Enter the following code below at anywhere in the public partial class section
Code:
protected void Page_PreInit(object sender, EventsArgs e)
{
}
Explanation:
The MasterPage needs to be defined before the .aspx page is initialized. In simpler terms, without the MasterPage predefined before the .aspx initialized, the .aspx page have no where to be loaded to, because webpages of website which utilizes MasterPage normally and most certainly requires a ContentPlaceHolder for it to be loaded into.
Step 02:
Enter the following code in the Page_PreInit body
Code:
MasterPageFile = “YourMasterPage.Master”;
Step 03 (optional):
Incorporate conditions with the code. What’s the point of changing MasterPage dynamically if there’s no conditions in the first place, right? The fact that we want to dynamically switch MasterPages, there has to be a condition. Therefore, incorporate them!
In my case, I determine the user type. If the user who logs in is an admin for example, I will display a MasterPage for admins, if its a user, I’ll display a MasterPage for users.
The code should look something like this:
protected void Page_PreInit(object sender, EventArgs e)
{
string redirect_from = ((string)Request.QueryString["redirectedfrom"]);if (redirect_from == "staff")
{
MasterPageFile = "~/MasterPage/StaffMaster.master";
}
else
{
MasterPageFile = "~/MasterPage/AdminMaster.Master";
}
}
The code above shows the way I incorporated conditions to the code which triggers it to switch MasterPage if a certain user type logs in. If you’re wondering what’s with the “~/MasterPage/”, it is because I stored all my pages in their respective folders and my MasterPages are stored in a folder named MasterPage.
Safe trip friend!
This blog entry is dedicated to my friend and my role model in programming, In Ming. He is going abroad to further his studies in a few days time and I would like to wish him to have a safe trip there.
We met during college. In the start we weren’t really friends, maybe just acquaintances. However, as the course of our study progress, we became familiar with each other’s circle of friends and started to get to know each other better. At first, I didn’t know he’s interested in programming until one of the subject’s assignment brought me to the knowledge of it.
From then on, whenever I had a ‘coding-block’, I would consult him and discuss the matter and he never fails to point out what I am doing wrong. Then we attended a Java seminar together at KLCC and I got to know him a little better. I remember during our ride in the LRT heading towards KLCC in the morning we kept discussing about what program that has not exist yet that would make a revolution if it was created. Talks like this really feels good. You have a friend of similar interest and you talk about the possibilities, it really motivates you in that field of interest you’re sharing.
After graduating from college, I started working due to certain shits that happened, while he went on with his degree. I remember there was one time where I had this really huge ‘coding-block’ and I had to consult him. We met up at Starbucks SS2 and we discussed for hours and he found a solution. I was astonished, I kept reading and re-reading his codes because the solution was rather complicated, but most of all, I’ve learnt something new. Hence, I call him my teacher, lol.
He told me that he’s going abroad to further his studies for 1 year or maybe more than 2 years if he’s doing masters there. When it is possible, I hope I could visit him there and catch up. It’s really hard to find a friend with similar interest such as programming, so I’ll do my best to keep in touch. Take care man! and have a safe trip!!
Petaling Jaya - Top Serviced Apartments
Kuala Lumpur, a -city that never sleeps-, and literally next to it is a -city that rarely rests-, Petaling Jaya!
Petaling Jaya is a great place to live it apart from Kuala Lumpur. If fact, for those who loves nature more than concrete jungle, it is meant for you. It's location is central and convenient! because it is right next to KL!
There are tons of Shopping malls in Petaling Jaya and my very own favorite category apart from shopping, is -food-!!
You would definitely want to live in PJ if given an opportunity, I know I would!
Wait.. in fact, I am! and it's been great. If you hadn't found a place to live in PJ yet, then this is the right time for you because there are a few great serviced apartments which are located here in PJ. Furthermore, the places which I'm going to recommend are located really close to a cluster of great Shopping malls. The good news is, you'll be able to witness brilliant fireworks during special occasions right off your window or balcony without needing to go through all the traffic!
Here are some of the top serviced apartments here in PJ, Kota Damansara to be exact!
1) Ritze Perdana
2) Ritze Perdana 2
3) Metropolitan Square
4) Neo Damansara
5) 1 Bukit Utama
If you would like to browse more great places by your own, I recommend you to visit this website: http://www.propwall.my/petaling_jaya
[ASP.NET][C#] ASP page loading twice
Reason behind this post is because I would like to document all the problems I had encountered and the solution for my and all visitor's convenience in the possible future.
As the titled states; I've recently, to be exact, 2 days back, encountered this strange phenomenon whereby my asp page loads twice when I click on the button, asp:imageButton to be exact. I'm working with this search function you see. I have to pass a value from this page, back to this page. Don't get it?
Let's say, I have a webpage called report.aspx. There's a search function inside, and after the user entered a value, the user has to click on a button to pass that value for a search, right? yea, so, I stored the value using Session, as I thought it was the most convenient and efficient way to pass a value from report.aspx back to report.aspx because the page has to be posted back in order to fire off the next function.
However, as convenient as it may seemed to be, the downside of Session is that it stores in two places at the same time; the server side and the client side. Hence, the page loads twice.
Advance explanation: the first click of the button stores the Session on the Server side but not the client side. Therefore, it only updates the Server side and not the Client side. Which means, the user has to click on the button twice then only the user could view the updated page with the search result.
Solution:
Dispose the use of Session and replace it with QueryString. Problem solved.
I'll assume that everyone who are reading this knows how to work a QueryString. If you have any inquiries or need a pointer, feel free to drop me a comment and I'll get back to you. Cheers all!!
Life Check
We’re another year older and perhaps another year wiser. Why wiser? because everyday is a new experience. Even reading a newspaper full of government crap is something new. If we read about something new each day for a year, it means we’ve learnt 365 new stuffs.
Even if we encountered difficult situations, it is still something new, in a way.
“When written in Chinese, the word ‘crisis’ is composed of two characters. One represents danger and the other represents opportunity.” – John Fitzgerald Kennedy
I have learnt not much but not too little either. Leastwise I’ve learnt a tiny bit about the people around me, be it colleagues, friends or the crappy P1 WiMAX customer service officer.
To many people, New Year is just an excuse to fabricate a less-than-likely-to-be-achieved resolution (plentiful will never be achieved, fact). On the other hand, New Year to me is a new job prospect, with a different position, company, colleagues, experience, environment and most importantly salary figure – AND – not forgetting, knowledge!
Ironically, even though most New Year resolution is most likely never to be achieved but here I wish to make a resolution to mend dented relationships, be it family, friends or love. No man is an island. Therefore, it’s good to ensure that your relationship with the people you care are well nurtured =) I guess that’s all for now. Happy New Year all, cheers!