Visual Basic

Moderators: None (Apply to moderate this forum)
Number of threads: 18011
Number of posts: 55384

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Sure could use a helping hand........ Posted by mchkin on 13 Apr 2005 at 10:47 PM
Hey, Thanks for reading this...
Am creating a web site and part of it is in VB6. have a data base that will often change in catagories... I want to download info to a form for each item. the items and info will be loaded onto a form then advance to a new form. How do I duplicate a form?.....
I E

name.file to form.name
location.file to form.location
picture.file to form.picture
New_Form

How is this done... I haven't programmed in 18 years... Anyone remember "structured Programming"?
Mchkin
Report
Re: Sure could use a helping hand........(forms mania) Posted by DjSpirit on 13 Apr 2005 at 11:05 PM
: Hey, Thanks for reading this...
: Am creating a web site and part of it is in VB6. have a data base that will often change in catagories... I want to download info to a form for each item. the items and info will be loaded onto a form then advance to a new form. How do I duplicate a form?.....
: I E
:
: name.file to form.name
: location.file to form.location
: picture.file to form.picture
: New_Form
:
: How is this done... I haven't programmed in 18 years... Anyone remember "structured Programming"?
: Mchkin
:
If I have understood you correctly you want to generate a form based on the data you find in a database.

Forms work sort of like classes so you can create a variable and pass a new form to that variable, the new form will be a copy of the original form, with code and all. So what you want to do is to set up a generic form with the things you need, and make copies of this.

Assuming you have already made a form (frmMyDBForm) you can do it like this:
Dim myNewDBForm As New frmMyDBForm
myNewDBForm.Show

