Tuesday, September 9, 2025

How to add text to MS word Document - in VB

     Sub mecro1()

Selection.TypeText "www.automateexcel.com"


 MsgBox "You need to select some text."

    End Sub

    


ref:-  https://www.automateexcel.com/vba/word/macro-examples

Friday, September 5, 2025

How to do eye protection in window 11 - How to do eye protection in window 10 - Eye protection in chrome

 > Search for night light (Turn it on)option in search under display settings

> Also you can search for color filter settings in search option

> Also search for "adjust clear text" setting in search option under window button click

>Also you can search for brightness and change the brightness level

> Also you can increase Zoom in Chrome browser (Min 110% is good).

> Also you can go to font and (chrome://settings/fonts) and min size to 15 and normal font size to 16.

> chrome://settings/system, enable or disable hardware acceleration

Also you can use apps like eye saver, CareUEyes


Also you can use Magnifier.

Also you can use scale from 100% to 110% from display settings.(Min 110% is good )

Also you can use resolution change. and color in Intel graphics command centre.

Also you can go to text size in scale in system settings and change it to 100% to 110%.(Min 110% is good )

Also you can use incognito window (Ctrl + Shift + N) for eye protection because in normal window and incognito window CSS of font is different


Also Change CSS color: #495057; to color: black; in Class.

====================================

Snippets in chrome - Snippet in chrome:-

If color is color: #495057; in css

Also you can create snippets in chrome developer tools 

> Go to Source and create new snippets

and paste below code

(function() {

  let style = `<style>

   .p-datatable .p-datatable-tbody>tr>td{

color: black;

}

  </style>`;

  document.head.insertAdjacentHTML("beforeend", style);

})();

=============================================

Also you can use visual vibration images, examples :- https://img.freepik.com/free-vector/realistic-optical-illusion-background_52683-54383.jpg?semt=ais_hybrid&w=740&q=80

https://kapooryash.blogspot.com/2026/02/vibration-of-font-in-chrome-shaking-of.html

https://i.pinimg.com/736x/82/b2/5f/82b25fed9db53b364d55bc80f9d76efc.jpg

ref:- https://allthings.how/how-to-change-brightness-on-windows-11/

how to increase color in android or how to change color in android - how to decrease color

 >You can use color changer app but it needs root permission

2) Display collaboration, blue light filter or sfilter , you can use these apps for android for decreasing color.

>Also simples is the rgb settings app for color changer.


Sunday, August 31, 2025

export to excel in grid - simplest way

   Response.Clear();

        Response.Buffer = true;

        Response.ClearContent();

        Response.ClearHeaders();

        Response.Charset = "";

        string FileName = "Vithal" + DateTime.Now + ".xls";

        StringWriter strwritter = new StringWriter();

        HtmlTextWriter htmltextwrtter = new HtmlTextWriter(strwritter);

        Response.Cache.SetCacheability(HttpCacheability.NoCache);

        Response.ContentType = "application/vnd.ms-excel";

        Response.AddHeader("Content-Disposition", "attachment;filename=" + FileName);

        GridView1.GridLines = GridLines.Both;

        GridView1.HeaderStyle.Font.Bold = true;

        GridView1.RenderControl(htmltextwrtter);

        Response.Write(strwritter.ToString());

        Response.End();

RDLC Report manual export to pdf, image etc - report viewer export to pdf manually

 https://www.c-sharpcorner.com/blogs/rdlc-report-export-on-server


https://www.aspsnippets.com/Articles/2568/Export-RDLC-Report-to-PDF-without-using-ReportViewer-in-ASPNet-with-C-and-VBNet/