Welcome to the Visual Basic IDE forum!

Hi all, and welcome to theVisual Basic IDE forum.

I'm Paul Yuknewicz - I'm one of the Program Managers on the Visual Basic product team, and starting today, I'll be moderating these forums. For more info about me, check out
my blog. Note there is aVB Team blogas well.

In this forum we will cover questions and discussions regarding the all things in the Visual Basic IDE (integrated development environment). This covers Intellisense, debugging, ErrorCorrect, ClickOnce deployment, code snippets, colorization, smart tags, key bindings, Object Browser, Refactor! for Visual Basic 2005?, etc.

The team and I look forward to joining you in discussions about VB.

Best,
Paul

[1121 byte] By [PaulYuk_MS] at [2008-1-10]
# 1
I'm very happy to see you here. I'm new to VB.net. if I have any probs I'll inform you. Thanks
ChennaiBOY at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 2

Cool...

I'm new to Vb.net programming and I'm from Sri Lanka.

Hope to clear my doubts from you very soon....

Thanks

J>mayooresan

J.Mayooresan at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 3

Hi Paul,

I am using visual basic.net 2003.

How can i make the IDE work faster. It's driving me nuts.

Thanks.

iAMssGOH at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 4

Hi-

Performance problems can be caused by a number of factors. Would you mind taking a moment to outline some details about your project and where exactly you experience slowless? I suggest posting this in a new forums post. My team will keep an eye for this and respond.

Best,

Paul

PaulYuk_MS at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 5

My problem in short is like this.

When I want to add codes behind a control. I dbl-click it it takes a long while before the text editor comes on line. Meanwhile, I can see that VB is busy saving stuff (hard disk light blinking).

When I move back to design view after putting in my codes, again it takes a long while before the design view becomes editable.

If I use tab strips the problems sometimes gets worst. My tabs becomes re-arranged (i.e. not in the order I had intended it to be).

Did I do something wrong in my installation?

Help appreciated as I am losing "train of thought" because of this.

Thanks.

iAMssGOH at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 6

OK, Spotty I will give it a try. Thanks.

luisfigueredo at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 7

Hi again Spotty: Itried what you said. I read the entire chapter, which shows only several lines of code. And a lot of reading. That is not what I need. What I need is to see the entire VB 2005 program for the Northwind database, to learn how they do things.

However, I thank you for trying.

Luis

luisfigueredo at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 8

Hi Luis,

The topic "Walkthrough: Displaying Related Data on a Form in a Windows Application" shows how to create a Parent/Child relationship using the Customers and Orders tables from the Northwind database.

http://msdn2.microsoft.com/en-us/library/803kw7az.aspx

There are also several other data walkthroughs that may be of help:

http://msdn2.microsoft.com/en-us/library/fxsa23t6.aspx

Steve Hoag

Visual Basic

shoagMSFT at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 9

Steve thanks, it worked very well.

Two more questions:

Is Crystal Reports included in VB 2005 Express?

Luis

luisfigueredo at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 10

Hi Luis,

No, Crystal Reports isn't included - for that you would need the full edition. Does that answer both of your questions :-)

Steve Hoag

shoagMSFT at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 11

Thanks again. Yes you answered the question, I know there is a 30 day trial but it may not be enough.

Luis

luisfigueredo at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 12

Hi All,

I'm facing problem as below:

