|
The tigg wrote: I really couln't care less about learning.
You pretty much summed up the main problem in the software industry these days.
|
|
|
|
|
I'll second that.
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
"I really couln't care less about learning"
sorry, my mistake.
-- modified at 23:44 Sunday 11th November, 2007
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
indeed....
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
It sounds to me like you are a frustrated kid that is too emotional to read the advice you are being given...
Perhaps this will help you to understand what Chris has been telling you...
Read this:
Microsoft Visual Basic .NET tutorials for Beginners-
www.homeandlearn.co.uk/NET/vbNet.html
Cheers,
Cam
vXp- Helping is fun. Until you have to help.
|
|
|
|
|
It frustrates me when there's a lengthy thread establishing that someone is deliberately clueless and needs to be encouraged to try and do their own homework, and then someone else comes along and tries to post a solution. At least the solution you've posted won't do what he wants, and will probably confuse him more.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
there is that, i agree and your right, i tend to post a solution before reading what everyone else has said, im gonna delete it anyway. I just threw it together as a concpet, knew he was struggling, didn't care if it was right or not, his fault if he expects us to do it for him.
|
|
|
|
|
Christian Graus wrote: It frustrates me when there's a lengthy thread establishing that someone is deliberately clueless and needs to be encouraged to try and do their own homework
And the worst part is, I might have tried to make a helpful suggestion, but after the "I have no interest in learning" part, I have no intention of doing so.
The solution you suggested is exactly what immediately popped into my head when I read his problem. I almost posted it, until curiosity got the better of me and I wondered why all the extra responses. I'm glad I read them.
"If you think of yourselves as helpless and ineffectual, it is certain that you will create a despotic government to be your master. The wise despot, therefore, maintains among his subjects a popular sense that they are helpless and ineffectual."
- Frank Herbert
|
|
|
|
|
|
Hi,
1. Why the cross-post? You expect better answers from VB.NET programmers?
2. nice picture, now I (think I) know what it is you want.
3. you know you can turn a Form into a regular Control, so you can add it to another
Form? All it takes is setting TopLevel false. Maybe that solves all your requirements?
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
1. i never posted on any other forum than the vb one. i just thought i'd make a dedicated topic for this concept as the other one was for painting stuff.
2. thankyou.
3. yes ironic i was actually contemplating this move as i got your email. about to give that a go. But still, i don't know if it will help, maybe it will. we'll see
|
|
|
|
|
The ANZAC wrote: i never posted on any other forum than the vb one
Sorry I got confused then, thought I had just seen this elsewhere, I guessed on the C# forum.
yes ironic i was actually contemplating this move as i got your email. about to give that a go. But still, i don't know if it will help, maybe it will. we'll see
AFAIK it is intended for such use, but again I never did it: when Controls don't do what
I want, I usually tackle the problem with fewer of them (the "lightweight" approach),
avoiding the fight, rather than more of them and/or UserControls.
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
i need help writing a block of code that can scan the entire networked pcs ip and put the result into a listbox.As i not sure of even where to start i don't even know how to write it.Will be adding a polling function to it
|
|
|
|
|
Have you started on the project?
"I've seen more information on a frickin' sticky note!" - Dave Kreskowiak
|
|
|
|
|
Here I am in a situation where three events should occur one after another provided that the
preceding event occured successfully.
For eg. When i click a button, the first event prints the first report and when the first
printing succeds ,it should print the second report.But sometimes, the first report printing
cannot be done because some printing error may occur.In that case,the program should stop there.
How can it be done?? I need a general idea only.
Could you guys help me out??
X
|
|
|
|
|
|
Another one of those cross posters.
"The early bird may get the worm, but the second mouse gets the cheese" - anonymous, found in Uncle John's Bathroom Reader
|
|
|
|
|
Doesn't sound like your talking about events. you only have 1 event. the click event. inside that event you need to call 3 functions. each function should be a boolean so that you know whether or not to continue.
Sub Button_click(sender as object, e as system.eventargs) handler button.click
If bPrintFirstReport Then
If bPrintSecondReport Then
If bPrintThirdReport Then
'
else
'report error
End If
Else
'report error
End If
Else
'report error
End If
end sub
|
|
|
|
|
VB6 Property set with two parameters won't port to VB.Net
I'm trying to port a VB6 class called VBXML to VB.Net in such a way to also minimise changes to client code using the class.
In VB6 the class has a property called FieldValue that is defined with 2 parameters:
Public Property Get FieldValue(strXPath As String) As Variant<br />
<br />
CurrentField = strXPath<br />
FieldValue = CurrentFieldValue<br />
<br />
End Property<br />
<br />
Public Property Let FieldValue(strXPath As String, pvarNewValue As Variant)<br />
<br />
CurrentField = strXPath<br />
CurrentFieldValue = pvarNewValue<br />
<br />
End Property
Now without going into the innards this Property Let allows client code to be written like this:
Dim obj As VBXML<br />
<br />
Set obj = New VBXML<br />
obj.FieldValue("ID") = 10<br />
obj.FieldValue("Name") = "Gordon Brown"<br />
obj.FieldValue("Address") = "10 Downing Street"
This client code in VB6 generates a call to the property let with the string argument strXPath being passed as "ID" or "Name" or "Address" in the 3 examples above and with the variant pvarNewValue being passed as 10 or "Gordon Brown" or "10 Downing Street".
This is very convenient and intuitive syntax a bit like we used record sets:
rs.Fields("ID") = 10<br />
rs.Fields("Name") = "Gordon Brown"<br />
rs.Fields("Address") = "10 Downing Street"
It seams that equivalent VB.Net Property Let declarations are only ever allowed to have 1 parameter otherwise you receive an error: 'Set' method cannot have more than one parameter
So the question is how do I rewrite the class property so that client code will be able to be of this form and with minimal changes? The client code is also being ported to VB.Net by the way.
|
|
|
|
|
Ex:
Test("bbbb") = "hello"
Public WriteOnly Property Test(ByVal o As Object) As String
Set(ByVal value As String)
MsgBox(o)
Msgbox(value)
End Set
End Property
|
|
|
|
|
I did wonder what the relationship was between the argument in the declaration of the property itself and the argument in the declaration of the Set of the property in VB.Net. Now I know! Thanks for the very quick answer.
|
|
|
|
|
A list of numbers is input in a list box, say (4.8,6.9,8.0,3.2). The sum of these numbers are displayed in a textbox using:
For Index As Integer = 0 To lstbox1.Items.Count - 1
Total += CDbl(lstbox1.Items(Index))
Next Index
When one of those numbers are removed from the listbox, the total is accumulated , that is the new total is added to the old one. How can I correct this so that the total given is always, the total of the numbers in the listbox.
|
|
|
|
|
try an occasional Total=0
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
I need help with updating an access database table(access database is included in my project). my data comes from an xml that will periodically be updated and displayed on a DataGrid field. I manage to display the data onto datagrid and now I want to copy the displayed data into an access database table. Does anyone knows how to do that?
Thanks for your help
Maria
|
|
|
|
|
1. Iterate through the rows in your DataGrid control.
2. For each row, execute an INSERT INTO...VALUES DML query that inserts a row of data into a table in your Access database. This query could be constructed dynamically as a string or it could be a parametetized query stored in the Access database.
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|