கண்ணின்று கண்ணறச் சொல்லினும் சொல்லற்க |
Friday, September 28, 2007
Very Good Morning.
Posted by Rajesh Prabhu. R at 7:12 AM 0 comments
Thursday, September 27, 2007
Very Good Morning.
புறங்கூறிப் பொய்த்துயிர் வாழ்தலின் சாதல் |
Posted by Rajesh Prabhu. R at 6:53 AM 0 comments
Wednesday, September 26, 2007
DllMain in a DLL
DllMain Called with FlagsThere are several conditions where DllMain is called with the DLL_PROCESS_ATTACH, DLL_PROCESS_DETACH, DLL_THREAD_ATTACH, or DLL_THREAD_DETACH flags.The DLL_PROCESS_ATTACH flag is sent when a DLL is loaded into the address space of a process. This occurs in both situations where the DLL is loaded with LoadLibrary, or implicitly during application load. When the DLL is implicitly loaded, DllMain is executed with DLL_PROCESS_ATTACH before the processes enter WinMain. When the DLL is explicitly loaded, DllMain is executed with DLL_PROCESS_ATTACH before LoadLibrary returns. The DLL_PROCESS_DETACH flag is sent when a process cleanly unloads the DLL from its address space. This occurs during a call to FreeLibrary, or if the DLL is implicitly loaded, a clean process exit. When a DLL is detaching from a process, the individual threads of the process do not call the DLL_THREAD_DETACH flag. The DLL_THREAD_ATTACH flag is sent when a new thread is being created in a process already attached to the DLL. Threads in existence before the process attached to a DLL will not send the DLL_THREAD_ATTACH flag. The first thread to attach to the DLL does not send the DLL_THREAD_ATTACH flag; it sends the DLL_PROCESS_ATTACH flag instead. The DLL_THREAD_DETACH flag is sent when a thread is exiting cleanly. There is a situation when DllMain may be called when the thread did not first send the DLL_THREAD_ATTACH flag. This can happen if there are other threads still running and the original thread exits cleanly. The thread originally called DllMain with the DLL_PROCESS_ATTACH flag and later calls DllMain with the DLL_THREAD_DETACH flag. You may also have DllMain being called with DLL_THREAD_DETACH if a thread exits but was running in the process before the call to LoadLibrary. Situations Where DllMain is Not Called or Is BypassedDllMain may not be called at all in dire situations where a thread or process was killed by a call to TerminateThread or TerminateProcess. These functions bypass calling DllMain. They are recommended only as a last resort. Data owned by the thread or process is at risk of loss because the process or thread could not shut itself down properly.DllMain may be bypassed intentionally by a process if it calls DisableThreadLibraryCalls. This function (available with Windows 95 and Windows NT versions 3.5 and later) disables all DLL_THREAD_ATTACH and DLL_THREAD_DETACH notifications for a DLL. This enables a process to reduce its code size and working set. For more information on this function, see the SDK documentation on DisableThreadLibraryCalls. |
Posted by Sundar at 4:08 PM 0 comments
C# Tips
I am working in C# 2005 1.Modal Dialog and Modeless Dialog in C# Modal Dialog and Modeless Dialog in C# : Class Form2 } class Form1 frm.Show() ;// For Modeless Dialog 2.C# MDI forms Wecan display more than one forms at a time in MDI forms. For the parent Form, we have to enable the IsMdiContainer property as true. and then drill down in to the coding as follows : class ChildForm private void mnuShowChildForm_Click()
while opening the chm file, sometimes it displays the dialog with "always ask before opening this file" check box. if this check box is not selected by us then it will not display the chm contents. So To display the chm file contents, we must enable "always ask before opening this file" check box. 4.CheckOnClick property in a menu item Sometimes we may need Checked property in a menuitem. For Instance, if the user selects the menuitem then it will show the Checked mark in a menuitem and if we select once again, the checkbox will if we enable this property, then we can display the check mark and we can change the execution behavior also based on the check mark. CheckedState property is set to true or false based on whether the check mark is currently displayed in a menuitem or not. This feature can be aptly used in the following Scenario. if we have MDI parent form, based on the checked selection of the menuitem we have to display the MDI child form.
hided... By default set the menuitem's CheckOnClick property as true and Checked property as false. For doing this one , add the menu event handler as follows : void mnuShowChildForm_Click()
|
Posted by Sundar at 1:11 PM 0 comments
Very Good Morning.
அறனழீஇ அல்லவை செய்தலின் தீதே |
Posted by Rajesh Prabhu. R at 6:48 AM 0 comments
Tuesday, September 25, 2007
Micro camcorder dubbed the 'world's smallest'
There's no shortage of " world's smallest camcorders," but Spy Gadget's Micro Camcorder is definitely one of the most diminutive that we've seen. Designed to actually slip inside an empty pack of gum, this device features a "one touch record button," captures video at a less-than-stellar 15fps, holds footage on a microSD card, and can be recharged via USB. Reportedly, users can capture up to 33-hours of low-res video on a 1GB card, and two hours of that can be captured on a single charge. 'Course, whether or not this all is worth the stiff $295 asking price is certainly debatable. Source From: Engadget |
Posted by Prakash at 10:30 AM 0 comments
?? operator (C#)
The ?? operator returns the left-hand operand if it is not null, or else it returns the right operand. For example: int? x = null; ... // y = x, unless x is null, in which case y = -1. int y = x ?? -1; The ?? operator also works with reference types: //message = param, unless param is null //in which case message = "No message" string message = param ?? "No message" ; |
Posted by Prakash at 10:17 AM 1 comments
Very Good Morning.
அறங்கூறான் அல்ல செயினும் ஒருவன் |
Posted by Rajesh Prabhu. R at 7:04 AM 0 comments
Sunday, September 23, 2007
Some List of Sites
Free Sub domains http://www.freeurl.com
http://www.dot.tk/ (redirection)
http://megagiga.com
http://java.isavvix.com/freeback.jsp
http://quickemail.de
http://bigmailbox.com
http://www.countercentral.com/
http://www.fileserv.sytes.net
http://opticalorgasm.com/huge_tutorial_list.html
http://members.shaw.ca/
http://www.comet- cartoons.com/toons/3dhelp.cfm/
http://www.deviantart.com/?tier=stockart
http://www.catnmoose.com/wsc.shtml -- -------------------------------------------------------------- If you want a thing done well, do it yourself. -------------------------------------------------------------- |
Posted by Prakash at 12:24 PM 0 comments
Friday, September 21, 2007
Very Good Morning.
இறலீனும் எண்ணாது வெஃகின் விறல்ஈனும் |
Posted by Rajesh Prabhu. R at 7:14 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Thursday, September 20, 2007
How to Host winforms c# control in dialog based MFC application
To create the .NET user control |
Posted by A.VinothKumars at 12:36 PM 0 comments
Very Good Morning.
அறனறிந்து வெஃகா அறிவுடையார்ச் சேரும் |
Posted by Rajesh Prabhu. R at 6:51 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Wednesday, September 19, 2007
Very Good Morning.
அஃகாமை செல்வத்திற்கு யாதெனின் வெ ஃகாமை |
Posted by Rajesh Prabhu. R at 7:18 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Tuesday, September 18, 2007
Re: Robots That Sense Before They Touch
Latest Robot in Japan. -- Asimo http://www.youtube.com/watch?v=kFgXEkzMq7A On 9/18/07, Prakash < p.gnanaprakash@gmail.com> wrote:
|
Posted by Rajesh Prabhu. R at 12:58 PM 0 comments
Labels: Latest Trends
Robots That Sense Before They Touch
Intel researchers have developed a sensor for robotic arms that allows the robot to sense an object before actually touching it. For example, a robotic arm is capable of telling the difference between an empty bottle and a bottle filled with water without touching either one. The technology, known as pre-touch, is intended to "improve the ability of robots to grasp objects in unstructured human environments," says Intel research scientist Josh Smith. Pre-touch's electric-field (EF) proximity sensors are electrodes made of copper and aluminum foil. A current is sent to one of the electrodes, which creates a magnetic field and induces a current in the other electrodes. When the robotic hand gets near metal or anything with water in it, the object reduces the induced current, which is detected by the sensors. Special algorithms process the information and instruct the robotic hand to move around the object accordingly. Smith developed similar EF sensors while he was a student at MIT. Those sensors were used to help determine the position of people in a car, information that was used to determine how to deploy airbags during an accident. Smith says his current EF research will now involve developing algorithms capable of handling the complex data that EF sensors produce, particularly when the object or the robot is in motion. From ACM Technews |
Posted by Prakash at 10:49 AM 0 comments
Labels: Latest Trends
Very Good Morning.
வேண்டற்க வெஃகியாம் ஆக்கம் விளைவயின் |
Posted by Rajesh Prabhu. R at 7:53 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Friday, September 14, 2007
Very Good Morning.
அருள்வெஃகி ஆற்றின்கண் நின்றான் பொருள்வெ·கிப் |
Posted by Rajesh Prabhu. R at 7:13 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Thursday, September 13, 2007
Very Good Morning.
அஃகி அகன்ற அறிவென்னாம் யார்மாட்டும் |
Posted by Rajesh Prabhu. R at 6:36 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Wednesday, September 12, 2007
Indian team flies remote controlled aircraft with cellphone
A Mechanical Engineering research team based in Punjab has tweaked out a remote control plane to use what is ironically verboten during flight as its means of control. Using a programmable chip on the plane, the team was able to successfully take off and land the aircraft with a cellphone -- no brand mentioned -- and are now busying themselves with "perfecting the art of speed, height and direction of the plane." We wish them good luck with that, as those are the key elements to not having to cough up money for a new plane for every run. |
Posted by Prakash at 8:03 PM 0 comments
Labels: Latest Trends
Want to Get Ahead at the Office?
You go in early, stay late, finish all your assignments on time and come in below budget, but you still haven't got the recognition you deserve at work. What gives? According to Cynthia Shapiro, author of the book "Corporate Confidential," it doesn't matter how adept you are at your job because if you make these five common mistakes, you'll never be a star:
Source from: http://www.careerjournal.com/myc/killers/20070821-loeb.html?cjpos=home_whatsnew_major |
Posted by Prakash at 9:57 AM 0 comments
Very Good Morning.
இலமென்று வெஃகுதல் செய்யார் புலம்வென்ற |
Posted by Rajesh Prabhu. R at 6:30 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Tuesday, September 11, 2007
Interoperability Tips
Interoperability : [DllImport("MAPI32.DLL", CharSet = CharSet.Ansi)]
if we want to rename the MAPISendMail fn as SendMail within C# , How can we do it ? we can do the following.
[DllImport("MAPI32.DLL", EntryPoint = "MAPISendMail", CharSet = CharSet.Ansi)]
EntryPoint = "MAPISendMail" // specified function address is obtained from the DLL
SendMail( ...) Literally what will happen is the address of the MAPISendMail() fn is assigned to the SendMail() fn. So if we call the SendMail() fn from C#, it will in turn calls the MAPISendMail() functionality from MAPI32.dll |
Posted by Sundar at 5:51 PM 0 comments
Configure yahoo in Outlook
To Configure yahoo in Outlook, we have to download yPOPS application and install and run this application then configure the yahoo with outlook with the following : |
Posted by Sundar at 11:02 AM 0 comments
Labels: General
Very Good Morning.
சிற்றின்பம் வெஃகி அறனல்ல செய்யாரே |
Posted by Rajesh Prabhu. R at 6:14 AM 0 comments
Labels: Daily Digest, Jokes, Thirukkural
Monday, September 10, 2007
Using SingleTagSectionHandler Instead Of appSettings
While working with any kind of configuration files in .NET, be it Web.config in case of ASP.NET or App.config in case of Windows Forms applications, we very often use the appSettings section. We use it to store all kinds of simple configuration options. Options, that are too simple for us to implement a completely new SectionHandler type. There is however one problem with appSettings section not very expressive. What does it mean to be expressive? Consider the following example: <appSettings > <add key=" source1user" value="user" /> In simple cases, it may be acceptable, but what happens if more user keys are required for some reason? Maybe we need to access few different locations, each of which requires a username and password? We may use some kind of prefix for each key like in the above example, but that is not very elegant. What is key and value anyway? Another obvious problem here is when we need to have 2 parameters associated with a single logical functionality in the application, we need 2 entries in appSettings section. If we still don't want to implement a new SectionHandler type, we have very nice option left: SingleTagSectionHandler. MSDN describes it as: "Handles configuration sections that are represented by a single XML tag in the .config file". And that's about it. Unfortunately, (as usual) MSDN provides no example of how to use it. Fortunately it is quite simple: <configSections> <section name=" remoteDataSource" type="System.Configuration.SingleTagSectionHandler " /> </configSections> <remoteDataSource username=" user" password="pass" url="http://remote/" /> Using the newly declared section from the code is also easy: Hashtable remoteDataSource = (Hashtable)WebConfigurationManager.GetSection("remoteDataSource"); string username = (string)remoteDataSource["username"]; string password = (string)remoteDataSource["password"]; string url = (string)remoteDataSource["url"]; Simple, yet useful. |
Posted by Prakash at 9:51 AM 0 comments