If you want to be able to create multiple forms (like in a MDI application, you would probably create an array of forms. Like this:
Dim frmMyForms() As frmMyDBForm

Sub CreateForm()
    If IsNothing(frmMyForms) Then
        Redim frmMyForms(0)
    Else
        Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
    End If
    Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
    frmMyForms(UBound(frmMyForms)).Show
End Sub

You would probably add some code to set the properties of the new form, and also change it's content to fit the database.

DjSpirit, in all forms

Report
Re: Sure could use a helping hand........(forms mania) Posted by mchkin on 14 Apr 2005 at 1:02 AM
:
: Sub CreateForm()
: If IsNothing(frmMyForms) Then
: Redim frmMyForms(0)
: Else
: Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: End If
: Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: frmMyForms(UBound(frmMyForms)).Show
: End Sub[/code]
: You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
:
: DjSpirit, in all forms[/grey]
:
DjSpirit,
Thanks guy, er ah Gal (??)
What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
anyhow
Thanks Heaps


Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 10:44 AM
This message was edited by delljohnb at 2005-4-14 10:46:48

: :
: : Sub CreateForm()
: : If IsNothing(frmMyForms) Then
: : Redim frmMyForms(0)
: : Else
: : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : End If
: : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : frmMyForms(UBound(frmMyForms)).Show
: : End Sub[/code]
: : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: :
: : DjSpirit, in all forms[/grey]
: :
: DjSpirit,
: Thanks guy, er ah Gal (??)
: What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: anyhow
: Thanks Heaps
:
:
:
You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.



assuming you have the names in an array called FutureFormNames(1..10) :

for counter = 1 to 10
DotFound=0
for counter2 = 1 to len(FutureFormNames(counter))
if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
next counter2
FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
next counter


Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.





Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 10:53 AM
: This message was edited by delljohnb at 2005-4-14 10:46:48

: : :
: : : Sub CreateForm()
: : : If IsNothing(frmMyForms) Then
: : : Redim frmMyForms(0)
: : : Else
: : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : End If
: : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : frmMyForms(UBound(frmMyForms)).Show
: : : End Sub[/code]
: : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : :
: : : DjSpirit, in all forms[/grey]
: : :
: : DjSpirit,
: : Thanks guy, er ah Gal (??)
: : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : anyhow
: : Thanks Heaps
: :
: :
: :
: You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
:
:
:
: assuming you have the names in an array called FutureFormNames(1..10) :
:
: for counter = 1 to 10
: DotFound=0
: for counter2 = 1 to len(FutureFormNames(counter))
: if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: next counter2
: FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: next counter
:
:
: Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
:
:
:
:
:
:
Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.




Report
Re: Sure could use a helping hand........(forms mania) Posted by DjSpirit on 14 Apr 2005 at 11:01 AM
: : This message was edited by delljohnb at 2005-4-14 10:46:48

: : : :
: : : : Sub CreateForm()
: : : : If IsNothing(frmMyForms) Then
: : : : Redim frmMyForms(0)
: : : : Else
: : : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : : End If
: : : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : : frmMyForms(UBound(frmMyForms)).Show
: : : : End Sub[/code]
: : : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : : :
: : : : DjSpirit, in all forms[/grey]
: : : :
: : : DjSpirit,
: : : Thanks guy, er ah Gal (??)
: : : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : : anyhow
: : : Thanks Heaps
: : :
: : :
: : :
: : You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
: :
: :
: :
: : assuming you have the names in an array called FutureFormNames(1..10) :
: :
: : for counter = 1 to 10
: : DotFound=0
: : for counter2 = 1 to len(FutureFormNames(counter))
: : if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: : next counter2
: : FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: : next counter
: :
: :
: : Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
: :
: :
: :
: :
: :
: :
: Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.
:
:
:
:
:
This rambling of yours has very little to do with the original question, your solutions is not particularly well thought through, and the question has already been properly answered. Need you go on with this? It mostly serves to complicate and confuse matters.

DjSpirit, puhleeze

Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 2:43 PM
: : : This message was edited by delljohnb at 2005-4-14 10:46:48

: : : : :
: : : : : Sub CreateForm()
: : : : : If IsNothing(frmMyForms) Then
: : : : : Redim frmMyForms(0)
: : : : : Else
: : : : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : : : End If
: : : : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : : : frmMyForms(UBound(frmMyForms)).Show
: : : : : End Sub[/code]
: : : : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : : : :
: : : : : DjSpirit, in all forms[/grey]
: : : : :
: : : : DjSpirit,
: : : : Thanks guy, er ah Gal (??)
: : : : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : : : anyhow
: : : : Thanks Heaps
: : : :
: : : :
: : : :
: : : You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
: : :
: : :
: : :
: : : assuming you have the names in an array called FutureFormNames(1..10) :
: : :
: : : for counter = 1 to 10
: : : DotFound=0
: : : for counter2 = 1 to len(FutureFormNames(counter))
: : : if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: : : next counter2
: : : FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: : : next counter
: : :
: : :
: : : Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
: : :
: : :
: : :
: : :
: : :
: : :
: : Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.
: :
: :
: :
: :
: :
: This rambling of yours has very little to do with the original question, your solutions is not particularly well thought through, and the question has already been properly answered. Need you go on with this? It mostly serves to complicate and confuse matters.
:
: DjSpirit, puhleeze

:

ah.....ok...

sorry you feel like your toes got stepped on.

Wow...things have changed around here in the last couple months.

(rolling eyes)

Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 3:04 PM
: : : : This message was edited by delljohnb at 2005-4-14 10:46:48

: : : : : :
: : : : : : Sub CreateForm()
: : : : : : If IsNothing(frmMyForms) Then
: : : : : : Redim frmMyForms(0)
: : : : : : Else
: : : : : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : : : : End If
: : : : : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : : : : frmMyForms(UBound(frmMyForms)).Show
: : : : : : End Sub[/code]
: : : : : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : : : : :
: : : : : : DjSpirit, in all forms[/grey]
: : : : : :
: : : : : DjSpirit,
: : : : : Thanks guy, er ah Gal (??)
: : : : : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : : : : anyhow
: : : : : Thanks Heaps
: : : : :
: : : : :
: : : : :
: : : : You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
: : : :
: : : :
: : : :
: : : : assuming you have the names in an array called FutureFormNames(1..10) :
: : : :
: : : : for counter = 1 to 10
: : : : DotFound=0
: : : : for counter2 = 1 to len(FutureFormNames(counter))
: : : : if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: : : : next counter2
: : : : FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: : : : next counter
: : : :
: : : :
: : : : Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
: : : :
: : : :
: : : :
: : : :
: : : :
: : : :
: : : Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.
: : :
: : :
: : :
: : :
: : :
: : This rambling of yours has very little to do with the original question, your solutions is not particularly well thought through, and the question has already been properly answered. Need you go on with this? It mostly serves to complicate and confuse matters.
: :
: : DjSpirit, puhleeze

: :
:
: ah.....ok...
:
: sorry you feel like your toes got stepped on.
:
: Wow...things have changed around here in the last couple months.
:
: (rolling eyes)
:
:

LOL

http://www.programmersheaven.com/c/authorpage.asp?AuthorID=17409

BTW...I was on my second "PC" in 1982.

My post to this "old skool" programmer was written in generic locic code that he would understand from his "old Fortran days". I assume that you haven't had the thrill of writing Fortran code on punch cards using binary conversion of ASCI character numbers....try that, then look at my suggestions and see if they seem rambling...

In 1982 (your birth date) I was a Junior in High School. Oh...and I had a Fortran class in 1982.

I was trying to be helpful, and I don't appreciate your disrespectful comments.






Report
Re: Sure could use a helping hand........(forms mania) Posted by DjSpirit on 14 Apr 2005 at 3:33 PM
: : : : : This message was edited by delljohnb at 2005-4-14 10:46:48

: : : : : : :
: : : : : : : Sub CreateForm()
: : : : : : : If IsNothing(frmMyForms) Then
: : : : : : : Redim frmMyForms(0)
: : : : : : : Else
: : : : : : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : : : : : End If
: : : : : : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : : : : : frmMyForms(UBound(frmMyForms)).Show
: : : : : : : End Sub[/code]
: : : : : : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : : : : : :
: : : : : : : DjSpirit, in all forms[/grey]
: : : : : : :
: : : : : : DjSpirit,
: : : : : : Thanks guy, er ah Gal (??)
: : : : : : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : : : : : anyhow
: : : : : : Thanks Heaps
: : : : : :
: : : : : :
: : : : : :
: : : : : You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
: : : : :
: : : : :
: : : : :
: : : : : assuming you have the names in an array called FutureFormNames(1..10) :
: : : : :
: : : : : for counter = 1 to 10
: : : : : DotFound=0
: : : : : for counter2 = 1 to len(FutureFormNames(counter))
: : : : : if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: : : : : next counter2
: : : : : FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: : : : : next counter
: : : : :
: : : : :
: : : : : Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
: : : : :
: : : : :
: : : : :
: : : : :
: : : : :
: : : : :
: : : : Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.
: : : :
: : : :
: : : :
: : : :
: : : :
: : : This rambling of yours has very little to do with the original question, your solutions is not particularly well thought through, and the question has already been properly answered. Need you go on with this? It mostly serves to complicate and confuse matters.
: : :
: : : DjSpirit, puhleeze

: : :
: :
: : ah.....ok...
: :
: : sorry you feel like your toes got stepped on.
: :
: : Wow...things have changed around here in the last couple months.
: :
: : (rolling eyes)
: :
: :
:
: LOL
:
: http://www.programmersheaven.com/c/authorpage.asp?AuthorID=17409
:
: BTW...I was on my second "PC" in 1982.
:
: My post to this "old skool" programmer was written in generic locic code that he would understand from his "old Fortran days". I assume that you haven't had the thrill of writing Fortran code on punch cards using binary conversion of ASCI character numbers....try that, then look at my suggestions and see if they seem rambling...
:
: In 1982 (your birth date) I was a Junior in High School. Oh...and I had a Fortran class in 1982.
:
: I was trying to be helpful, and I don't appreciate your disrespectful comments.
:
:
:
Sorry that I went at you like that, it's just that the question was already answered and the code you suggested seemed, hmm, not the modern way of doing things, especially when the user had already mentioned that he was using a database, mixing arrays and such into the solution more than neccessary would only lead to more complexity, with no actual gain.
I have as you said not much of coding things into punch cards, but as fortran is programmable in most high level languages I suppose I have done some fortran indirectly. I am familiar with ASCII encoding and know the workings of the touring machine, I also enjoy a bit of assembly from time to time, and also a know a thing or two about electronics.
I do believe that experience counts, however seniority doesn't always mean more experience, and more experience doesn't always yeald better solutions. I do admire older people, but not because they are older, admiration comes by display of skill, knowledge and wisdom.

I will say I'm sorry about the outburst, but I will not admire you, as of now anyway.

DjSpirit, FAEBFE

Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 4:40 PM
: : : : : : This message was edited by delljohnb at 2005-4-14 10:46:48

: : : : : : : :
: : : : : : : : Sub CreateForm()
: : : : : : : : If IsNothing(frmMyForms) Then
: : : : : : : : Redim frmMyForms(0)
: : : : : : : : Else
: : : : : : : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : : : : : : End If
: : : : : : : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : : : : : : frmMyForms(UBound(frmMyForms)).Show
: : : : : : : : End Sub[/code]
: : : : : : : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : : : : : : :
: : : : : : : : DjSpirit, in all forms[/grey]
: : : : : : : :
: : : : : : : DjSpirit,
: : : : : : : Thanks guy, er ah Gal (??)
: : : : : : : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : : : : : : anyhow
: : : : : : : Thanks Heaps
: : : : : : :
: : : : : : :
: : : : : : :
: : : : : : You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
: : : : : :
: : : : : :
: : : : : :
: : : : : : assuming you have the names in an array called FutureFormNames(1..10) :
: : : : : :
: : : : : : for counter = 1 to 10
: : : : : : DotFound=0
: : : : : : for counter2 = 1 to len(FutureFormNames(counter))
: : : : : : if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: : : : : : next counter2
: : : : : : FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: : : : : : next counter
: : : : : :
: : : : : :
: : : : : : Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
: : : : : :
: : : : : :
: : : : : :
: : : : : :
: : : : : :
: : : : : :
: : : : : Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.
: : : : :
: : : : :
: : : : :
: : : : :
: : : : :
: : : : This rambling of yours has very little to do with the original question, your solutions is not particularly well thought through, and the question has already been properly answered. Need you go on with this? It mostly serves to complicate and confuse matters.
: : : :
: : : : DjSpirit, puhleeze

: : : :
: : :
: : : ah.....ok...
: : :
: : : sorry you feel like your toes got stepped on.
: : :
: : : Wow...things have changed around here in the last couple months.
: : :
: : : (rolling eyes)
: : :
: : :
: :
: : LOL
: :
: : http://www.programmersheaven.com/c/authorpage.asp?AuthorID=17409
: :
: : BTW...I was on my second "PC" in 1982.
: :
: : My post to this "old skool" programmer was written in generic locic code that he would understand from his "old Fortran days". I assume that you haven't had the thrill of writing Fortran code on punch cards using binary conversion of ASCI character numbers....try that, then look at my suggestions and see if they seem rambling...
: :
: : In 1982 (your birth date) I was a Junior in High School. Oh...and I had a Fortran class in 1982.
: :
: : I was trying to be helpful, and I don't appreciate your disrespectful comments.
: :
: :
: :
: Sorry that I went at you like that, it's just that the question was already answered and the code you suggested seemed, hmm, not the modern way of doing things, especially when the user had already mentioned that he was using a database, mixing arrays and such into the solution more than neccessary would only lead to more complexity, with no actual gain.
: I have as you said not much of coding things into punch cards, but as fortran is programmable in most high level languages I suppose I have done some fortran indirectly. I am familiar with ASCII encoding and know the workings of the touring machine, I also enjoy a bit of assembly from time to time, and also a know a thing or two about electronics.
: I do believe that experience counts, however seniority doesn't always mean more experience, and more experience doesn't always yeald better solutions. I do admire older people, but not because they are older, admiration comes by display of skill, knowledge and wisdom.
:
: I will say I'm sorry about the outburst, but I will not admire you, as of now anyway.
:
: DjSpirit, FAEBFE

:
Quite correct. Things have changed over the years, I made a suggestion to him in a way thay would be familiar. While the "traditional" way of programming may not seem intuitive to younger programmers (I use the term "younger" loosely here), it certainly has it's place. The traditional imbedded "for loop" with use of global dummy variables is something that the poster will be quite familiar with.

That familiarity eases transition into the "modern" programming theory of local variables and stacked objects. Local variables used to be considered sloppy programming.

I see my suggestions as assisting the poster in giving usable code logic in a language that he is not comfortable with.

BTW...while global variables are frowned upon now, they were generally required in the "old days". Total compiled code and data blocks could generally not exceed 64k. You HAD to re-use variables because any local declared variables in functions/procedures (especially global functions/procedures!!!) grabbed memory but would not release it. MTX was the onlylanguagethat I have used that never really had a problem with that. Oh...and the highest number you could use ANYWHERE was 32768....but I digress...

Don't get all stressed over programming approaches that you disagree with or don't understand the reasoning. There are many ways to skin a cat, and all the stress will do is make you go bald like me.



Resp.
John "delljohnb" Baugher
Sr. Programming Developer
CFC





Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 5:03 PM


There is nothing special and fancy about Fortran. To be quite honest I found it to be quite a pain. Generally the formal educational direction was...

1) Fortran
2) Cobol
3) Pascal


