Hi there. Im having a problem with a loop inside a C++ dll being called from VB. I want this loop to update a global variable, but when I call the function the variable does not update the first time round, but does so every subsequent time.
This is how I am trying to update the variable.
else
{
::nScore = nHighest;
if (nScor...
The desktop application I'm migrating makes heavy use of a treeview control, and many calls to TreeNode.FirstSibling, e.g.
'UPGRADE_ISSUE: MSComctlLib.Node property tvTreeView.SelectedItem.FirstSibling was not upgraded.
If tvTreeView.SelectedNode.FirstSibling.Index = 1 Then
...
End If
Is there an equivalent function to use?
...
Hi,
I am a vb.net newbie, so please bear with me. Is it possible to create properties (or attributes) for a class in visual basic (I am using Visual Basic 2005) ? All web searches for metaprogramming led me nowhere. Here is an example to clarify what I mean.
public class GenericProps
public sub new()
' ???
end sub
p...
I have a class called Player in the business layer of my web application.
Player class has fields PlayerID, CategoryID and CountryID
A function in Player Class calls a function in PlayerDB Class in the Data Access Layer which in turn calls a stored proc which returns data for PlayerID, CategoryID (foreign key to Category table) and Cou...
In an electric company where I was hired temporarily, we have to implement an upgrade of the billing and payments system ( the current system is a dbaseIII system). The company's programmer and I have decided to use VB.Net and MySQL.
The company served several towns and have billing and payments centers in selected towns. Every billing...
My Application is built to a scan MS Access database in VB.NET.
When the Access application is distributed to end users, they may have different versions of COM components. Is it possible to Add/Remove references programmatically to resolve broken references due to differing versions?
Please share me code or link for reference.
...
Hi All,
I need to learn VB.net in Visual Studio 2005 Express for my job. I'm not that good or experienced of a programmer.
I've done Basic and Pascal in school. I played with assembly language programming a Motorola HC08 processor a little. For the past 2 years I have done some involved things in Access using VBA. At work we have an o...
Does VB.NET have any scope nesting operators like {} in C type languages?
Example C++ type code:
int i;
i = 0;
{
int i;
i++;
}
...
We have data that's updated nightly in a database residing in the same instance as my app's database. So to save on database calls, I want to cache this static-for-the-day data into a List(Of MyObject). From a theory point of view, should this cached List(Of ) be cached in the presentation layer code, via a global variable? Should it be ...
As the title states, I have a session variable that is set during a login script with asp.net and vb.net code-behind. Can I call a javascript function when a link is clicked that will destroy that session variable?
If it is possible, can I use jQuery to make that process easier?
...
I am hoping that someone can help me with a problem I've got at the moment using Compact Framework.Net 2 SP 2.
At the moment I have a UI with a series of text boxes and each textbox displays the contents of a database field. These are shown one beneath another with a scroll bar on the right hand side of the form. Each textbox has a set ...
I have a custom class set up as a key that has two properties, X and Y
I have something similar to this:
Dim test As New List(of TestClass)
Dim key as New TestData
key._a = A
key._b = B
For Each a As TestClass In SomeCollection
If Not test.Contains(key) Then
'Do Stuff
End If
Next
My question is this: How does the .Contain...
I am familiar with the VB6 ADO way of dealing with SQL queries and looping through the record set results.
However, what is the correct way to query a server, cycle through the results, and dispose of my query in VB.Net? All the ways I have been using seem to be unstable and crash randomly.
I have been using the following code:
Public...
I have gridview that I am using paging on. I want to pass along the current page in a asp:Hyperlink so I can send them back to the current page when they are done viewing the details of a record. Is this possible? If it is how can I do this?
<asp:GridView ID="grdObitList" runat="server" allowpaging="true"
PageSize="10" Aut...
I am trying to copy the contents of one graphics object to another, but the only was i have been able to find is based on using GDI32.DLL, which i would rather avoid using if possible.
Does anyone know how/if this is possible using managed code? I dont mind if answers are in C# or VB.Net.
Here is waht i currently have:
Private Sub Co...
We heard a lot about the vulnerabilities of using QueryStrings and the possible attacks.
Aside from that, yesterday, an error irritated me so much that i just decide to stop using QueryStrings, i was passing something like:
Dim url As String = "pageName.aspx?type=3&st=34&am=87&m=9"
I tried to
Response.Write(url)
in the redirecting...
In VB.NET, I am trying to talk to a webservice (that can't be changed) to create and update customer data.
The CreateCustomer service expects an object of type ConsumerPerson and the ChangeCustomer service expects an object of type ChangeData.
The properties of these two object are exactly the same, so I thought it would be wise to just...
I am using Linq to convert an array of any object to a CSV list:
String.Join(",", (From item In objectArray Select item.ToString()).ToArray())
This is giving me the strange error: "Range variable name cannot match the name of a member of the 'Object' class."
I can get round it by wrapping the string in a VB StrConv method, with a set...
Are variables declared in a case statement local to that case statement -
For example, in the following code, is it safe to use z like this? Or is the compiler just placing z at the procedure scope?
Select Case x
Case 6
Dim z As Integer = 6
Case 7
Dim z As Integer = 7
...
In VS2008 (VB.NET) when you type Public Property X As SomeType
and press enter, VS auto-generates the rest of that property definition for you.
I would like to be able to customize what VS generates.
Any thoughts on how to go about that? VS must have a template for it somewhere, eh?
Thanks.
...