Dim d As Double
d = 127.4
d = d / 18.2
MsgBox (d = 7#)

It's should return as true like what's we get from calculator, but it's not!

Workaround that I have encountered and seen so far are as below

  1. Declare d as Single instead Double

Dim d As Single
d = 127.4
d = d / 18.2
MsgBox (d = 7#)

  1. Convert the results to string and convert it back to double

Dim d As Double
d = 127.4
d = CDbl(CStr(d / 18.2))
d = d / 18.2
MsgBox (d = 7#)

Both message box will now return True.

Does anybody has a better solution or provide the logical explanation behind this results?

cht at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 13

When will the VB Team simply make vs 2005 VB.NET actually work ( read usable on anything other than example projects), and preferably not crash each and every day, and behave as a compiler, i.e detect syntax and compile errors!!

It would also be nice if it could actually compile lage programs without locking up and needing a re-boot.

All I see is look what we will do next, what we are looking for is "we will actaully produce a commercial product"..

See numerious threads on google about why VB.NET is luck to be a "beta" product..

And before I get the flame, yes I know I shoudl have stuck with VB6...

RayDyce at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 14

Hi everybody,

You might like to get the FREE Add-Ins VSIP DVD, i've just got mine.

See http://msdn.microsoft.com/vstudio/extend/partnerdvd/ for details.

Regards,

S_DS

Spidermans_DarkSide at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 15

This is great, I am new to doing this, I am a college student and am taking Visual Basic I, and having a lot of issues trying to write the codes for the different projects. The main one now is how do you write a code for a discount if the customer is a wholesaler? Can anyone help me. I would appreciate any help that I can get in this.

cheys1granny at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 16

Hi,

Please click on NEW THREAD to ask further questions.

Regards,

S_DS

P.S. Sorry to use "cartoon character" names.

You could do something like this ( to get you started just add 1 button to your FORM, click on that button).>>

PASTE these highlighted sections in the appropriate sections.>>

'Set up 3 arrays with each 'wholesale'

'customer having a different discount.

Dim wholesalers(4) As String

Dim others(4) As String

Dim discounts(4) As Double

'CLICK on the FORM to get this FORM_LOAD event

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

'Set up wholesalers.

wholesalers(0) = "Fred"

discounts(0) = 10.5

wholesalers(1) = "Barney"

discounts(1) = 12.5

wholesalers(2) = "Wilma"

discounts(2) = 14.5

wholesalers(3) = "Betty"

discounts(3) = 16.5

wholesalers(4) = "BamBam"

discounts(4) = 18.5

others(0) = "Sylvester"

others(1) = "Felix"

others(2) = "Tweety"

others(3) = "Marvin"

others(4) = "Speedy"

End Sub

'Type a 'FLINTSTONES' (c) character name to

'show a discount.

'Otherwise they don't get a discount.

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

Dim response As String

response = InputBox("Type 'FRED' 'BARNEY' 'WILMA' 'BETTY'" _

& " 'BAMBAM' 'SYLVESTER' 'FELIX' 'TWEETY'" _

& " 'MARVIN' or 'SPEEDY'")

Dim index As Integer

For index = 0 To 4

If response.ToUpper = others(index).ToUpper Then

MessageBox.Show("Sorry no discount for " & response.ToUpper)

End If

If response.ToUpper = wholesalers(index).ToUpper Then

MessageBox.Show(response & " gets " & _

discounts(index).ToString & "%")

End If

Next

End Sub

Spidermans_DarkSide-VSIP at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 17

Thanks it does seem to look like it might help me some. The one thing I have to do is put a message box on the form that will ask if the customer is a wholesaler, then with a yes or no. So then if they are they would get the discount if not they wouldn't. Does that make sense.

Judy

cheys1granny at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 18

cheys1granny wrote:

Thanks it does seem to look like it might help me some. The one thing I have to do is put a message box on the form that will ask if the customer is a wholesaler, then with a yes or no. So then if they are they would get the discount if not they wouldn't. Does that make sense.

Judy

Hi,

Yes it makes perfect sense but someone could "lie" about being a wholesaler.

If this was part of a "professional" application then the program would look up the customer in a database and apply their discount as per that item.

The discount will vary too from item-to-item, depending on who the OEM ( original equipment manufacturer is ), take for example the following; i worked in electrical wholesale for 8 years and one manufacturer had about 8 different discounts depending on the product code associated with that item.

So we had to produce a table for each customer showing their discount for each product code.

In that business we sometimes sold items with a 'gross profit' percentage added or just said list price - 20% if we were getting say 35% discount ( sometimes more ), depending on the item.

The company director wanted us to try and do all sales with a minimum of a certain gross profit percentage and i can tell you that the market-place was so competitive that "it became frustrating" trying to achieve this.

I worked mostly on the telephone-sales / trade-counter side of the business.

Your question "as is" though can be answered like.>>

Code Snippet

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) _

Handles Button1.Click

Dim response As String

Dim getsDiscount As Boolean = False

response = MessageBox.Show("Are you a wholesaler (Y/N) ?", "Wholesaler (Y/N)?", MessageBoxButtons.YesNo)

If response = vbYes Then

getsDiscount = True

Else

getsDiscount = False

End If

'Show a message to confirm.

If getsDiscount = True Then

MessageBox.Show("Your discount will be applied to each item.")

End If

End Sub

Regards,

S_DS

Spidermans_DarkSide-VSIP at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 19

Ok, I understand that but where would I put that in the section below?

Private Sub uiExitButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles uiExitButton.Click

'ends the application

Me.Close()

End Sub

Private Sub DiscForm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

End Sub

Private Sub uiDiscountLabel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles uiDiscountLabel.Click

End Sub

Private Sub uiCalcButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles uiCalcButton.Click

End Sub

End Class

I am assuming that it will go under the CalcButton_Click. Please tell me that I am right.

Judy

cheys1granny at 2007-8-21 > top of Msdn Tech,Visual Basic,Visual Basic IDE...