Posts

On Windows10, 11, How to enable https:// in Wamp

Image
To enable HTTPS on your local WAMP server, you need to set up SSL/TLS certificates.  Windows 10, 11 WampServer https:// Have you recently purchased Godaddy wild card ssl certificate?! Have you recently purchased Google SSL Certificate? Have you been trying to enable https protocol in order to test alternatively on your local Windows11 system because the previous two options are too expensive?!                         'This post is for you' Here’s how to do it: ### Steps to Enable HTTPS on WAMP: 1. **Install OpenSSL** (if not already installed):    - WAMP comes with OpenSSL, but make sure it’s properly installed. You can check this by looking for the `openssl.exe` file inside your WAMP directory, usually found in `C:\wamp64\bin\apache\apache[version]\bin\`.    - If OpenSSL isn’t installed, download it from [OpenSSL's official site](https://www.openssl.org/) and install it. 2. **Generate SSL Certificates**:    - Open a command prompt and navigate to the OpenSSL directory insi

VB .NET WinForms Datagridview.CellValueChanged event fires multiple times (Solved)

Image
Solution for  DataGridview.CellValueChanged Event fires multiple times. Datagridview.CellValuechanged event fires multiple times   - When you use Visual Studio to develop a WinForms application that contains Datagridview CheckBox Column. One of the Events that you may use to Change the Values in the Cells is [ CellValueChanged ] event.  You will notice 'if you debug your code', that this Event fires multiple times while executing. - Here is a solution for this multiple firing issue : Code Private Sub DatagridView1_CellValueChanged(sender As Object, e As DataGridViewCellEventArgs)         If TypeOf DatagridView1.CurrentCell Is DataGridViewCheckBoxCell Then             Dim ChkCnt As Integer             Dim columnIndex As Integer = OptCol.Index             If e.ColumnIndex = columnIndex Then                 Dim isChecked As Boolean = CBool(DatagridView1.Rows(e.RowIndex).Cells(e.ColumnIndex).Value)                 RemoveHandler DatagridView1.CellValueChanged, AddressOf DatagridView

VB .NET WebView2 WinForms tips

Image
VB .NET WebView2 WinForms Tips Edge WebView2 Tips Edge WebView2 Intro This course blog discusses dealing with Microsoft Edge WebView2 Control. If you are a developer then I'm sure you have searched before for an alternative WebBrowser Control, especially if you are a Desktop Apps Developer. Edge WebView2 Control by Microsoft gives you the ability to Embed Web Technologies like (HTML, CSS, JavaScript, …, etc.) in your App. It uses rendering engine Microsoft Edge (Chromium), so you can Display the web contents in your Apps. Requirements In order to start Microsoft Edge WebView2 for Desktop Projects as alternative for WebBrowser Control, you need the following : Microsoft Windows (In my case, it is Win10 64bit) Microsoft Visual Studio (In my case, it is VS2017) WebView2 Runtime or any Microsoft Edge (Chromium) non-stable channel installed on supported OS (currently Windows 10, Windows 8.1, and Windows 7). (In my case, Win10 64bit and Microsoft Edge (Chromium)

visual basic programming course - How to Extract Text from PDF File in VB Net

Image
 Visual Basic Programming Course How to Extract Text from PDF File in VB Net Visual Basic Tips on How to Manipulate PDF Files Intro This course blog discusses dealing with PDF File Format (PDF). Since Adobe Acrobat PDF reader is the best tool until today, then I will use it. iTextSharp  is the most common well known tool for manipulating PDF Files in most of development environments. As stated here  , there is a new release called itext7  which adds new security features when you move to itext7, you could get either commercial copy or AGPL from their official website . Unless you purchase a commercial License, you are not permitted to change the PDF Info concerning 'PDF Producer'. You can find Documentations on iTextSharp 5.0 here   Requirements Microsoft Windows 32bit or 64bit Microsoft Visual Studio 2010 iTextSharp 5.5.13.2 << Download it from NuGet >> AGPL3 License 'Open Source' Awesomium 1.7.5 << Download it from NuGet >> Visual Basic

