Skip to main content

Posts

Showing posts from 2018

Word header does not print correctly

Ever printed a document and set the header as 1 inch. After printing the header is adjusted and it’s not the same with the specified settings on the header. There are numerous solutions to this single issue. Updating printer driver may help to solve this problem. Selecting the proper size of the document before printing that is same size with the paper that is on the printer. And a lot of possible solutions. Another solution to solve this issue is to check the headers and footers on page setup. On the document click on “File”, click “Print”. On the Print window, click “Page Setup” at the bottom on this window. See image below: On “Page Setup” window, click the “Layout” tab and adjust the “Headers and Footers” as per requirement. See image below: After adjust to a desired setting, click “Print” and if everything goes well. Then the printing will be as expected. Cheers..till next time.   ================================ ...

Add multiple drivers to a WinPE image

How to add multiple inf drivers to a Windows PE Image? To add a single driver to a Windows PE Image  is quite straight forward but adding multiple drivers  one by one is not ideal or else it will take a definite amount of time. Dism command provides an option to add a single driver or add multiple drivers. To add a single driver or multiple drivers, the first thing to do is to mount the image for editing. Dism /Mount-Image /ImageFile:"C:\WinPE_amd64\sources\boot.wim" /index:1 /MountDir:"C:\WinPE_amd64\mount" C:\WinPE_amd64\media\sources\boot.wim  -   is the image where the new drivers will be added C:\WinPE_amd64\mount - this directory will contain the extracted files of wim images, the folder must be created if it doesn't exist Once the image has been mounted, to add a single driver type the command below: Dism /Add-Driver /Image:"C:\WinPE_amd64\mount" /Driver:"C:\Folder_Driver\driver.inf" C:\WinPE_amd64\mount - the fold...

Move folders in command line with specific string

How to move folders in command line without selecting manually the folders? Manually moving folders is quite ideal if there are two or three folders that needs to be moved. But if the folders are quite a lot and doing it manually is a bit tedious; besides chances are there might be folders that will be missed out. Command lines and some basic editing in notepad can ease the process of moving folders it can be run via batch file or just simply enter the command at the command prompt window. Assume that all folders have the word “old-data” as part of its folder name. It can be any string as long as it’s common to all the folders that needs to be moved or archived. First step, is to open a command prompt window then change directory to the folders. Example: c:\cd sales_data Then at sales_data directory type: dir *old-data* /s/b > file_old_data.txt replace old-data with any string that is common to all folders. * is used between the string,...

Check if 32 bit or 64 bit processor from command line

How to check processor architecture whether its 32bit or 64bit? One method is to query the registry from the command line. Here’s a one liner command line that will check whether the PC processor is 32bit or 64bit. reg query "HKLM\SYSTEM\ CurrentControlSet\Control\ Session Manager\Environment" | find “ARCHITECTURE” If the output is something like this: PROCESSOR_ARCHITECTURE     REG_SZ     AMD64 Then it’s a 64bit, if it shows x86 then it’s a 32 bit. reg query "HKLM\SYSTEM\ CurrentControlSet\Control\ Session Manager\Environment" | find “IDENTIFIER” Above query can also identify, the output shows Intel64 for 64bit. Sample Output: PROCESSOR_IDENTIFIER     REG_SZ     Intel64 Family 6 Model 142 Stepping 10, GenuineIntel Omitting the find option from the “reg query” command will show quite a few information. reg query "HKLM\SYSTEM\ CurrentControlSet\Control\ Session Manager\Envi...

Linux copy files and change date or time

So, you want to copy files from one folder to another folder and change both the source and destination timestamp? Linux can easily change or modify the timestamp with ‘touch’ command. A one liner command with the help of ‘pipe’ to pass the arguments and ‘xargs’ to execute multiple commands in a single line can easily accomplish this task. Command below will copy the files in the current directory where ‘ls’ command is executed to the directory ‘xfiles’, timestamp will be changed to 7 hours less from the current time. ls | xargs -I % sh -c 'touch -d "7 hours ago" %; cp   -p %   ./xfiles'; -p   option is important to preserve the modified timestamp Note: the above command will change the timestamp for both source files and destination files. Command below will change the source timestamp, but the destination timestamp will be the date and time that the command was executed. ls | xargs -I % sh -c 'touch -d   "2 Aug" %; ...