Fortran...great on math...bad on logical reasoning.

Cobol...great on logical reasoning and functions, but the math was complicated.

Pascal...generally a weak language...Jack-of-all-trades, BUT...it came into it's own when RGB monitors were developed. Pascal was known for graphics.

Basic was considered a "wimpy" and pooly designed language...the interpreter was to memory hogish and caused more problems than it was worth. MSBasic was a little better.


(Prior to the mid-1970's just about everything was assembly. I wrote my first assembly program in 1977. ACK! What a pain! It was a simple "battleship" program that took 2k of code.)

These were the mainframe side versions, not the pretty standardized versions that we have now. Each mainframe had its own version, and you couldn't program in Fortran for one computer and take it to another computer and have it work. Sometimes you could change a few leader cards and have it work, but not usually.

Here is how the "old skool" worked...

You would sit down and write your code on a legal pad.
You would then take each character of each line of code and give each character the ASCI value that it was assigned.
You would then go to a punch machine and convert the ACSI number of each character into its binary equiv and punch out the corresponding holes in the punch card.

You had to keep them in order, so most people wrote the "line number" in pencil across the top. The line number was not specifically encoded on the card. Some guys used crayon because it stood out really well.

Anyway...

You would then go to a card reader and put your stack into the reader and turn it on...

You would have a leader card that would have your account number on it.

The cards would whip through the reader (kind of like a dollar bill counter at a bank) sequentially and telex the "program" over to the mainframe facility.

In the morning (sometimes upt o 36 hours later), you would stop by the the mainframe facility and pick-up your print out. If you had several pages, then you were happy because you probably didn't get a compile failure...if you just had one page, then you went back to re-write the incorrect code cards, punched the cards, telexed them, waited overnight and picked up the revised print out.

It was not unusual for a programmer to take a week ormore to debug a simple 100-200 line program. You stillh ad to make minor tweaks to get the code to function correctly!!! Each tweak took several hours to punch and reload, and you still had to wait a day to get the results!

What a pain.

This is what the poster was used to.

Terminals were a GOD SEND!!! But that's another story.

LOL



Report
Re: Sure could use a helping hand....... wow did I start this??? Posted by mchkin on 14 Apr 2005 at 5:28 PM
: : : : : : : This message was edited by delljohnb at 2005-4-14 10:46:48

: : : : : : : : :
: : : : : : : : : Sub CreateForm()
: : : : : : : : : If IsNothing(frmMyForms) Then
: : : : : : : : : Redim frmMyForms(0)
: : : : : : : : : Else
: : : : : : : : : Redim Preserve frmMyForms(UBound(frmMyForms) + 1)
: : : : : : : : : End If
: : : : : : : : : Set frmMyForms(UBound(frmMyForms)) = New frmMyDBFrom
: : : : : : : : : frmMyForms(UBound(frmMyForms)).Show
: : : : : : : : : End Sub[/code]
: : : : : : : : : You would probably add some code to set the properties of the new form, and also change it's content to fit the database.
: : : : : : : : :
: : : : : : : : : DjSpirit, in all forms[/grey]
: : : : : : : : :
: : : : : : : : DjSpirit,
: : : : : : : : Thanks guy, er ah Gal (??)
: : : : : : : : What I'm tryin to do is nothing like we were taufgt in college... Purchased 3 books, (one was vb for dummies( don't laugh)) and am still pretty lost.....
: : : : : : : : anyhow
: : : : : : : : Thanks Heaps
: : : : : : : :
: : : : : : : :
: : : : : : : :
: : : : : : : You could always have an array of say 10 strings (or any number you want for that matter), then parse out the strings to remove everything after the "." then run a loop to force this shortened value into the form properties.
: : : : : : :
: : : : : : :
: : : : : : :
: : : : : : : assuming you have the names in an array called FutureFormNames(1..10) :
: : : : : : :
: : : : : : : for counter = 1 to 10
: : : : : : : DotFound=0
: : : : : : : for counter2 = 1 to len(FutureFormNames(counter))
: : : : : : : if mid(FutureFormNames(counter),counter2,1)="." then DotFound=counter2
: : : : : : : next counter2
: : : : : : : FutureFormNames(counter)=left(FutureFormNames(counter),DotFound-1))
: : : : : : : next counter
: : : : : : :
: : : : : : :
: : : : : : : Maybe somebody knows a quicker way, but this might be a nice little add in you can use. You only need to loop through FutureFormNames(x) and you can reset what you want.
: : : : : : :
: : : : : : :
: : : : : : :
: : : : : : :
: : : : : : :
: : : : : : :
: : : : : : Better yet...set up an array of records where you keep a consistant setup and store this in a text file...you can then read in the text file and parse out all the data contained in the file. You main script would stay the same, but you could change all the "changing values" by simply editing the text file, then uploading that to your site.
: : : : : :
: : : : : :
: : : : : :
: : : : : :
: : : : : :
: : : : : This rambling of yours has very little to do with the original question, your solutions is not particularly well thought through, and the question has already been properly answered. Need you go on with this? It mostly serves to complicate and confuse matters.
: : : : :
: : : : : DjSpirit, puhleeze

