Tuesday, January 1, 2019

Get Height and Width of a Cell in Excel

Private Sub Worksheet_Activate()
    Dim getHeight As Single
    Dim getWidth As Single
   
    For i = 1 To 10
        getHeight = Range("A" + Trim(Str(i))).Height
        getWidth = Range(Chr(65 + i) + "1").Width
     
        Me.UsedRange(i, 1) = "Row  cm : " + Str(Round((getHeight / 72) * 2.54, 2))
        Me.UsedRange(1, i + 1) = Chr(65 + i) + "1 :" + Str(Round((getWidth / 72) * 2.54, 2))
     
    Next
End Sub

Friday, November 30, 2018

10 Things That Require ZERO Talent



B+ with Yourself
  1. Being on Time
  2. Work Ethic
  3. Effort
  4. Body Language
  5. Energy
  6. Attitude
  7. Passion
  8. Being Coach-able
  9. Doing Extra
  10. Being Prepared

Monday, November 5, 2018

Best way to get FILE NAMES from any Folder in Excel


This is one of the easy way to get File Names from your Windows Folder via "Name Manager".


  • At first, create a new Excel worksheet.
  • Then, select Cell A1.
  • Next, go to “Formulas” tab and click “Name Manager” button.
  • In the popup dialog box, click “New” button.


  • Subsequently, in the next dialog box, input “Files” in “Name” field.
  • And change “=Sheet1!$A$1” to “=FILES(Sheet1!$A$1)” in “Refers to:” field.



  • Afterwards, click “OK” and close “Name Manager” dialog box.
  • Later, copy the Windows folder path in Cell A1 and add “\*” at the end of the path.
  • Next, select the Cell A3 and input the function “=INDEX(Files,ROW()-2)”.



At once, a file in this Windows folder will be listed, like the following image.

  • Finally, just copy this function down several rows to list the other files until you see the “#REF!” error. The error means that all files have been listed.




Tuesday, October 23, 2018

Export High Resolution Images Directly from Microsoft PowerPoint

We know that PowerPoint allow you to save side as JPEG, but default resolution of the image in 96. Here we have a trick where you can increase the resolution.
Follow below steps and will allow you to save JPEG with high resolution.



  1. Press "Window + R" and type "regedit"
  2. Go to "Computer\HKEY_CURRENT_USER\Software\Microsoft\Office\\PowerPoint\Options". (xx.xx is your Office version folder number)
  3. Find / Create new "ExportBitmapResolution" DWORD entry and set Decimal Value as per your required resolution. eg. 196
  4. Open your PowerPoint and save slide as JPEG.
You can now see all the slides were saved with high resolution. 

Monday, October 22, 2018

Connect-SPOService : Current site is not a tenant administration site.

Working around with: Connect-SPOService : Current site is not a tenant administration site.

For the “Current site is not a tenant administration site” error message, which may look like following:
Connect-SPOService : Current site is not a tenant administration site.
At line:1 char:1
+ Connect-SPOService -Url https://mysite.sharepoint.com -Credential $credentials
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Connect-SPOService], ServerException
+ FullyQualifiedErrorId : Microsoft.SharePoint.Client.ServerException,Microsoft.Online.SharePoint.PowerShell.Con
nectSPOService

You get this error because you’re not entering the URL for your “Sharepoint Online Administration Center” site… Which is typically your normal sharepoint online URL, but then with a -admin after it, such as:

https://mysite-admin.sharepoint.com (assuming that your sharepoint online site is https://mysite.sharepoint.com). Therefore, then whole Powershell script would be:

Connect-SPOService -Url https://mysite-admin.sharepoint.com -credential username@mysharepointsite.com

NOTE: The -admin site is setup automatically. You don’t have to do anything. Just type in your sitename and then add the -admin.sharepoint.com to the end and you’ll be prompted to log in.

Wednesday, October 10, 2018

Enable the "Insert Rows" with mouse Right Click in Microsoft Excel

To fix this Issue, just follow below steps:

  1. Close all you Microsoft Excel files
  2. Goto "%appdata%\Microsoft\Excel" in Windows explorer and rename Excel15.xlb to Excel15.old
  3. Start Excel and you will see the 'Insert Row' function is now active.
Now you are able to find "Insert Rows" Enable. 

What is .xlb file ?
XLB is a settings file format created by Microsoft Excel. XLB files contain custom settings for the toolbars (or command bars). These settings can be edited or customized by selecting “toolbar” from the view options. XLB files can contain information such as which toolbars are visible, their position, and their function. XLB files allow for the transfer of customization information between computers and users.

Thursday, September 27, 2018

Promoted Links -> Script to show tile in rows and column

Promoted Links in SharePoint always show in a single row, following script help to break it into columns and rows also added style that will modify height and width.

// Copy Paste follow script into "Script Editor" above your Promoted Link web-part.