Saturday, October 1, 2011

Unable to share files and folders?????

If you are having problems with the functions of network related to sharing, this might help you.

Server

Windows 7

Default Description

Supports file, print, and named-pipe sharing over the network for this computer. If this service is stopped, these functions will be unavailable. If this service is disabled, any services that explicitly depend on it will fail to start.

Additional Information

None at this time.

Default Startup Type

OS SP0
Windows 7 Starter Automatic (Started)
Windows 7 Home Basic Automatic (Started)
Windows 7 Home Premium Automatic (Started)
Windows 7 Professional Automatic (Started)
Windows 7 Ultimate Automatic (Started)
Windows 7 Enterprise Automatic (Started)

Service Names

Service Name (registry): LanmanServer

Display Name: Server

Default Path and Command Line Options

C:\Windows\system32\svchost.exe -k netsvcs

Log On As

Account: Local System account

Dependencies

What service Server needs to function properly:

What other service require Server to function properly:



If by any means the server service is disabled, you are going to be in a lot problem in sharing files using homegroup or even directly with LAN cable or addoc. Troubleshooting problems won't help you a bit. File and printer sharing can't be turned on. Share with options on the explorer and folder properties vanishes. You'll be unable to leave homegroup or fix any problem with homegroup. What you are left out with is problems and problems with your network.

Tuesday, July 26, 2011

Creating a button with SDL

Mouse Events

The mouse events—mouse motion and mouse button each have their own structures for dealing with the events.


Mouse Motion Events

A mouse motion event is stored in an SDL_MouseMotionEvent, which looks like this.

typedef struct{
Uint8 type;
Uint8 state;
Uint16 x, y;
Sint16 xrel, yrel;
} SDL_MouseMotionEvent;

As with all SDL event structures, the type member specifies what type of event has occurred. In the case of a mouse motion event, this constant will only ever be SDL_MOUSEMOTION.
The state member is a combination of bit flags that tells you which mouse buttons are currently pressed, if any. Table below shows these bit flags.

Monday, July 25, 2011

Working with text in SDL

Using SDL_ttf

Like SDL itself, SDL_ttf first needs to be initialized. The function for doing this is TTF_Init. Likewise, after the program ends, it needs to be uninitialized by calling TTF_Quit.

int TTF_Init(void);
void TTF_Quit(void);

TTF_Init will return 0 if all went well and -1 if an error occurred. TTF_Quit does not return any value.


Creation and Destruction

The creation and destruction functions deal with making and unmaking fonts. The structure that keeps font information is called TTF_Font.

TTF_Font * TTF_OpenFont(const char *file, int ptsize);

Tuesday, July 12, 2011

SDL: Color Keys (Transparency)

A few times you’ll have portions of the image not to  be visible when you blit.  This is done by setting a transparent color key. You can select a single color that will be ignored when blitting.


To set a color key,  use the SDL_SetColorKey function.

int SDL_SetColorKey(SDL_Surface *surface, Uint32 flag, Uint32 key);


This function returns an int. In typical SDL style, 0 means success and -1 means an error. The function has three parameters—a pointer to the surface for which you are setting the color key (surface), a set of
flags (flag), and a value to use as the transparent color (key). There are two different flags that you can use in the flag parameter. One is SDL_SRCCOLORKEY, and the other is SDL_RLEACCEL. The

Monday, July 11, 2011

Loading images other than bitmap on SDL

Though SDL natively supports only .bmp files, on using the SDL_image extension library, we are able to load BMP, PNM, XPM, LBM, PCX, GIF, JPEG, TGA and PNG files.


SDL_Surface * IMG_Load(const char *file);



This function takes a string that holds the name of a graphics file that you want to load. If successful, it will return a pointer to an SDL_Surface that contains that newly loaded image. If there is some sort of problem, the function will return NULL.
This function looks very much like SDL_LoadBMP. The only difference is that it can load images other than those with a .bmp extension.

Sunday, July 10, 2011

Color fills in SDL

Color fills are typically only used to clear the screen or a large rectangular portion of the screen. They are still important, nonetheless. If you want to go deep, you can set individual pixels. If you can set a single pixel, you can do anything graphics-wise, such as drawing lines, circles, ellipses, polygons, and whatever else you can imagine. SDL has no functions for drawing these primitives, so if you want them you have to implement them yourself. The ability to retrieve the value of individual pixels goes hand-in-hand with setting them.

Saturday, July 9, 2011

Moving the loaded image with SDL

Filled Rectangles (SDL_FillRect)

SDL_FillRect is used to render color-filled rectangles.

int SDL_FillRect(SDL_Surface *dst, SDL_Rect *dstrect, Uint32 color);

