2,599 questions with VB-related tags

Sort by: Updated
1 answer

Structure member name conflict rules

Hello When using Structures: Public Structure Blah Public Name As String Public Home As String End Structure I have 2 strings: Name and Home, does it matter for the variable names inside the Structure to be unique? ie if I have another string…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-20T15:04:43.32+00:00
StewartBW 465 Reputation points
answered 2024-05-20T15:24:43.67+00:00
Dewayne Basnett 1,356 Reputation points
1 answer One of the answers was accepted by the question author.

Rename mdb column

Hello I use Access Database Engine and OleDbReader to work with mdb and accdb files, need to rename a column: "ALTER TABLE xc RENAME Column old new LONG" Searched and found ADE might not support it, what if I add a new column and drop the old…

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,363 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-17T23:55:41.8966667+00:00
StewartBW 465 Reputation points
accepted 2024-05-20T14:59:02.35+00:00
StewartBW 465 Reputation points
1 answer

WebClient Timeout

Hello, I used many WebClient : OpenRead, UploadValues, DownloadString, DownloadStringAsync, DownloadFileAsync in my app. Need to set a timeout for each one and found this code, added the Dispose sub myself, needed to check if it's fine to use it? A class…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-19T14:43:38.9+00:00
StewartBW 465 Reputation points
commented 2024-05-20T09:28:29.15+00:00
StewartBW 465 Reputation points
2 answers

Create accdb or mdb from code

Hello I can create a new xls or xlsx Excel file with this: "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=D:\x.xls;Extended Properties=""Excel 8.0""" Using ExcelConnection As New OleDbConnection(AboveString) But how to…

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,363 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-16T12:30:38.7166667+00:00
StewartBW 465 Reputation points
commented 2024-05-20T07:18:28.5166667+00:00
Jiachen Li-MSFT 26,921 Reputation points Microsoft Vendor
0 answers

How to automatically jump to another cell after hitting enter

Hello All, is there a way to automatically move from the current cell to a specified cell after pressing enter or tab? For example: After entering data in cell H2 and pressing enter, cell H3 is selected. If I press tab, then cell I2 is selected. …

Excel
Excel
A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
1,520 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
Office Development
Office Development
Office: A suite of Microsoft productivity software that supports common business tasks, including word processing, email, presentations, and data management and analysis.Development: The process of researching, productizing, and refining new or existing technologies.
3,565 questions
asked 2024-05-17T21:01:24.8+00:00
Constance Fischer 0 Reputation points
edited the question 2024-05-20T01:02:54.1966667+00:00
Emi Zhang-MSFT 22,236 Reputation points Microsoft Vendor
1 answer One of the answers was accepted by the question author.

DirectoryInfo GetDirectories Reverse

Hello, Using this code and need to reverse the list returned by GetDirectories: Dim di As New DirectoryInfo(path) Dim di2 As DirectoryInfo() = di.GetDirectories How to reverse di2 list? Thanks :)

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,363 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-19T15:25:17.47+00:00
StewartBW 465 Reputation points
accepted 2024-05-19T23:19:59.1733333+00:00
StewartBW 465 Reputation points
2 answers One of the answers was accepted by the question author.

Get enum string from integer

Hello I have this enum: Friend Enum Blah As Integer Zero = 0 One = 1 Two = 2 End Enum I will get an integer and need to return the related string. ie will need to convert 1 to One. Select Case InputInteger Case 0 …

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-16T01:15:44.92+00:00
StewartBW 465 Reputation points
commented 2024-05-19T23:19:15.5066667+00:00
StewartBW 465 Reputation points
1 answer One of the answers was accepted by the question author.

How to get the handle of the mouse cursor icon with API (GetCursorInfo)

hi I need a function to put in the timer and check the status of the mouse cursor every 500 milliseconds. Private Declare Function GetCursorInfo Lib "user32" (ByRef pCI As cursorInfo) As Integer Public Structure POINTAPI Dim x…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,440 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-18T15:37:53.0233333+00:00
Mansour_Dalir 1,651 Reputation points
edited a comment 2024-05-19T08:56:37.3733333+00:00
KOZ6.0 5,050 Reputation points
1 answer One of the answers was accepted by the question author.

How to create the Left/Right MouseDown And MouseUp click event of Global type(Anywhere from Windows with API)

hi .Require mouse events via API functions

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,440 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-19T02:28:21.12+00:00
Mansour_Dalir 1,651 Reputation points
commented 2024-05-19T06:08:50.09+00:00
KOZ6.0 5,050 Reputation points
2 answers One of the answers was accepted by the question author.

ComboBox before drop down event?

Hello I'm looking for an event in ComboBox in .net framework WinForms which fires before the drop down menu is going to drop, when DropDownStyle is set to DropDown, so when user clicks on the far button, I add some items to the list on the fly and then…

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,363 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-18T00:15:41.8566667+00:00
StewartBW 465 Reputation points
accepted 2024-05-18T13:33:18.67+00:00
StewartBW 465 Reputation points
1 answer One of the answers was accepted by the question author.