VB.NET How to check if a Form is already Open

Image
VB.NET How to check if a Form is already Open Check if Form is open in Visual Basic .NET Visual Basic 2010 Windows Form [WinForm] Project .NET 4 Microsoft Windows 10 32 or 64bit Form1 Text : MainFrm.vb Button1 Text : OK! Form2  Text : SecondFrm.vb Now, in order to check if Form2 is open or not, and if open then Show it, or if it is not open then Open it, the code would be. Public Class MainFrm Private Sub PictureBox4_Click(sender As System.Object, e As System.EventArgs) Handles PictureBox4.Click OpnFrm = New SecondFrm If Application.OpenForms.OfType(Of SecondFrm).Any Then OpnFrm.Select() Exit Sub End If OpnFrm.Show(Me) End Sub End Class ♥  Here are some online Visual Basic lessons and courses : Visual Basic .Net - Create TextBox control with Event at Project Run-Time Visual Basic .Net - How to check for the internet connection Visual Basic .Net - POP3 and Receiving E-mails Visual Basic .Net - Generate Random Combinations Visual Basic .Net - Play sounds on Button Clic

Visual Studio warning configuration element is not declared

Image
Visual Studio warning configuration element is not declared Visual Studio warning Error When you open your Visual Basic Project, and navigate to App.config file for editing, you notice that <configuration> is underlined with blue line. When the cursor hovers, you see this message ( The 'configuration' element is not declared ). configuration element is not declared Solution Open your VB.Net Project. From XML menu, choose Schemas.. App.Config - configuration element solution From XML Schemas, look for DotNetConfig.xsd From Dropdown Use, choose Use this schema Click OK. vb.net - app.Config - configuration solution Create your own App.config file, Set Value, Get Value You need to add reference to Configuration.dll in your project. Create Class MyConfigs.vb

VB.NET How to properly close a windows application Form

Image
VB.NET  How to properly close a windows application Form VB.NET How to properly close a windows application Form Requirements Visual Basic .Net (any version) , VB2010 and up recommend .NET FrameWork 4.0 and above recommended How to properly close a windows application Form in VB.NET ? You may close a Form in VB.NET Application [WinForm] by : KeyPress event Before you test this code you need to set the Form Property [KeyPreview] True, from Form Properties Window. The code below will Read Keyboard button [Escape] when clicked and Executes Close() Private Sub MainFrm_KeyPress(sender As Object, e As KeyPressEventArgs) Handles Me.KeyPress         If e.KeyChar = Chr(Keys.Escape) Then             Close()         End If     End Sub Then in the FormClosing() event, we will place a code to display a message [MsgBox] with [Yes, No, Cancel]. If the user clicked [Yes] then it will Close the Form and Ends the application. Private Sub MainFrm_FormClosing(sender A

VB .NET Google Drive Api Source Code Example

Image
CodeProject VB .NET Google Drive Api Source Code Example VB .NET Google Drive Api Source Code Example Requirements Visual Basic 2012 [recommended VS 2015] or above (Visual Studio 2019) from  here Visual Basic previous Example from  here Google Account from  here .NET Framework 4.5+ or above. "Async Programming" Google Drive Api [Google.Apis.Drive.v3] from NuGet  here Open VB 2015 Project in VB 2019  Can I open / migrate  Visual Basic 2015  Project Source Code with Visual Basic 2019 ? The answer is Yes, if you want to more details about VB 2015 to VB 2019 migration, please  read VB.NET Google Drive Api v3 post key points How to use Google Developer Console to create a project. How to Configuring Google Api Console How to Install Google Drive Api v3 from Visual Studio 2015 How to Upload Simple file to Google Drive using Google Drive Api v3 from VB.NET How to Upload Large Files (Resumable Upload) using Google Drive Api v3 from VB.NET Async programming. Project desc