: : : : :
: : : :
: : : : ah.....ok...
: : : :
: : : : sorry you feel like your toes got stepped on.
: : : :
: : : : Wow...things have changed around here in the last couple months.
: : : :
: : : : (rolling eyes)
: : : :
: : : :
: : :
: : : LOL
: : :
: : : http://www.programmersheaven.com/c/authorpage.asp?AuthorID=17409
: : :
: : : BTW...I was on my second "PC" in 1982.
: : :
: : : My post to this "old skool" programmer was written in generic locic code that he would understand from his "old Fortran days". I assume that you haven't had the thrill of writing Fortran code on punch cards using binary conversion of ASCI character numbers....try that, then look at my suggestions and see if they seem rambling...
: : :
: : : In 1982 (your birth date) I was a Junior in High School. Oh...and I had a Fortran class in 1982.
: : :
: : : I was trying to be helpful, and I don't appreciate your disrespectful comments.
: : :
: : :
: : :
: : Sorry that I went at you like that, it's just that the question was already answered and the code you suggested seemed, hmm, not the modern way of doing things, especially when the user had already mentioned that he was using a database, mixing arrays and such into the solution more than neccessary would only lead to more complexity, with no actual gain.
: : I have as you said not much of coding things into punch cards, but as fortran is programmable in most high level languages I suppose I have done some fortran indirectly. I am familiar with ASCII encoding and know the workings of the touring machine, I also enjoy a bit of assembly from time to time, and also a know a thing or two about electronics.
: : I do believe that experience counts, however seniority doesn't always mean more experience, and more experience doesn't always yeald better solutions. I do admire older people, but not because they are older, admiration comes by display of skill, knowledge and wisdom.
: :
: : I will say I'm sorry about the outburst, but I will not admire you, as of now anyway.
: :
: : DjSpirit, FAEBFE