This function returns an int. If successful, the value returned will be 0. If it fails, the return value will be -1. There are three parameters. The first (dst) is a pointer to an SDL_Surface on which you are drawing the filled rectangle. The second (dstrect) is a pointer to an SDL_Rect that describes the rectangular area that you want to fill. The third (color) is a Uint32 that represents the color with which you want to fill the rectangle.



clip_rect

The clip_rect member is an SDL_Rect. The values stored here limit the area on the SDL_Surface on which you can blit. SDL supports only rectangular clipping areas and only one rectangle at a time.


Now you are ready to load and animate or move the loaded image on the SDL screen you have created.



#include <sdl/sdl.h>
SDL_Surface *screen=0;
SDL_Surface *bitmap=0;

void draw_surface(SDL_Surface *sur, int x, int y)
{
    SDL_Rect pos={x,y};
    SDL_BlitSurface(sur, 0, screen, &pos);

Friday, July 8, 2011

Loading an image on the SDL screen

The knowledge of the following are required to some extent for loading an image on the screen.

SDL_Surface

It is a structure which acts as the stock and trade of SDL’s video subsystem. It abstracts a rectangular block of pixels. There is only one SDL_Surface that represents the actual display area. All of the other surfaces are buffers for storing pixel (such as images to be displayed) data that will eventually be shown on the main display.

SDL_Rect

The SDL video subsystem, being 2D in nature, deals primarily with copying rectangular blocks of pixels from one

SDL_Surface to another. This has been the way of dealing with raster displays since their initiation. It is The Way Things are done.

Thursday, July 7, 2011

Creating a window in SDL

You should know about some functions before you begin any sort of real work with SDL.



Initialize one or more SDL subsystems (SDL_Init )


The SDL_Init function should be the very first function that is called. If this function is not called, no other SDL function will operate. When you call this function, you specify which of the SDL subsystems you intend to use in the application. The identifiers for each of the subsystems are shown below.

Wednesday, July 6, 2011

Setting up SDL in codeblocks

  • First of all you've to download SDL headers and binaries. The download is available at http://www.mediafire.com/?ce02ii51rvoxezm
  • After downloading, extract the zip file.
  • Copy the contents of include folder and open ...\CodeBlocks\MinGW\include folder where your codeblocks has been installed ( such as C:\Program Files (x86)\CodeBlocks\MinGW\include). Create a new folder named SDL and paste the copied contents inside it.
  • Copy the contents of bin folder and paste it inside C:\Windows\System32.
  • Repeat the above step for lib folder. Paste the contents inside ...\CodeBlocks\MinGW\lib.

Tuesday, July 5, 2011

Collision detection in flash

Collision detection is an essential part in games. It ensures that the game physics are relatively realistic, so that an object does not cut through other objects or hovers when it should fall. How well a game can detect collisions is an integral part of the believability and enjoyment of the game.

Here is a simple concept in flash to test the collision detection.

  • Create two objects in flash, here for demo say two rectangles with red and blue color.
  • Right click both objects and convert them to symbol giving them names red and blue.
  • If properties panel is off, go to window menu and turn it on.
  • Select the respect objects and under properties panel give the instance names to both, say red and blue (these are the names we will be using to identify the them in action scripts).

Monday, July 4, 2011

Create your own character in flash-able to move

  • Create a character ( may be a circle here just for demo)
  • Right click the circle, convert to symbol, select movie clip and then give a name to the character finally pressing ok

Sunday, July 3, 2011

Make a Program Run at Startup

It sometimes require for us to make some programs run at startup. To accomplish this task, follow the steps as mentioned :

  1. Run registry editor ( run (win+R) and then type regedit)
  2. Then Computer\HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run
  3. Edit\New\String Value
  4. Rename New Value #1 to the name of program to be run at startup
  5. Double click the name so renamed

Saturday, July 2, 2011

Customize windows 7 - GodMode

By creating a new folder in Windows 7 and renaming it with a certain text string at the end, users are able to have a single place to do everything from changing the look of the mouse pointer to making a new hard-drive partition.
GodMode is the name given to cheats in video games that provide you with all weapons and access to all areas. As it turns out, Windows 7 has a GodMode cheat. It is basically a control panel of sorts which provides you access to all the features in one explorer window.

To enter "GodMode," one need only create a new folder and then rename the folder to the following: 

Friday, July 1, 2011

Changing Text on XP Start Button

Resource hacker


Resource Hacker is a freeware utility to view, modify, rename, add, delete and extract resources in 32bit Windows executables and resource files (*.res). It incorporates an internal resource script compiler and decompiler and works on Win95, Win98, WinME, WinNT, Win2000 and WinXP operating systems.
Viewing Resources: Cursor, Icon, Bitmap, GIF, AVI, and JPG resource images can be viewed. WAV and MIDI audio resources can be played. Menus, Dialogs, MessageTables, StringTables, Accelerators, Delphi Forms, and VersionInfo resources can be viewed as decompiled resource scripts. Menus and Dialogs can also be viewed as they would appear in a running application.
Saving Resources: Resources can be saved as image files (*.ico, *.bmp etc), as script files (*.rc), as binary resource files (*.res), or as untyped binary files (*.bin).
Modifying Resources: Resources can be modified by replacing the resource with a resource located in another file (*.ico, *.bmp, *.res etc) or by using the internal resource script compiler (for menus, dialogs etc). Dialog controls can also be visually moved and/or resized by clicking and dragging the respective dialog controls prior to recompiling with the internal compiler.
Adding Resources: Resources can be added to an application by copying them from external resource files (*.res).
Deleting Resources: Most compilers add resources into applications which are never used by the application. Removing unused resources can reduce an application's size.





Downloading resource hacker


Download resource hacker from the link http://www.mediafire.com/?acn0l46z8os67y7




Modifying explorer.exe file

  1. Make a backup copy of the file explorer.exe located at C:\Windows\explorer. Place it in a folder somewhere on your hard drive where it will be safe.
  2. Start Resource Hacker 
  3. File - open - explorer.exe located at C:\Windows\explorer.exe
  4. String table - 37 - 1033
  5. Replace the word 'start' with the one you want such as 'browse' and then compile script
  6. Then, File-save as - inside C:\Windows\ with any name such as explore.exe
  7. Close resource hacker
Modifying the registry

  1. Run ( win+R)
  2. Type regedit

Thursday, June 30, 2011

Phone Repair : Formatting your Phone

Flashing a mobile phone refers to the process of re-programming a mobile phone's firmware. Whenever you encounter issues such as phone restarting, hanging, no signal, etc or your phone even becomes dead, there are problems with your phone's firmware. And all it requires is flashing.


Primarily you need to download phoenix, a software used also for flashing. The download link is 
http://www.mediafire.com/?toyyinzjmtv#2

Wednesday, June 29, 2011

Create your own folder locker

A batch file is a text that contains a series of commands stored in the order the user wants them carried out. It executes a series of commands with a minimum number of keystrokes. Batch files allow you to automate a process and, at the same time, create more powerful commands, which increases productivity.

Here is an example of batch file, where you will be creating a simple folder locker which works in windows ( perfectly in xp version of windows)

Open notepad and type in the following commands.


cls
@ECHO OFF
if EXIST "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" goto UNLOCK
if NOT EXIST Personal goto MDLOCKER
:CONFIRM
echo Are you sure u want to Lock the folder(Y/N)
set/p "cho=>"
if %cho%==Y goto LOCK
if %cho%==y goto LOCK
if %cho%==n goto END
if %cho%==N goto END
echo Invalid choice.
goto CONFIRM
:LOCK
ren Personal "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
attrib +h +s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
echo Folder locked
goto End
:UNLOCK

Tuesday, June 28, 2011

Windows 7 tricks

Hidden Themes for Windows 7

Windows 7 by default has only few themes available for customization. People who are not satisfied with these in build themes can get few more themes for Windows 7 which are actually hidden. These themes are available for certain regional countries such as Australia, Canada, Great Britain, United States and South Africa. These themes can be revealed and used by the following steps.
win7-themes
1. Open Windows Explorer and click Organize
2. Select Folder and Search Options and navigate to the View tab.
3. Select Show hidden files, folders and drivers and uncheck Hide protected operating system files (Recommended). Click Yes, if prompted for confirmation.
4. Click OK and now browse to the folder: Windows\Globalization\MCT
5. There are five folders here with the name with format MCT-XX (where XX is AU, CA, GB, US, or ZA) which represents globalization settings for each region. Go into the folder that you want to activate its theme.
Note that AU, CA and ZA regions have the same themes.
6. Open the Theme folder inside the selected region folder.

Sunday, June 26, 2011

Protect your computer from viruses


Many people yell their pc got victimized of the so called - vital information resource under seize as a result of using flash drives(fd).  Here comes the notion which for sure will solve their problem. The first step is to download CPE17 autorun killer (http://www.4shared.com/file/-MWnPnNz/CPE17_Autorun_Killer__AntiAuto.html) and start it. By its name it is lucid it kills the autorun if subsist in the flash drives. Then the elective step (but recommended) to scan the fd via secure anti-virus(such as avira). http://www.softpedia.com/get/Antivirus/AntiVir-Personal-Edition.shtml - the download link.

Then after,


  1. Open my computer
  2. Tools (at the menu bar)
  3. Folder options
  4. View
  5. Turn on show hidden files, folders, and drives
  6. Uncheck hide protected operating system files(Recommended)
  7. Uncheck hide extensions for known file types
  8. Apply