WSUS – quick installation guide

WSUS or Windows Server Update Services is patching system for Windows OSes and other Microsoft products. In Windows 2016 or another version of Windows server it’s quite straight forward to install or config ure WSUS. Make sure the server has enough memory and has sufficient space to download and store updates. Plan accordingly the computer groups in WSUS, like 1 group for Testing updates and 1 group for production or other methods or strategy that is right for the environment. Configuring WSUS should be straight forward but in some instances, it may not work right after installing the WSUS server role. First, install and configure WSUS server role. Second, configure GPO to point to WSUS server. If the clients will not know where to find or report to a WSUS server then WSUS sever will be empty. WSUS server will not be able to detect client or server devices. In GPO you need to set the settings of how you are going to carry out the updates, like the time to ins...

How to open an elevated command prompt from a standard account?

Working in a fast pace environment, will need to get things done quickly to do other tasks that needs to be done also. Opening a command prompt in a standard user account without signing off and without logging off is possible with the “runas” utility command in Windows environment. Open the run box and type “ cmd ”, to open the command prompt window. Then type: Runas /user:admin_account cmd It will ask for a password, if authentication is valid then a new command prompt window will open in an elevated mode. Command works from Windows 7+  version. That’s it, you just open an elevated command prompt window in a user standard account. Since most users are hungry with the admin password, just watch out with the shoulder sniffing tactic. Other useful admin commands in a windows environment: If ever you have a custom local admin account name and you can’t remember, type: net users It will display all the local user accounts. To check domain ...

Ping IPv4 or IPv6 in Windows 10

Windows 7 and newer releases of Windows supports ping results of either IPv4 or IPv6. If the remote PC or server is configured for both IPv4 and IPv6, and if you need to ping via hostname and you want to get an IPv4 address type the command below: ping -4 -n 2 Dhoney_Srv Output will be IPv4 address of the hostname ping -6 -n 2 Dhoney_Srv Output will be IPv6 address of the hostname. -n 2 send two ICMP packet requests. Cheers! Till next time. ================================ Free Android Apps: Click  links below to find out more: Excel Keyboard guide: https://play.google.com/store/apps/details?id=chrisjoms.myexcelapplicationguide Linux Android App cheat sheet: https://play.google.com/store/apps/details?id=com.LinuxMobileKit Heaven's Dew Fall  Prayer app for Android : https://play.google.com/store/apps/details?id=soulrefresh.beautiful.prayer Catholic Rosary...

Activate Windows from command line

How to activate Windows from command line? If you have decided to convert an evaluation Windows server (Windows 2016 or other server version), or Windows 10 to a license Operating system then you need to replace the product key. You will need to change the product key and activate the system, in order to use the product outside of its evaluation period. Assuming you have done the steps of converting the evaluation software and all the evaluation packages has been removed. Of course, if you have plenty of time in your hands and you just want to redo everything then you can just install or setup a new environment. To activate a new product key from command line, first the product key must be installed and replaced the existing one. Second, activate the product key. Here’s how to do it via command line: a. slmgr /ipk windows-product-key-with-slashes /ipk = installed product key windows-product-key-with-slashes – replace this with the actual windows product...

How to search for string in Excel

There’s quite a lot of ways to do this in Excel, using Macro or Excel formula will be able to get the desired output. Macro I think is good if the number of rows is not so large, but if the number of rows is quite large then a buffer overflow error might occur. Formula can take quite large of data and able to deliver the result as expected. ISNUMBER is a function that can check whether value is a number or not, the function itself tells what the formula will be doing. Adding a search function to ISNUMBER then it can be used to search for a string with in a cell or the specified range in the formula. Example below shows how ISNUMBER can be used to search for a specified string whether it exists or not. The position of the string doesn’t matter as long as the string exist within the cell, the formula will return TRUE, otherwise it will return FALSE if the string does not exist. Here’s the example: =ISNUMBER(SEARCH("search string", A5)) The “...