vb.net

Is there any way to access a datasource from one project, in another project?

I have access to a database table that has been added as a datasource in project (A). Is there any way to refer to this database table from project (B) WITHOUT adding it to project (B)'s datasource? i.e. ProjB.databasetable.GetDataSetSchema Any ideas would be really appreciated. Thanks guys! ...

Programmatically change the startup form on application launch?

Can I programmatically change the startup form on application launch in VB.Net? ...

Custom glyph on DataGridView Header

Hello, I have a DataGridView where I would like drawing custom glyph (let's suppose a triangle) on the column header when the user click on it. I have the property EnableHeadersVisualStyles set to False. Do you have any example or suggestions how to reach the desired result? Do I need to inherit from DataGridView, or DataGridViewColu...

reassign thread to a different method vb.net

Is it possible to reassign thread to a different method, once it has been instantiated. If not, are there alternatives? ...

vb.net vs2008 empty executable

Is it possible to compile a vb.net project into an empty exe file (only containing the header information like version number, company, product name etc) in VS2008? ...

Deserializing json array into .net class

I'm having problems deserializing some json data, getting InvalidCastExceptions and the like. Can anyone point me in the right direction? Here's the json i'm wanting to deserialize; [{"OrderId":0,"Name":"Summary","MaxLen":"200"},{"OrderId":1,"Name":"Details","MaxLen":"0"}] Here's my code; Public Class jsTextArea Public O...

Correctly Identify the sender of a chat message in ASP.NET

I am developing a chat application using VB.NET and ASP.NET and I need to identify the particular user name users post messages. At present, it just shows my name, even for messages I haven't posted. What am I doing wrong? ...

Use property type in expression

I have a function which creates a different type of expression depending on the value of the variable passed in. Protected Function BuildSortPredicate(ByVal tableType As Object, ByRef expr As Expression) Dim sortExpression As Expression If tableType Is "Job" Then sortExpression = Expression.Lambda(Of Func(Of Job, String)...

Create an object whose type is in a string parameter

I have a TreeView, which contains nodes. When a user clicks on a node, corresponding CrystalReport document should be created and displayed. For example, names of my nodes are: "PeriodReport1", "PeriodReport2", "PeriodReport3". My CrystalReport documents are named same: "PeriodReport1", "PeriodReport2", "PeriodReport3". How can I creat...

Anyone used ConQAT with a VB.NET code base

To quote from the ConQAT - Continuous Quality Assessment Toolkit website Long-lived software systems are subject to gradual quality decay if no counter measures are taken. Continuous quality control counters this decay through an orchestrated application of constructive and analytic quality assurance techniques. The Conti...

How to get a dataset value

New to VB.Net, How to insert or select the dataset value. cmd = New SqlCommand("Select * from table1", con) ada = New SqlDataAdapter(cmd) ds = New DataSet ada.Fill(ds) cmd = New SqlCommand("Select * from '" & ds.Tables(0) & "' ", con) mydatatable1.Load(dr3) It was showing the error in '" & ds.Tables(0) & "',...

how to disallow history in vb.net web browser

I have a vb.net program that allows you to access webpages in my localhost. Now, my problem is that, when I try to list records in mysql by using tables, it remembers history and the previous data that you listed will appear like a ghost even if the data you inputted does not correspond to the data that it is showing. How can I avoid th...

How to build a very-low resolution timer ?

I need to implement a windows service that performs database import, and that once a month. The program receives data via e-mail, and will import them at the end of each month. Is there a better way than set the program to sleep for max_integer seconds/miliseconds repeatedly ? ...

Invoking the Windows Security Dialog (in C# or VB.NET)

Hi all, first things first this problem has stumped me for about a week and i would love a working answer! I would like to know how to invoke the Windows Security Dialog (press ctrl+alt+del on a windows workstation NOTE: i dont want the task manager!) programatically. ON AN XP WORKSTATION, don't worry about Win7 or Vista Ideally with ...

Parse numbers from string using regex in VB.NET

I am trying to parse the digits to store in a variable from a string in VB.NET (would like to also include the decimal point). Here is an example string: Refund issued for $27.74 ...

How do I get the name of parent method/class/file name inside other method call?

Hi, I will try to explain what I need. Let's say that I have a class like this: Public Class Example1 Public Sub ToBeCalled() System.Console.WriteLine( "The Method or Class or file and its line which called me is: ", ?????) End Sub End Class Then I have a second class like this: Public Cl...

VB.NET Array Initialization confuses me

Coming from a C# background, I have no idea why the following declarationr returns an array with length = 2, can someone please enlighten me? Dim lTestArray(1) As String Console.WriteLine(lTestArray.Length) (writes 2) ...

Why does CreateWindowEx return 0

VB.NET 2008 Express Private Declare Function CreateWindowEx Lib "user32" Alias "CreateWindowExA" (ByVal dwExStyle As Integer, ByVal lpClassName As String, ByVal lpWindowName As String, ByVal dwStyle As Integer, ByVal x As Integer, ByVal y As Integer, ByVal nWidth As Integer, ByVal nHeight As Integer, ByVal hwndParent As Integer, ByVal h...

XML to String value

I use an XMLWriter to manually make an XML document. Is there a way to put that in string form so I can write it to my DB? I am coding in VB..Net ...

Creating System Level Environmental Variables Manually

How do one create System Level environmental variables manually. I just installed a GeoSupport Desktop Edition software and in the document it is mentioned that I need to create system-level environmental variables for PATH and GEOFILES manually Add the location of the GDE executables to the system-level environmental variable PATH. Nor...