Questions tagged [vb.net-module]

9 questions
2
votes
1 answer

Suppressing FXCOP error for vb.net Method

I want to suppress FXCOP error(CA1811) for specific vb.net function. Like in c#, do we alternative of this in VB.net? I am new to vb.net.
1
vote
0 answers

picturebox.Scale, picturebox.Line in vb.net

I have the following Sub function I need to convert from Vb6 to Vb.net. The .Scale() & .Line() methods aren't supported anymore and I am brand new to the VB language so I am having a hard time doing so. Public Sub DrawMap(picMap As PictureBox, ByVal…
trankilo
  • 11
  • 2
0
votes
1 answer

Is there any code to change value of dim function

I want to put data in SQL table through vb.net in two columns which are Txn_Amount and Post_Amount where textbox3 = Txn_Amount Post Amount = Textbox4 - textbox3 but I want if textbox4 = "" than Post amount should be 0 This is my code: Call…
0
votes
1 answer

system login using query select 1

I am trying to code the login page, here is my code: 'login form code Private Sub btnLogin_Click(sender As Object, e As EventArgs) Handles btnLogin.Click Dim username As String = txtUsername.Text.Trim Dim pwd As String =…
user4221591
  • 2,084
  • 7
  • 34
  • 68
0
votes
1 answer

filter name and username from datagridview using textbox

i am using combobox for option search name and username and textbox for filter there are error missing operator Try If Trim(TextBox1.Text) <> "" Then dataadapter1 = New OleDbDataAdapter("select * form login…
0
votes
2 answers

How do you differentiate an operator vs know it is not operator but belong to a string?

Example this is the string: "Hello, this is challenging\n" + "you think it is easy?\n" + variableName + " 3 + 4 = 7\n" Dim example = """Hello, this is challenging\n"" + ""you think it is easy?\n"" + variableName + "" 3 + 4 = 7\n""" I want to use…
Gin May
  • 43
  • 1
  • 8
0
votes
0 answers

Assert statement not functioning well

The assert statement in the code below does not function properly. How can I control the assert with another variable decision? I am new in coding. Public Class FactorsOf32DictionaryCatchError Sub…
0
votes
2 answers

Share constants from a module with other projects

I have a VB.NET class library project which assembly name is MyCompany.Constants and it only contains a module MyModule.vb : Public Module Constants Public Const Item1 As String = "Foo" Public Const Item2 As String = "Foo2" End Module The…
Willy
  • 9,848
  • 22
  • 141
  • 284
0
votes
1 answer

Execution sequence for a module constructor in a web application for VB.NET

I am trying to understand an execution sequence in a web application environment - basically I am using a module for various utility functions, including logging and initializing various global/shared variables. The website has several stand-alone…