Posts

Showing posts from August, 2015

Latex Frequently used commands Part -2

1. How to add Bullets and numbering in Latex? There are two ways: 1. Unordered Lists 2. Ordered Lists Unordered Lists: \begin{itemize} \item{Text -1} \item{Text-2} \end{itemize} Entires are indicated with a black - dot (Bullet)) Ordered Lists: \begin{enumerate} \item{Text-1} \item{Text-2} \end(enumerate} Entries are labelled with numbers. These numbers start with 1. 2. How to type special characters in Latex? The following below characters play a special role in Latex and hence called Special Characters. # $ % & _ ^ \ { } If you want to print any of these characters to be printed just as any other letter, include a \ in front of the character. For example if you want print a % , then you have to type \% But what about backslash(\).  In order to display this \ , you have to type \textbackslash 3. How to make each section to start in a new page? We have to include titlesec package in the header and type the following command before you begin ...

Dumpbin Utility

dumpbin is a program in Visual Studio Tools that helps you to display infor- mation in binary le. By using dumpbin we can check whether a dll is build for x86 or x64. In order to run it Go to Start ) Microsoft Visual Studio2008 ) Visual Studio Tools ) Visual Studio 2008 Command Prompt. Type dumpbin and it will list all the commands present. To see all the methods exported by a particular DLL, change the directory where the DLL is present and type the following command: dumpbin /exports TestStreamDrv.dll To check whether a dll is build for x86 or x64 and type the following com- mand: dumpbin /headers TestStreamDrv.dll It displays a lot of information. Look for Machine which is present in FILE HEADER VALUES . This determines whether the DLL is present for x86 or x64. References: http://thompsonng.blogspot.com/2011/03/dumpbin-checking-your-application.html

Latex Frequently used commands Part -1

1. How to bold a particular text? \textbf{The text you want to Bold} 2. How to insert line breaks? a. \\ %{two backslashes} b. \newline c. \hfill \break 3. How to insert hyperlinks? Put \usepackage{hyperref} in your header, and when you want to link to a page, use the following command: \href{URL}{Anchor Text} 4. If you get *.sty not found in Windows? Method 1:  1. Win + R 2. Type mpm to start miketex package manager 3. Find the package you want to install , and install the corresponding package. The second method is used when you  manually download the file and install it. Method 2: 1. Create a folder named C:\tex-packages. 2. Copy the following files to the folder C:\tex-packages, http://mirrors.ctan.org/systems/win32/miktex/tm/packages/README.TXT     http://mirrors.ctan.org/systems/win32/miktex/tm/packages/miktex-zzdb1-2.9.tar.lzma     http://mirrors.ctan.org/systems/win32/miktex/tm/...

Ipconfig is not recognized as an internal or external command

Whenver you encounter this issue first check whether ipconfig.exe is actually present in your computer. It is present in Windows/System32/ipconfig.exe. So If s present, Open Command Prompt cd Windows\System32 and type ipconfig One more thing you can do is Edit your PATH variable and set it to C:\Users\<name of user> then it can be accessed at any location

_tgetenv_s example

It is used to get a value of a particular environmental variable. Syntax: errno_t _tgetenv_s( size_t *pReturnValue, char* buffer, size_t numberOfElements, const char *varname ); Parameters: pReturnValue: The buffer size that is required to store the variable buffer: Buffer in which the value of the environmental variable will be stored numberOfElements: Size of Buffer varname: Name of the Environmental Variable. Example: #include "stdafx.h" #include <stdio.h> #include <stdlib.h> int _tmain(int argc, _TCHAR* argv[]) { size_t requiredSize; TCHAR *value; _tgetenv_s(&requiredSize, NULL, 0, _T("SystemRoot")); printf("Size of the buffer required is %d\n", requiredSize); value = (TCHAR *)malloc(requiredSize * sizeof(TCHAR)); _tgetenv_s(&requiredSize, value, requiredSize, _T("SystemRoot")); printf("Value of SystemRoot Environmental Variable:%ls\n", value); return 0...

GetModuleFileName example

GetModuleFileName function is used to give the fully qualified path of the module passed. Syntax: DWORD WINAPI GetModuleFileName( _In_opt_ HMODULE hModule, _Out_    LPTSTR  lpFilename, _In_     DWORD   nSize ); Parameters: hModule: Handle to the loaded module. If you pass NULL as the first argument , it gives us the path of the executable file of the current file lpFileName:  Pointer to the buffer where the fully qualified path will be stored. nSize: The size of the lpFileName Buffer passed in TCHARs. Return Value:Length of the strring that is  copied in the buffer in characters. Example: GetModule.cpp: #include "stdafx.h" #include <windows.h> int _tmain(int argc, _TCHAR* argv[]) { TCHAR path[100]; DWORD length; length = GetModuleFileName(NULL, path, 1000); printf("Length: %d \t Path :%ls\n", length, path); getchar(); return 0; } ...