Can't locate and add the System.Management.Automation into my project

Dear All, I trying to search and add the System.Management.Automation and System.Management.Automation.RunSpace that available in VS 2019 and using NuGet as well. Unfortunately, no luck. How to add this reference to my VB.Net 2019 (.NET Framework 4.7.2)…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-15T21:39:24.4633333+00:00
Eekhay 101 Reputation points
commented 2024-05-18T04:10:25.99+00:00
Eekhay 101 Reputation points
2 answers

ToUpper and ToLower first char and first word

Hello, Going to convert the first letter of each word to upper and lower case, to upper is simple, but to lower? System.Globalization.CultureInfo.CurrentCulture.TextInfo.ToTitleCase(---) And to convert the first word of string to upper and lower case, no…

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,363 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-16T13:29:08.5166667+00:00
StewartBW 465 Reputation points
answered 2024-05-17T08:13:57.3033333+00:00
Karen Payne MVP 35,196 Reputation points
1 answer

Visual Studio 2022 - VB.Net Desktop application error message hindering functionality

My desktop application developed with Visual Studio 2022 - VB.Net codes, generated an error message that is hindering the functionality of the application. Please see the message below: Severity Code Description Project File Line Suppression…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-16T21:25:31.1233333+00:00
Simon 286 Reputation points
answered 2024-05-17T05:31:37.5133333+00:00
Jiachen Li-MSFT 26,921 Reputation points Microsoft Vendor
1 answer

Hold IP and Port

Hello Is there any property/class in vb.net that can be used to hold an IP address and Port number? In vb.net , .net framework 4.0, thanks.

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-16T14:51:19.78+00:00
StewartBW 465 Reputation points
answered 2024-05-16T15:27:04.19+00:00
Dewayne Basnett 1,356 Reputation points
1 answer One of the answers was accepted by the question author.

String to Enum?

Hello, How to assign a string to an enum in vb.net? DirectCast([Enum].Parse(GetType(Blah), "Second"), Integer) Option Strict On disallows implicit conversions from 'Integer' to blah. Public Enum Blah First Second Thirds End Enum

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-15T16:39:50.26+00:00
StewartBW 465 Reputation points
accepted 2024-05-15T22:15:16.32+00:00
StewartBW 465 Reputation points
2 answers

Why is Copy / Cut / Paste NOT working in RichTextBox? It works my previous projects.

Hi All, I am unable to "Copy" the text output in a RichTextBox in a project created in Visual Studio 2013. In my previous projects, I can "Copy" text from RichTextBox. I found out on Googling that for RichTextBox, it is necessary to…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-06T17:36:06.9066667+00:00
VKSB 196 Reputation points
commented 2024-05-15T07:08:29.02+00:00
Jiachen Li-MSFT 26,921 Reputation points Microsoft Vendor
1 answer

Add a row to a TableLayoutPanel at runtime with a textbox in each cell of the row

I've tried and tried to add a row to a TableLayoutPanel but I can't. Can anyone tell me a tutorial to do this? Thank you Fabrizio

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-03T09:34:51.5066667+00:00
Fabrizio Leoncini 0 Reputation points
commented 2024-05-15T07:07:35.9966667+00:00
Jiachen Li-MSFT 26,921 Reputation points Microsoft Vendor
4 answers One of the answers was accepted by the question author.

Simple Math Opertation

Hello I need to calculate how many parts an SMS text is, the text is US Ascii so here's the long code with minimum of 15 lines: .Length > 0 AndAlso .Length <= 160 Then Return 1 .Length > 160 AndAlso .Length <= 320 Then Return 2 .Length >…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-13T13:12:52.5666667+00:00
StewartBW 465 Reputation points
accepted 2024-05-14T22:42:39.8266667+00:00
StewartBW 465 Reputation points
2 answers One of the answers was accepted by the question author.

Why drawing 2 Rectangles on a PictureBox by calling twice a "Function for Drawing" shows only the 2nd Rectangle?

Hi All, Given below is my Function (a Sub) for drawing a "Rectangle" on a "PictureBox". I wanted to draw 2 Rectangles side by side. When I called the function for each Rectangle, only the 2nd Rectangle was drawn, the 1st Rectangle was…

VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-05-14T11:01:48.48+00:00
VKSB 196 Reputation points
commented 2024-05-14T13:32:19.5533333+00:00
VKSB 196 Reputation points
0 answers

How to disable "the attachment is open. don't forget to save the file if you made any changes" error in outlook auto save macro. Every time any new attachment received i got this error

I have a remote system which was working fine for last 3 years but suddenly i am started to received attached error when any new item received in Outlook. My outlook have macro which save all the attachement in specified folders but this error have…

Office
Office
A suite of Microsoft productivity software that supports common business tasks, including word processing, email, presentations, and data management and analysis.
1,345 questions
Outlook
Outlook
A family of Microsoft email and calendar products.
3,086 questions
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,599 questions
asked 2024-04-16T20:04:48.66+00:00
Bushra Raees 5 Reputation points
commented 2024-05-13T16:12:41.86+00:00
AP 0 Reputation points