--------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00021 Date: 03/30/97 From: GARY SONNENBERG Time: 02:00am \/To: JOHN MELOLING (Read 4 times) Subj: Import Txt -=> Quoting John Meloling to Gary Sonnenberg <=- Hi John, GS> I guess this means you want to use it as a number as opposed to a GS> string, GS> right? If so, I don't think VB is going to let you. If you really are GS> using GS> it as a number (integer), why do you need the leading zero? Would GS> working GS> with it as a string be an option? Did you want to say something here? If so, it didn't get posted. :-( Gary ... "42? 7 and a half million years and all you can come up with is 42?!" --- * Origin: *YOPS ]I[* 3.1 GIG * RA/FD/FE RADist * Milwaukee, WI (1:154/750) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00022 Date: 03/30/97 From: GARY SONNENBERG Time: 02:02am \/To: BRANDON PEN (Read 4 times) Subj: ARRAYS -=> Quoting Brandon Pen to Gary Sonnenberg <=- Hi Brandon, BP> Could you please tell me how to make an array? Sure. I'm not sure which kind you want, so I'll mention both. First, variable array. Either in the General Declarations section or a particular Sub, do this... Dim sMyVar(10) As String That's basically it. If you want something other than String variables, just change String to something suitable (e.g. Integer). Some prefer to be more specific in setting up the index in parentheses like this... Dim iMyVar(1 to 15) As Integer Then you can use these variables: iMyVar(1), iMyVar(2), and so on. You can also easily put them in loops... For i = 1 to 15 iMyVar(i) = 23 Next i This would set all fifteen variables to 23. Maybe not a very useful example but it should give you the idea of what you can do. Second, control arrays. Two ways to set them up. One: name a control like txtMyBox. Add another control and give it the same same -- txtMyBox. VB will pop up a box asking if you want to create a control array. Click Yes. Your first textbox will then be called txtMyBox(1) and the other will be txtMyBox(2). Adding more boxes with the same name (or using copy and paste) will automatically increase the index number -- without your being asked if you want to do so by VB. The other way is to set the Index of the control in the Properties box by yourself. It accomplishes exactly the same thing. I usually use the first method. You can then refer to these controls in your code in much the same way as variable arrays above. Textboxes and option buttons are often put in arrays such as these. HTH, Gary ... All I need is a Wave and a board to surf it on. --- * Origin: *YOPS ]I[* 3.1 GIG * RA/FD/FE RADist * Milwaukee, WI (1:154/750) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00023 Date: 03/30/97 From: GARY SONNENBERG Time: 02:22am \/To: THEJASWI (Read 4 times) Subj: -=> Quoting Thejaswi to All <=- Hi, Th> Try as I might, I have been unable to load VB4-32 bit under Win95. Th> The software loads OK, but then refuses to run, and I keep getting the Th> mesaage 'Illegal function performed, appl. will be shut down" with Th> a whole load of dump from memory. Th> Can someone please tell me what do I do ? Th> The same VB installs well at any other system. Are you using VB4 Pro? And if so, did you install the 16-bit version first? Gary ... Backup not found: (A)bort (R)etry (S)lap nearest innocent bystander. --- * Origin: *YOPS ]I[* 3.1 GIG * RA/FD/FE RADist * Milwaukee, WI (1:154/750) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00024 Date: 03/30/97 From: GARY SONNENBERG Time: 02:23am \/To: GARY SONNENBERG (Read 4 times) Subj: ARRAYS -=> Quoting Gary Sonnenberg to Brandon Pen <=- GS> Can't get rid of this trailing a--> Sure, now it's not there! ... ARRRRRGGGHHH!!!! ... Tension breaker, had to be done. --- * Origin: *YOPS ]I[* 3.1 GIG * RA/FD/FE RADist * Milwaukee, WI (1:154/750) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00025 Date: 03/29/97 From: EILEEN LOUISE Time: 06:38am \/To: DIK COATES (Read 4 times) Subj: Information Needed Hi DIK, DIK COATES to EILEEN LOUISE on Thursday March 27 1997 DC> Is frmName.activate a slow operation? The kiddie appears to run a no, it's just an event. from what you've been saying to others, it sounds like you may have a lot of bloat in this application, but it's really hard to tell withut more info. i suspect your architecture is top heavy for VB from the way you'v ebeen describing things. --- Flying Pond Software * Origin: Television is furniture. (1:326/431) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00026 Date: 03/29/97 From: EILEEN LOUISE Time: 06:46am \/To: JIM BROADBENT (Read 4 times) Subj: Info Needed Hi Jim, Jim Broadbent to Dik Coates on Friday March 28 1997 JB> I am not certain that you use Sub Main for displaying a splash JB> screen. I think this is used just to execute code for startup main is a good place to do this under many circumstances. displaying a splash modelessly will allow the rest of your code to run "in the background" JB> Haven't tried this yet. Using MDI looks alot like a windows 3.1 JB> main screen to me or Tiling/cascade windows of Excel or Word. I JB> prefer to be childless until I sort out the rest. hahaha. that's cute. one reason to use MDI is when you want the user to decide what/when/how things happen. some programs have a structure and logical order of screen presentation which make SDI a good choice. others do not, and MDI is a good choice. --- Flying Pond Software * Origin: Television is furniture. (1:326/431) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00027 Date: 03/29/97 From: EILEEN LOUISE Time: 06:54am \/To: PHILLIP NORMAND (Read 4 times) Subj: File encryption using visual basic3 Hi Phillip, Phillip Normand to Eileen Louise on Friday March 28 1997 PN> Thank for your reply, the ways that you've mention, can you show PN> how I could incorporate these in Visual Basic 3? there are a lot of ways to do this, and mostly it depends on your application. Ultimately, you need to do two things. Get the user's input of their password and validate that The validation of the password is something like this ... open the password file read the program password decrypt the password by running some kind of DoDecode function wherein you give the program the pasword you read from the file and the master key. then you compare the two passwords. an exact match is ok, anything else fails. --- Flying Pond Software * Origin: Television is furniture. (1:326/431) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00028 Date: 03/29/97 From: PHILLIP NORMAND Time: 04:21pm \/To: JIM BROADBENT (Read 4 times) Subj: encryption Hi! Jim! Thank for your reply. I wanted the program to make it difficulte to open the password file with other windows application. I'm that you know some encryption program could encrypt/decrypt a file as command line. Therefore there must a way in visual basic but without as command line, for example when user enters password, the program must encrypt the file after, but when readyto retrieve password the program must decrypt the file before. But when he password appear, the program must encrypt the file before. I've downloaded your previous reply but having trouble reading it, can you give a hand, I want it to appear as on bbs? Thank you. --- Maximus 3.01 * Origin: The Treehouse Club 613-825-2932/206.130.50.192 (1:163/416) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00029 Date: 03/29/97 From: MICHELE MAURO Time: 08:20am \/To: GARY SONNENBERG (Read 4 times) Subj: SQL statement and apostro GS> MM> & CHR$(34) & GS> GS> MM> is a lot less confusing than GS> GS> MM> & """ & GS> GS> And how! Brilliant idea, Michele! Thanks for posting it. I've seen someone come up with a better idea on the newsgroups, but I haven't used it yet myself (too much recoding): vbQuote = CHR$(34) Then you just need "& vbQuote &" which makes it even easier to read (and follow). It seems like MS should have made the quote a constant like vbCrLf and a few others. There are huge gaps in my understanding of VB4, but when it comes to standard Jet engine databases, bound controls and SQL statements, I've picked up quite a bit of knowledge just doing this one dern shareware program that I've been working on now for months! Most of the app is done, but I'm still dreading writing the HLP file for it. I've had to work around the bugs in DBCombo so much that I tried nearly every other solution until I just gave up and used the one mode of DBCombo that doesn't leak memory (Type 2 - no user input). And after futzing with several copies of my database, then wanting to merge them, I spent a week coming up with the correct SQL statement to merge the unique records from one table into the same table in another copy of the database. Using DBGrid I spent another week to get it to work like Explorer (clicking on a header changes the type of sorting) which is what started my SQL self-training course and where I first ran into the apostrophe problem. Then I upgrade to True DBGrid and found out I'd inadvertantly had coded around bugs (that I thought were bad programming on my part - not a bug in the OCX) and had to redo half my code now that the bugs were gone. Basically, I found the "long way around" everything in VB and am just starting to learn the shortcuts. Have fun, Michele Internet: chaos@ao.net FIDO: 1:363/340 * Stupid is as stupid does... RoseReader 2.52T P001948 Entered at [COMPLICATIONS] --- * Origin: Complications, Altamonte Spgs, FL 407-297-8298 (1:363/340) --------------- FIDO MESSAGE AREA==> TOPIC: 178 VISUAL BASIC Ref: E3Z00030 Date: 03/28/97 From: NIELS SCHOOT Time: 01:44pm \/To: JOHN MELOLING (Read 4 times) Subj: Import Txt Hoi Hoi John! Monday March 24 1997 19:12, John Meloling wrote to All: JM> I'm trying to import a number string with leading 0 Example 098765432. JM> I use the following VAL(Trim$(Mid$(a$, 1, 9))). This drops the leading JM> 0. How can I keep the leading 0? Any help appreciated. NumVar$ = Trim$(Str$(YourValue)) NewVar$ = String$(10 - Len(NumVar$), "0") + NumVar$ Groetjes, Niels Email: niels.schoot@wpaper.iwg.nl --- FMailX32 1.22 * Origin: Whitepaper BBS ++31-575-565697 - Mail for everyone (2:2802/281)