: :
: Quite correct. Things have changed over the years, I made a suggestion to him in a way thay would be familiar. While the "traditional" way of programming may not seem intuitive to younger programmers (I use the term "younger" loosely here), it certainly has it's place. The traditional imbedded "for loop" with use of global dummy variables is something that the poster will be quite familiar with.
:
: That familiarity eases transition into the "modern" programming theory of local variables and stacked objects. Local variables used to be considered sloppy programming.
:
: I see my suggestions as assisting the poster in giving usable code logic in a language that he is not comfortable with.
:
: BTW...while global variables are frowned upon now, they were generally required in the "old days". Total compiled code and data blocks could generally not exceed 64k. You HAD to re-use variables because any local declared variables in functions/procedures (especially global functions/procedures!!!) grabbed memory but would not release it. MTX was the onlylanguagethat I have used that never really had a problem with that. Oh...and the highest number you could use ANYWHERE was 32768....but I digress...
:
: Don't get all stressed over programming approaches that you disagree with or don't understand the reasoning. There are many ways to skin a cat, and all the stress will do is make you go bald like me.
:
:
:
: Resp.
: John "delljohnb" Baugher
: Sr. Programming Developer
: CFC
:
: Glad you two got things settled, thoutht I might have to recomend swords at 20 paces.... thanks again guys...
I will probably have a hundred other problems before I finosh this...
mchkin
:
:
:
:



Report
Re: Sure could use a helping hand........(forms mania) Posted by delljohnb on 14 Apr 2005 at 6:06 PM
DjSpirit had some good suggestions. Take the code that he dropped you, add your own twist that you understand, and you should find that it works like a charm. Certainly, the advice that you will get around is always aimed at being helpful. In the two or three years that I have posted here, I have only ever seen beneficial suggestions. Good luck on your project and let us know how it works out.

Resp,
John "delljohnb" Baugher




 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.