Jay Fuller Personal Journal "Portable Patients" Senior Project August 2-12, 1999 I worked with the initial senior project team to calculate what would be a reasonable senior project. Initially, the team came up with an idea to revamp the existing CIS website, adding scripts which would allow students to have a form of advising online, as well as provide the basic functionality of bringing the website up to date. Several other ideas were also incorporated. The team members chosen were Yvonne Totty, Steven Grimes, Adam Hewalski, and Jay Fuller – upon team approval. August 13, 1999 (approx) I discovered I was not eligible to register for the senior project course. I appealed this decision immediately, and was granted permission to join the project. September 1, 1999 (approx) The team discovered that we were not granted our original proposal. We are working with Dr. Mark Brown to create a solution for a problem he had. Initially, we thought we would be doing some type of retinal analysis. The team had a very hard time coping with this, as we felt the project did not meet our capabilities. September 9, 1999 The team had our initial meeting concerning our new project. It was held in an online format, initially on America Online's Instant Messager software, and eventually through Microsoft Netmeeting, which our meeting was hosted on Steve Grimes' computer. I suggested that we continue to use this type of software and meet in the comfort of our own homes whenever possible, but the team felt that online meetings, although fun to do, took too much time, and were not an efficient way to spend our valuable meeting time. September 15, 1999 I had suggested that we treat our meetings as actual formalized meetings, with someone acting as a president and as a secretary. I offered initially to be the secretary position as I had previous doing that before. I offered that our minutes could be a large section of our team journal, establishing what we did to accomplish our project and when – documenting the entire process. We also began working towards documenting our initial proposal. For this document, I worked on the introduction and the system description. September 28, 1999 I took 20 minutes tonight to review the final project proposal. I also spent around 20 minutes replying to various emails pertaining to the project. I am maintaining a personal collection of the emails, which go back and forth in this project; however, in order to preserve privacy in non-formal communications, these emails will not be presented with the project. At 12:47 am, I am posting some suggested corrections to the proposal document. They include: page 10 - client's (instead of client – as the document presents a possessive form ; page 11 - featured needed for (instead of current misleading phrase, according to a Microsoft word suggestion ). October, 1999 The team agreed we had difficulty getting off to a good start. Reasons for this were A lack of a suitable meeting place and frustration and remorse over the loss of our initial project were reasons contributing to our bad start. This negative feeling began to die as we were granted a lab to work in with suitable space and some project ideas began to come together. October 7, 1999 Previously, I had suggested that we treat our meetings as actual formalized meetings. The team was now doing this, and Joshua had suggested that I, as secretary, keep a running list of what needed to be accomplished – a "to do" list. I began to do this as each weekly set of minutes came out. October 14, 1999 It was now time for our second document to be done. I was elected for the introduction because the team I had a good bit of creativeness, and that I could use that to actually sum up the project in an introduction. I was also assigned the prototype analysis, which consisted of taking a look at the prototype and trying to explain how it should function in the words that someone who had not been there during the development process could understand. October 19-20, 1999 Rough drafts of the above mentioned sections were drafted and posted to the team's website for review. November 18, 1999 We held a meeting to discuss the presentation we were to present showing our progress and future plans for Portable Patients. As this discussion continued, I suggested that as we actually start really developing this project, to try to download the "working prototype" from the project web site, and make your changes to that prototype. This way, we've always got a working prototype. December 12, 1999 As I had been assigned a module to bring the database information into the database from the camera files, I began working on this module. From about 1:00 am until about 1:40 am, I coded a short module to read a sequential file and import fields that would be required for our database. This module was posted on the group's website approximately 2 am in a raw beta form. I plan to research methods for improving this module. One problem I encountered was the fact that I could not "parse" the incoming text file and only read information past the colon (:). I plan to research ways to perform this function from the Internet newsgroups. January 3, 2000 After spending several hours learning how to setup and install newsgroups from the internet as well as reading and evaluating different newsgroups relating to visual basic and database programming, I eventually got tired of reading sex advertisements and sorting through tons and tons of messages that had nothing to do with anything I was trying. On a whim, I decided to scan the fidonet (accessible via a bulletin board system, which I have run since 1996) for a Visual Basic Conference. I was amazed not only that I found one, but also, at the lack of advertisements (since the conference is moderated as all fidonet conferences are), and also at the professionalism of the examples. I plan to introduce the group to this resource. Also, I'll include some sample fidonet messages below: =========================================================================== BBS: Doc's Place Bbs Online. Date: 10-29-99 (19:19) Number: 170 From: JOSH EINSTEIN Refer#: NONE To: WILLIAM HURN Recvd: YES Subj: DB Listbox Hiccup Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:266/512@fidonet.org 42cbbc24 -> I built a program that calls up and prints records from an Access query. An -> invisible (at run time) data control fills a .... -> The operator can then see both individually, and print one at a time. I'm -> off to research Data control and DBListbox properties. I am assuming you remember the lengthy message you posted because I feel it would not do much good to quote it. Anyhow, here is my suggestion to you, but I understand if you are not interested, as it involves rewriting some of the code. 1. UNbind the data list and populate it manually. What I mean is, create a new recordset containing both the last name AND an autonumber field from the table. (SQL server calls these ID fields i believe) 2. Add each last name from the recordset to the list box, but also add the autonumber field to the listbox's ItemData array. List1.AddItem rs("Lastname") List1.ItemData(List1.NewItem) = rs("ID") 3. Then in the List1_Click() event, you simply choose from the data control (which should be the only one) which ID you want, not last name. Sub List1_Click() Data1.RecordSource = "SELECT * FROM MyTable WHERE IDField = " & _ List1.ItemData(List1.ListIndex) Data1.Refresh End Sub This will make your second data control contain ONLY one record and it is the exact one they chose. To make things more intuitive for your user, you should probably add the first name to the first listbox too List1.AddItem rs("Lastname") & ", " & rs("Firstname") Hope this helps. --- QScan/PCB v1.19b / 01-0462 ? Origin: Christian Fellowship | Mt. Ephraim, NJ 856-933-7096 (1:266/512) =========================================================================== BBS: Doc's Place Bbs Online. Date: 10-29-99 (19:25) Number: 171 From: JOSH EINSTEIN Refer#: NONE To: VERONICA BENDERSKY Recvd: NO Subj: Re: Visual Basic Editions Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:266/512@fidonet.org edc1ffaf -> What do you mean when you say "bussiness objects maintained in another -> server" ? I'm rather new to VB. Business objects are compiled "rules" so to speak that an application must follow. For example, assume you have a program that manages customers. In the application you would implement a Customer class. Say the Customer class has a method called SetupService and in this method you do all kinds of magic to the database. Every program your company uses that works with customers should follow the same pattern so should all have the setupservice method. If you put the customer class in a separate project and compile it as a activex DLL or exe you can make sure that all applications that use a customer object work the same way. (because they are all executing the same code). It's like a regular DLL but with objects instead of just functions. But remote business objects take this a step further. They are installed on a remote server. So ONE copy of these DLLs are installed on the whole network and the whole company is using these same modules. This not only ensures consistency, but eases upgrading and deployment issues. When used with MS Transation Server, the code can actually be EXECUTED on the remote server and only the results passed back to your computer. For networks that implement security, this can be a huge benefit to them because they now can define security levels for that one computer and not worry about everyone in the network being able to violate them. I know this is a horribly condensed description and it doesn't do justice to the beauty of business objects. If you are intending to become a serious enterprise developer, I recommend buying Visual Basic 6 Business Objects by Rockford Lhotka. Its a big book, but a good one. samples of it should be found in your "Partial Books" section of the MSDN cd. --- QScan/PCB v1.19b / 01-0462 ? Origin: Christian Fellowship | Mt. Ephraim, NJ 856-933-7096 (1:266/512) =========================================================================== BBS: Doc's Place Bbs Online. Date: 10-31-99 (18:02) Number: 174 From: WILLIAM HURN Refer#: 170 To: JOSH EINSTEIN Recvd: NO Subj: Re: DB Listbox Hiccup Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- -=> JOSH EINSTEIN wrote to WILLIAM HURN <=- WH> I built a program that calls up and prints records from an WH> Access query. An invisible (at run time) data control fills a WH> DBListbox with the last names in the query. The operator WH> selects the record to be printed in the DBListbox. A second WH> invisible data control places all the record data in labeled WH> textboxes on the form. Clicking a Print command button prints WH> the record. It works, but... WH> When two people have the same last name, the DBListbox shows WH> that last name twice but only one of the two complete records WH> shows up in the textboxes and it shows up twice! Say in WH> Access there is a John Miller and a Juan Miller. In VB, there WH> will be a Miller and a Miller, but NOT John and Juan. It will WH> be either two Juans or two Johns. JE> Here is my suggestion to you, but I understand if you JE> are not interested, as it involves rewriting some of the code. I'm interested, I NEED THIS TO WORK! JE> 1. UNbind the data list and populate it manually. What I mean JE> is, create a new recordset containing both the last name AND JE> an autonumber field from the table. JE> (SQL server calls these ID fields i believe) I thought about that. You would use a regular listbox, rather than the databound listbox (DBList) right? JE> 2. Add each last name from the recordset to the list box, but JE> also add the autonumber field to the listbox's ItemData array. JE> JE> List1.AddItem rs("Lastname") JE> List1.ItemData(List1.NewItem) = rs("ID") JE> JE> 3. Then in the List1_Click() event, you simply choose from the JE> data control (which should be the only one) which ID you want, JE> not last name. JE> Sub List1_Click() JE> Data1.RecordSource = "SELECT * FROM MyTable WHERE IDField = " & _ JE> List1.ItemData(List1.ListIndex) JE> Data1.Refresh JE> End Sub JE> JE> This will make your second data control contain ONLY one record JE> and it is the exact one they chose. To make things more intuitive JE> for your user you should add the first name to the listbox too JE> List1.AddItem rs("Lastname") & ", " & rs("Firstname") JE> JE> Hope this helps. Undoubtedly it would have but I was able to use the account number, which is unique to each record as follows: I was loading the DBListbox with a second data control and using code to advance the primary data control to match the user-selected last name. I still have the second data control loading the last names in the DBListbox but I also set up the DBListbox to obtain the Account Number as BoundText(BoundColumn property). I am now using code and the BoundText account number (rather than the text last name) to advance the first data control to the record matching the one the operator clicks) Now you can click each of the last names in the DBLIstbox and see each individual record, even though some last names are identical. Thank you and the others on this Echo who took the time to respond to my many questions. I have saved your message for reference during future programming efforts. ... MultiMail, the new multi-platform, multi-format offline reader! --- MultiMail/MS-DOS v0.26 =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-07-99 (17:52) Number: 184 From: WILLIAM HURN Refer#: NONE To: ALL Recvd: NO Subj: SQL Help! Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- I need to build a recordset using class start dates from a DBListbox that I'm loading with a DataControl. The following SQL statement was built in Access and chopped up a bit to get it in this message. It runs properly and fills a second DBListbox with LastName entries BUT ONLY when the date is entered as below with the # symbols around it, the way it came from Access and only when the PARAMETERS statement in the first line is remarked out. Following from the DBList2 click event ' SqlStr2 = "PARAMETERS RecDate Date; " & "SELECT DISTINCTROW [New Student query].LastName," & "[New Student query].[Account Number]," & "[New Student query].[Start Date]" & "From [New Student query]" & "Where ((([New Student query].[Start Date]) = #10/18/99#))" & "ORDER BY [New Student query].LastName;" RecDate = DBList2.Text Debug.Print RecDate 'NOTE: this prints correctly e.g. 10/18/99 Set RS2 = LoanAgreeDb.OpenRecordset(SqlStr2, dbOpenSnapshot) Set Data2.Recordset = RS2 Data2.Refresh I have tried using a date variable, text variable, string vaiable, etc. I also tried entering DBList1.Text directly in the SQL statement and even putting "#'s" around it like Access did, No go! I keep getting error messages about "number of PARAMETERS (usually one) less than expected. How can I get the SQL string to accept a date value from DBList1? ... MultiMail, the new multi-platform, multi-format offline reader! --- MultiMail/MS-DOS v0.26 =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-07-99 (19:20) Number: 187 From: PETER DALTON Refer#: NONE To: ALL Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 4df58525 Hi Everyone, I have a program that I wrote to analyse the log-files from our telephone system. These files are simple text with one full line holding a single calls data. Up to now I've been opening the file for input and then reading each line into a Listbox for display. A simple routine allows a text input which the program then searches for using instring, if it finds a match it copies that line over to a second Listbox to display all the calls made by any chosen extension, it works OK for a few days worth of data but it is slow. The problem is I've updated the program to search multiple files and in this case it doesn't load each file, it opens them in turn, grabs each line in turn and then checks for a match as before. The major difference now is you can go away for a cup of tea and come back later to find it's still spooling through files... So is there a quicker way? I wondered if I'd need to rewrite the whole thing to (possibly) add each new file into a large (possibly) Access database which could be done every few days and then to search that database when I wanted specific data? Any ideas please? Oh, the only thing we can't do is alter the output from the phone system... Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-09-99 (19:26) Number: 191 From: FRANCOIS ROY Refer#: NONE To: PETER DALTON Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 790daa04 REPLY: 2:25/108.9 4df58525 PD> The problem is I've updated the program to search multiple files and in PD> this case it doesn't load each file, it opens them in turn, grabs each PD> line in turn and then checks for a match as before. 1- When you Open a file For Input, you can specify a LEN = parameter that will make the buffers larger and it will speed things up a bit (nothing drastic, but it will help). The default Len is 512; try 2048 or even 4096 (has to be multiples of 512). 2- When searching multiple files, I hope you open one file, and search it in its entirety BEFORE you go on to the next file; hopping back and forth between files is likely to be much slower than processing them one at a time. 3- Are you searching the content of the List box (after populating it from the file(s)? You would likely get faster results if you load a copy of what's in the ListBox into a string array, and perform the searches in the array, especially if multiple searches can be performed on the same content. --- Msged 4.00 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-10-99 (07:59) Number: 192 From: DAVE HAMILTON Refer#: NONE To: WILLIAM HURN Recvd: YES Subj: SQL Help! Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- REPLY: 1:3603/140 dfd95215 MSGID: 1:351/206 382926b9 CHRS: IBMPC 2 TID: FastEcho 1.45a 10440 About that message on 11-07-1999 from WILLIAM HURN to ALL: Assuming you have RecDate declared and populated as a variable somewhere, WH> ' SqlStr2 = "PARAMETERS RecDate Date; " WH> & "Where ((([New Student query].[Start Date]) = #10/18/99#))" Try this: "WHERE ((([New Student query].[Start Date]) = '" & RecDate & "'))" --- FleetStreet 1.22+ ? Origin: Aurora Exploratoria - Ladysmith, BC, Canada (1:351/206) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-11-99 (07:34) Number: 200 From: PETER DALTON Refer#: NONE To: FRANCOIS ROY Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 47800fb5 REPLY: 1:163/506 790daa04 On (09 Nov 99) Francois Roy wrote to Peter Dalton... Hi Francois, FR> 1- When you Open a file For Input, you can specify a LEN = parameter that FR> will make the buffers larger and it will speed things up a bit (nothing interesting, thanks! FR> 2- When searching multiple files, I hope you open one file, and search it FR> in its entirety BEFORE you go on to the next file; hopping back and forth yes, then I close that file before opening the next one. FR> 3- Are you searching the content of the List box (after populating it from FR> the file(s)? You would likely get faster results if you load a copy of I do if it's a single file, the delay isn't too bad in this case and it actually looks on screen that the PC is 'doing something'. When searching multiple files I decided not to 'load' each one but to read each line in turn and discard any that don't have the search string in. FR> what's in the ListBox into a string array, and perform the searches in the FR> array, especially if multiple searches can be performed on the same I womdered about this. When I first wrote the program I used an array as that's what I would have done in QB4.5. However it didn't seem to work as I expected, I had some problems with it. As I recall it stopped when trying to load larger files into an array, and then I had to copy everything to a list-box to display it anyway, so I dropped the Array idea. It's probably time to re-create it. What, if any, is the size limit on a dimmed array please? Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-13-99 (09:22) Number: 204 From: FRANCOIS ROY Refer#: NONE To: PETER DALTON Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 793cdb08 REPLY: 2:25/108.9 47800fb5 PD> It's probably time to re-create it. What, if any, is the size limit on PD> a dimmed array please? With VB4 and prior versions, string arrays were quite limited (around 64K if I remember), but with VB5 and above, you should be able to load several hundred K and more without problems. I think the limits are documented but all that stuff is at work, an I'm not there right now... --- Msged 4.00 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-12-99 (21:46) Number: 205 From: WILLIAM HURN Refer#: 192 To: DAVE HAMILTON Recvd: NO Subj: Re: SQL Help! Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- -=> DAVE HAMILTON wrote to WILLIAM HURN <=- DH> About that message on 11-07-1999 from WILLIAM HURN to ALL: DH> DH> Assuming you have RecDate declared and populated as a variable somewhere, DH> DH> WH> ' SqlStr2 = "PARAMETERS RecDate Date; " DH> DH> WH> & "Where ((([New Student query].[Start Date]) = #10/18/99#))" DH> DH> Try this: DH> DH> "WHERE ((([New Student query].[Start Date]) = '" & RecDate & "'))" Actually I had a couple more glitches in my code and ended up solving it this way: RecDate = DBList2.BoundText 'from the first DBListbox SqlStr2 = "PARAMETERS StartDate Date; " "Where ((([New Student query].[Start Date]) = StartDate))" Set QD = LoanAgreeDb.CreateQueryDef("", SqlStr2) QD!StartDate = RecDate Set RS2 = QD.OpenRecordset(dbOpenSnapshot) Set Data2.Recordset = RS2 Thank you for your very informative & useful response. ... MultiMail, the new multi-platform, multi-format offline reader! --- MultiMail/MS-DOS v0.26 =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-15-99 (22:11) Number: 214 From: PETER DALTON Refer#: NONE To: FRANCOIS ROY Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 d63c24af REPLY: 1:163/506 793cdb08 On (13 Nov 99) Francois Roy wrote to Peter Dalton... Hi Francois, PD> It's probably time to re-create it. What, if any, is the size limit on PD> a dimmed array please? FR> With VB4 and prior versions, string arrays were quite limited (around 64K FR> if I remember), but with VB5 and above, you should be able to load several FR> hundred K and more without problems. I think the limits are documented but ok, thanks. The program is almost finished now, I found a glaring error that was causing the major part of the problem. I was loading into a List Box with that List Box visible. Setting Visible to False until after filling it increased the speed incredibly. It now loads a file in part of a second where before it was taking 5 - 10 seconds to load it. I can search a dozen files for every occurence of an particular telephone number and display the results in just a few seconds. One thing I tried to do was to get a simple sign showing on screen with 'Please wait', and I tried to do this with a Text Box. I assumed that I could switch it to visible/invisible at the appropriate times, but it doesn't work. The List Box is always shown. I thought there was some way of setting a particular item to be 'always on top' but I can't seem to find it. Is this correct and, if so, what's the command to make a text box show up by switching Visible between True and False please? I later thought that if I could get this to work then another minor enhancement that would make a big impact would be to display the name of the current file being scanned so a user might know how far the program had got (and in fact it would also show them that the program was still running). Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-17-99 (18:17) Number: 215 From: FRANCOIS ROY Refer#: NONE To: PETER DALTON Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 79767bb0 REPLY: 2:25/108.9 d63c24af PD> Is this correct and, if so, what's the command to make a text box show PD> up by switching Visible between True and False please? You need to give the CPU a break so it can refresh the window: after switching the Visible state of the text box, throw in a DoEvents. --- Msged 4.00 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-19-99 (07:36) Number: 220 From: PETER DALTON Refer#: NONE To: FRANCOIS ROY Recvd: NO Subj: faster loading? Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 d1b29645 REPLY: 1:163/506 79767bb0 On (17 Nov 99) Francois Roy wrote to Peter Dalton... Hi Francois, PD> Is this correct and, if so, what's the command to make a text box show PD> up by switching Visible between True and False please? FR> You need to give the CPU a break so it can refresh the window: after FR> switching the Visible state of the text box, throw in a DoEvents. I found another way, frantically trying to remember it now... ah yes, change the text, switch Visible to true and then set the text box to 'have focus' (or whatever the actual commnand is). When I next switch the TextBox Visible to false, the focus comes back to the ListBox and it displays as I want it to. Your method is probably a lot better though, I'll play around with it later. Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-26-99 (08:31) Number: 225 From: SHAUN EWING Refer#: NONE To: ARMANDO SILVA Recvd: NO Subj: POP3 Mail Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- XN1-161 NOTE: IceEdit 2.20 M17220 REPLY: 1:271/140.2 84d17639 MSGID: 1:396/45.21 5ddce2ec PID: RA 2.5 1161 * In a message originally to All, Armando Silva said: AS> Does anyone know where I can get info on the commands for POP/SMTP AS> format mail ? Thanks in advance! Check out rfc1725 for Post Office Protocol (POP3) and rfc821 for Simple Mail Transfer Protocol (SMTP). If you cannot find these on the Internet, send an email to: freq@flashmail.com , Subject: FREQ Body: FREQ RFC1725 FREQ RFC821 You will receive the files via email attachment within 24 hours. Anybody can use the requester if they like. Regards, Shaun Ewing. Sys Admin: Aus Internet Web: http://www.aus.dhs.org/ Email: shaun@aus.dhs.org ... It said "insert disk #3" - but onty two will fit... --- FMail/Win32 1.22 ? Origin: Shauns Point. Sydney, Australia. shaun1aus.dhs.org (1:396/45.21) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-21-99 (23:51) Number: 228 From: TOM LAERMANS Refer#: NONE To: PATRICK LOGIST Recvd: NO Subj: playing wav files Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:292/624.10 4de257bc REPLY: 2:292/624.28 27287ad8 PID: TerMail 5/Pro ff364407ff Hi Patrick ... At 19-Nov-99 16:18:53, Patrick Logist wrote to All about playing wav files... PL> Can somebody please tell me how to play wav files in VB 5. By using the MCI32.OCX control? Or WinMM.DLL or something... Some function... But I don't know *exactly* ... [Email: sidewind@softhome.net] [ICQ: #12120754] --- Terminate 5.00/Pro ? Origin: Tadadadaaaaaaaaaaaaa ;-) (2:292/624.10) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-27-99 (23:34) Number: 230 From: FRANCOIS ROY Refer#: NONE To: PATRICK LOGIST Recvd: NO Subj: playing wav files Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 79fd3b46 REPLY: 2:292/624.28 973fdb07 PL> Subject: playing wav files PL> Thanks Tom but I need some code for that :-) Well, I have an old Win3.1 computer at home; all the 32-bit stuff is at the office. However, if I give you the code to do it in 16-bit mode, you should be able to find the corresponding declaration for the 32-bit API call in the docs that came with VB5. ' The following Declare statement must appear on one line. Declare Function sndPlaySound Lib "MMSYSTEM.DLL" (ByVal lpszSoundName$, ByVal wFlags%) As Integer Global Const SND_SYNC = &H0000 Global Const SND_ASYNC = &H0001 Global Const SND_NODEFAULT = &H0002 Global Const SND_LOOP = &H0008 Global Const SND_NOSTOP = &H0010 Add the following line of code to the appropriate function or subroutine in your application: SoundName$ = "c:\windows\tada.wav" wFlags% = SND_ASYNC Or SND_NODEFAULT x% = sndPlaySound(SoundName$,wFlags%) --- Msged 4.00 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) =========================================================================== BBS: Doc's Place Bbs Online. Date: 11-29-99 (18:34) Number: 234 From: PATRICK LOGIST Refer#: NONE To: FRANCOIS ROY Recvd: NO Subj: playing wav files Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:292/624.28 8ef0005c REPLY: 1:163/506 79fd3b46 PID: TerMail 5/Pro fe25112eaf Hi Francois, Quoted From: Francois Roy To: Patrick Logist Date: 27-Nov-99 Subject: playing wav files PL>> Subject: playing wav files PL>> Thanks Tom but I need some code for that :-) FR> ' The following Declare statement must appear on one line. FR> Declare Function sndPlaySound Lib "MMSYSTEM.DLL" (ByVal FR> lpszSoundName$, ByVal wFlags%) As Integer I found the correct declaration in the api text viewer, thanks for your help Francois. Greetings from Patrick. .!. I must be using the wrong kind of hammer for this screw. --- Terminate 5.00/Pro ? Origin: Ever danced with the devil in the pale moonlight? (2:292/624.28) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-01-99 (18:48) Number: 236 From: FRANCOIS ROY Refer#: NONE To: VERONICA BENDERSKY Recvd: NO Subj: .hlp files Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 7a3c8896 REPLY: 4:901/134.61 68e86420 VB> Does anybody know how are .hlp files created? Which program does that? The answer used to be simple. Now, it depends... With the older versions of VB (up to v5 I believe), Windows Help files were created using a Help Compiler (provided with VB Pro and up) that operates on files created by a word processor (such as Word) and saved as .RTF files (Rich Text). With VB6 and Win98 came "HTML Help". I haven't yet investigated to see if VB6 includes the tools to create HTML Help... There are also third-party softwares (shareware as well as commercial) that help you in putting a "Help Project" together. It's worth searching your favorite BBS or the Web... --- Msged 4.00 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-05-99 (14:26) Number: 237 From: WILLIAM HERRINGTON Refer#: NONE To: FRANCOIS ROY Recvd: NO Subj: .hlp files Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- EID:1176 026cdec0 MSGID: 1:374/38@fidonet.org a98e57f0 REPLY: 1:163/506 7a3c8896 PID: FM 2.2c.mL OC000101 > VB> Does anybody know how are .hlp files created? Which program does that? > The answer used to be simple. Now, it depends... > With the older versions of VB (up to v5 I believe), > Windows Help files were created using a Help Compiler > (provided with VB Pro and up) that operates on files > created by a word processor (such as Word) and saved > as .RTF files (Rich Text). > With VB6 and Win98 came "HTML Help". I haven't yet > investigated to see if VB6 includes the tools to > create HTML Help... Yes, both are on the vb6 cd... the html help is in a sub directory right off the root... the older version is hidden several sub directories down and, is not made clear to the casual user. Bill http://ddi.digital.net/~bill --- ? Origin: SaddleBag BBS in Saddlebag Beach, Florida 407 773 0831 (1:374/38) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-06-99 (14:27) Number: 238 From: TOM LAERMANS Refer#: NONE To: VERONICA BENDERSKY Recvd: NO Subj: .hlp files Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:292/624.10 e814f98d REPLY: 1:163/506 7a3c8896 PID: TerMail 5/Pro ff364407ff Hi Veronica ... At 01-Dec-99 18:48:27, Francois Roy wrote to Veronica Bendersky about .hlp files... VB>> Does anybody know how are .hlp files created? Which program does VB>> that? FR> [ms] VB5 includes "Microsoft Help Workshop" ... Dunno if that supports HTML help, though... FR> There are also third-party softwares (shareware as well as FR> commercial) that help you in putting a "Help Project" together. FR> It's worth searching your favorite BBS or the Web.. Try HelpScribble... Kinda good :-) URL: www.jgsoft.com [Email: sidewind@softhome.net] [ICQ: #12120754] --- Terminate 5.00/Pro ? Origin: Skynet BBS (2 Nodes) - +32-(0)16-580862 v90/ISDN (2:292/624.10) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-17-99 (21:46) Number: 241 From: MATTY JAMES NEALE Refer#: NONE To: ALL Recvd: NO Subj: Please Can You help Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:2502/123 385af5a015abc0 PID: Beemail 0.392 / F0EEEA2A INTL 0:0/0 2:2502/123 Dear all, I've only just started propgramming and wondered how to do something i belive is called indexing. so that i can read infomation that is stored in and ini files. for example: if i made a proram that needed the user name and password to be correct i could store the data like this:- Username | Password Fred | qwerty john | berty ect ect but how do you read this infomation so that it forund the user name say fred found the | key and them checked that the password matched the user name. i have been told it is possiable but how?? thanks alot /\/\atty --- Beemail 0.392 / F0EEEA2A ? Origin: Darkside - www.darkside-hull.co.uk (2:2502/123) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-20-99 (07:34) Number: 242 From: PETER DALTON Refer#: NONE To: MATTY JAMES NEALE Recvd: NO Subj: Please Can You help Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 a6534625 REPLY: 2:2502/123 385af5a015abc0 On (17 Dec 99) Matty James Neale wrote to All... Hi Matty, MJ> could store the data like this:- MJ> Username | Password the simplest way is: Open "Path\Filename" For Output as #1 Write #1, User, Password Close #1 and Open "Path\Filename" For Input as #1 While Not EOF(1) Input #1, User Input #1, Password 'test if user name matches 'if it does then test that password is correct Wend Close #1 Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-28-99 (08:37) Number: 246 From: CHRIS CRANFORD Refer#: NONE To: ALL Recvd: NO Subj: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:379/1200 3868BCCC Hello Everyone! I am using VB5 and I need to be able to calculate a 32-bit CRC value for a string of values. Could someone tell me how this is done? I am needing this to check for duplicates in my mail tosser I am currently working on .. I have it calculating a Check Value of the message now, but it's not a true 32-bit CRC and with a true 32bit CRC value, I could eliminate some fields in my database making it smaller and not taking up so much room... Any help is greatly appreciated... And finally, I am using a form which tracks the status of my tosser.. It has a textbox which I am using as a scrolling box to display what the tosser is doing and the most recent information is attached at the bottom of the textbox... The problem is that once the textbox goes to lets say about 15 lines of text, and I'm using frmstats.scrollbox.selstart = len(frmstats.scrollbox.text) to scroll the window to the bottom. The problem is only really when the tosser if going VERY fast the the application has to append to the textbox, it then reset the scrollbox to the first line of the textbox and then I have the above line of code scroll to the bottom.. The screen flickers when this is done... I also use DoEvents() in this update loop to allow some Time slices to be returned to the PC so that it does not tie up the entire system 'cause the loop could continue for 5-10 minutes at a time... Can anyone tell me how to prevent the screen from flickering when doing the selstart thing? Thanks, Chris Cranford --- Mail-ennium v1.0.5a ? Origin: www.tkdsoftware.com (1:379/1200) =========================================================================== BBS: Doc's Place Bbs Online. Date: 12-28-99 (18:37) Number: 249 From: CHARLES GAEFKE Refer#: NONE To: CHRIS CRANFORD Recvd: NO Subj: Re: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:129/230 38c5073c REPLY: 1:379/1200 3868bccc PID: CDRMAIL v1.22FO TID: GE 1.11+ CC> I am using VB5 and I need to be able to calculate a 32-bit CRC value for CC> a string of values. Could someone tell me how this is done? I am CC> needing this to check for duplicates in my mail tosser I am currently CC> working on .. I have it calculating a Check Value of the message now, CC> but it's not a true 32-bit CRC and with a true 32bit CRC value, I could CC> eliminate some fields in my database making it smaller and not taking up CC> so much room... Any help is greatly appreciated... My advice is to use a 32-bit C DLL to calculate the value. I have the code here in C for it that I could easily make a 32-bit Win32 DLL for you. EMail me at the below address if this is the way you want to go. I'll give you the C source as well. Of course, you'll have no way of knowing for certain that I didn't put anything else in the DLL. You'll just have to trust me on that, just like you trust Microsoft with your hard drive by running Windows. CC> to scroll the window to the bottom. The problem is only really when the CC> tosser if going VERY fast the the application has to append to the CC> textbox, it then reset the scrollbox to the first line of the textbox CC> and then I have the above line of code scroll to the bottom.. The screen CC> flickers when this is done... I also use DoEvents() in this update loop CC> to allow some Time slices to be returned to the PC so that it does not CC> tie up the entire system 'cause the loop could continue for 5-10 minutes CC> at a time... Can anyone tell me how to prevent the screen from CC> flickering when doing the selstart thing? I don't know how to stop the flickering, but I do know that "doevents" doesn't free up time slices. The Windows API Sleep does that. AFAIK DoEvents just allows VB to run other events waiting to "fire" in that app. C. Gaefke cdgaefke@earthlink.net ... Ever feel like firing your boss? --- Renegade 98-310 Dos/CDRMail v1.23.b1.1 ? Origin: LOTL/2 * www.icubed.com/~cdgaefke (1:129/230) =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-05-00 (08:08) Number: 254 From: CHARLES GAEFKE Refer#: NONE To: CHRIS CRANFORD Recvd: NO Subj: Re: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:129/230 38df0cbd REPLY: 1:379/1200 386ae984 PID: CDRMAIL v1.22FO TID: GE 1.11+ CC> I think a friend of mine who does a lot of Win32 programming in Delphi CC> and Visual C has some code I'm going to check out on the flickering.. My CC> major problem was making sure that while I was in a TIGHT-NESTED loop of CC> updating statistics while it was tossing mail that the mail tosser was CC> able to update the labels and data fields on the form as well as allow CC> the user of the PC to minimize, maximize, or perform any other Win32 PC CC> related action and not have to WAIT on the mail tosser to complete. Now CC> I can say that DoEvents has worked, but it has SLOWED the process down. CC> I can usually SCAN mail faster than I toss mail and I think it's because CC> when I am tossing the mail I open the PKT file and read directly from CC> disk into my program. I think if I read from MEMORY that will allow my CC> TOSSING to run faster. How do I load a binary file into memory and read CC> it from memory instead of from disk? IMHO doing anything that required extensive file manipulation should -not- be done in VB. It just plain isn't efficient, as I'm sure you've discovered. I was a C programmer long before I was a VB programmer. File manipulations in C are so easy and logical. VB, well, to put it bluntly, sucks. I've also learned that in many cases, it's much easier and efficient to do the hard work in C DLLs and let VB make the pretty interface. C. Gaefke cdgaefke@earthlink.net ... Have your dreams come true? --- Renegade 98-310 Dos/CDRMail v1.23.b1.1 ? Origin: LOTL/2 * www.icubed.com/~cdgaefke (1:129/230) January 4, 2000 Once reading through several messages in the visual basic conference, I posted the following message introducing myself as well as my primary purpose for introducing conversation. I also commented on a debate that was taking place in the conference. =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-04-00 (05:23) Number: 252 From: JAY FULLER Refer#: 243 To: ALL Recvd: NO Subj: Comments... Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- CH>Except there wouldn't of ever been a netscape had there not be large CH>government subsidies giving the man who is now netscape's principle CH>officer the money and resources to develop what is now netscape. CH>Netscape wouldn't exist had there not been government handout's and CH>today couldn't exist with out -strong- government (Joel Klein) support. Greetings, folks, I have just joined this conference as the proud system operator of "Deep Space Nine BBS" in Cullman AL. Now-a-days, I'm providing the BBS services for a handful of people in my hometown of Cullman AL while I attend college in Mobile AL at the University of South Alabama. I am pursuing a new degree, Information Technology, which is a track of Computer and Information Science at this school. I have joined this conference to learn more about visual basic which I had (windows scripting concepts and advanced databases) both actually taught in VB. (version 5). The school has now offically moved up to version 6, but if you'll just file this info for a little bit, I want to present you all with the "story" of Netscape as presented and is generally accepted by most universities across the US. This same concept is also the explanation understood for the reason Netscape was formed out of Mosaic. Property developed on a University campus _IS_ the property of that university (this was a hard learned lesson, and much of the messages I write here initially will go directly to a senior project which we are working on - as I said, more info later...). In order to take a product developed under grant or under a university's orders, you must create what our instructors call "Version _2_". You must change the program and add / modify / and improve the product enough where it is substantially different from the "prototype" or last known version of the University's owned software. Folks, the popularity of the browser was realized. I forget the end of the story, but someone wised up and recruited a lot of the team that developed Mosaic, and that is how Netscape was formed. They took Mosaic (which I used as I _FIRST_ came on the internet), and added and changed enough of it - improved upon it - to form Version 2 - Netscape. That's all there is to it - at least as I was taught to understand it. Incidently, when all this was happening, (I'm guessing around 1992-1994?) - I was in High School. My hometown of Cullman did not get the internet until mid-1995 - shortly after I graduated. Therefore, my version of events is not "distorted" by any observations I may have made along the way -- but I will tell you all this. I researched the internet signifigantly in 1995 while producing my senior term paper. This included researching nearly every magazine and article relating to the internet I could get my hands on - and I never saw any report of that security bug. Furthermore, it would make sense to me for the press to keep something like that relatively quiet if they found out about it - becuase otherwise, you'd have hackers trying to get into hard drives all the time -- just like you do now-a-days, when a problem crops up with some winsock.dll bug (2 years ago...someone could run "winnuke" while you're in irc...and you're gone...because your IP address was publically visable - just for ONE example), and your continuing problems you have now with the outlook express / macro viruses..if these things were ONLY reported to Microsoft, and not to the press, perhaps we would not suffer so many outages. Nevertheless, I never meant to raise any more cain over this subject- I've just read all the messages in this conference dating back to October, 1999, and was getting furious at some of the conversation which took place. :) I wasn't going to reply until I realized this thread was "semi-active" as of 12-15-1999, and hey...? what better way to introduce myself. ;-) Thank you very much, Sincerely, Jay Fuller SysOp: Deep Space Nine BBS, Cullman AL ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- ------------------------------------------------------------------------ (if you're wondering, i can't access DSN long distance from Mobile easily, so I use a telnet BBS while I'm at school. I still get at least one mail packet from DSN per week) * OLX 2.1 TD * Resistince is futile! January 7, 2000 I made a suggestion to the team regarding a history type file. If someone else is going to make some changes to the prototype, they need to keep a version history file updated telling everyone what was done to the prototype, and when it was done. A small file should be emailed to the team when updates are being made, so if there are any problems with overwriting one another's additions, the team will be aware that the prototype is being modified. This will also allow for me to keep documented what changes take place when. January 8, 2000 I finally got around to posting a message in the fidonet visual basic conference concerning the team's project. My message requested information about how to accomplish my specific goal. Read the message: =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-08-00 (15:23) Number: 843 From: JAY FULLER Refer#: NONE To: ALL Recvd: NO Subj: Reading a Text File 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- Greetings everyone again, As promised, I have returned to the echo with a question reguarding a programming project for "Senior Project" here at the University of South Alabama. The team I am working with is attempting to write a piece of software to read a file from a Kodak DC-290 digital camera which is produced internally to the camera using "digita" scripting, which comes with the camera. We are reading this text file, along with an image, to import information into a database maintained by the Visual Basic front end. The text file I am trying to import looks like this: (P:\patients.txt) Number:1234567890 Path:/DC_290 Filename:P0000331.JPG Date: Time: Far: Close: First:Adam Last:Helewski Gender:M Keyword1:AA Keyword2:B Keyword3:Q Number:5678901234 Path:/DC_290 Filename:P0000332.JPG Date: Time: Far: Close: First:Yvonne Last:Totty Gender:F Number:2345678901 Path:/DC_290 Filename:P0000334.JPG Date: Time: Far: Close: First:Jay Last:Fuller Gender:M Keyword1:X Keyword2:CD Keyword3:P Keyword4:OP Keyword5:W Number:3456789012 Path:/DC_290 Filename:P0000335.JPG Date: Time: Far: Close: First:Josh Last:Carter Gender:M Keyword1:W Number:2345678901 Path:/DC_290 Filename:P0000336.JPG Date: Time: Far: Close: First:Jay Last:Fuller Gender:M Keyword1:X Keyword2:CD Keyword3:P Keyword4:OP Keyword5:W Number:2345678901 Path:/DC_290 Filename:P0000337.JPG Date: Time: Far: Close: First:Jay Last:Fuller Gender:M Keyword1:X Keyword2:CD Keyword3:P Keyword4:OP Keyword5:W Number:6789012345 Path:/DC_290 Filename:P0000338.JPG Date: Time: Far: Close: First:Steven Last:Grimes Gender:M Keyword1:ST Keyword2:PR Keyword3:WE Keyword4:B Keyword5:AA ...as you can see....there are variable lines...depending on how many "keywords" the person who took the photo selected. On top of this, I need to be able to read the fields ONLY on the right hand side of the colon. I've started by trying to read everything out of the text file, line by line, as I learned a while back in a lab. However, it's not smart enough to learn what to look for. :) On top of that....I obviously need to learn to count characters or something (i guess i could do that manually..) - is there a way to look for the colon and 'record' only what is on the right side of it? here is the code as I now have it: Sub selectfile() 'called when user needs to select the file CdlPatient.ShowOpen 'shows user a dialogue to select the file they wish to work with (must be patients.txt) frmImportPatients.Caption = frmImportPatients.Caption & " - " & Me.CdlPatient.Filename ' adds file selected to title to prove a file has been selected If CdlPatient.Filename = "" Then End End Sub Private Sub CmdProcess_Click() Call selectfile Dim PatientNum As Integer Dim Path As String Dim Filename As String Dim FileDate As Date Dim Time As String Dim Fardata As Integer 'data used because 'close' is a reserved vb word Dim Closedata As Integer ' " " Dim First As String Dim Last As String Dim Gender As String Dim Keyword1 As String Dim Keyword2 As String Dim Keyword3 As String Open CdlPatient.FileTitle For Input As #1 While Not EOF(1) Input #1, PatientNum, Path, Filename, FileDate, Time, Fardata, Closedata, First, Last, Gender, Keyword1, Keyword2, Keyword3 PicData.Print PatientNum; Path; Filename; FileDate; Time; Fardata; Closedata; First; Last; Gender; Keyword1; Keyword2; Keyword3 MsgBox "RECORD COMPLETE" Wend Close #1 End Sub Private Sub Form_Activate() MsgBox ("Your best bet is to download the .frm file and step through to see what's happening. Currently, there are labels before the text { __FIRST NAME:__ <<-- [label] } which are causing complications. Also, the length of the 'data segments' are also variable. This will require some extra coding. In the meantime, though, this demo shows that the file can be selected and can be assigned to certain variables and printed on the screen. It should be relatively easy to link these to a database at a later time. -Jay Fuller, 2:08 AM ; December 12, 1999 ") MsgBox ("This program will eventually exit with an 'input past end of file' error.") End Sub ...any suggestions are GREATLY appreciated!!.. Thank you very much, Jay Fuller ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- January 9, 2000 I received my first reply to the above message. =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-08-00 (19:59) Number: 259 From: FRANCOIS ROY Refer#: NONE To: JAY FULLER Recvd: NO Subj: Reading a Text File 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 38779829 REPLY: 1:3603/140 150713ef JF> On top of that....I obviously need to learn to count characters or JF> something (i guess i could do that manually..) - is there a way to look JF> for the colon and 'record' only what is on the right side of it? I have no intention of immersing myself in your code, but I can certainly answer some of your questions. First of all, I do believe that reading the file line by line _is_ the way to go. It's then only a matter of parsing the information. VB comes with many string-manipulating functions. For example, the value of InStr(LongString, StringToLookFor) returns the position of the 2nd string in the 1st string. This is how you'd find the colon. Functions such as Left and Mid let you cut strings into substrings (for example separating the keyword from the rest of the string). --- Msged TE 05 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) …and my reply… =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-10-00 (01:01) Number: 843 From: JAY FULLER Refer#: 259 To: FRANCOIS ROY Recvd: NO Subj: Reading a Text File Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- FR>JF> On top of that....I obviously need to learn to count characters or FR>JF> something (i guess i could do that manually..) - is there a way to look FR>JF> for the colon and 'record' only what is on the right side of it? FR>I have no intention of immersing myself in your code, but I can certainly FR>answer some of your questions. First of all, I do believe that reading the FR>file line by line _is_ the way to go. It's then only a matter of parsing th FR>information. ahh...okee... FR>VB comes with many string-manipulating functions. For example, the value of FR>InStr(LongString, StringToLookFor) returns the position of the 2nd string in FR>the 1st string. This is how you'd find the colon. Sounds good....I remember referencing some of this material earlier. FR>Functions such as Left and Mid let you cut strings into substrings (for exam FR>separating the keyword from the rest of the string). thank you very much for your assistance...I guess I'll get started on this module...only got 5 months to finish it. :) Thank you, Jay Fuller ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- ------------------------------------------------------------------------ ? OLX 2.1 TD * Mr.Worf!!,Is that Sinister's Merchant Cruiser??? January 10, 2000 Additional replies will be listed here. =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-09-00 (10:31) Number: 261 From: CHARLES GAEFKE Refer#: NONE To: FRANCOIS ROY Recvd: NO Subj: Re: Reading a Text File Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:129/230 38d4e765 REPLY: 1:163/506 38779829 PID: CDRMAIL v1.22FO TID: GE 1.11+ FR> I have no intention of immersing myself in your code, but I can certainly FR> answer some of your questions. First of all, I do believe that reading the FR> file line by line _is_ the way to go. It's then only a matter of parsing t FR> information. It -is- the way to go if you are using VB. The result will be a slow and cumbersome process, but that usually goes unnoticed on high end PCs anymore. It's sad but it's true. It's be much more efficient (and easier IMHO) to process it in C. I still haven't figured out why MS made VB so backwards when it comes to file manipulation. C. Gaefke cdgaefke@earthlink.net ... I love my job! Do you? --- Renegade 98-310 Dos/CDRMail v1.23.b1.1 ? Origin: LOTL/2 * www.icubed.com/~cdgaefke (1:129/230) January 12, 2000, 1:46 am We had our first Senior Project meeting of the new semester today. The team also went out to lunch afterwards and discussed the classes we were all taking during the spring. We encouraged each other to continue work on our project now so we could finish it up and work towards beta testing it because our other classes would be time intensive as time went on. We discussed creating a master file on the visto website which is serving as our team's file server. We also decided if we are going to be making changes to the online prototype then we needed to indicate that somehow. This lead to the creation of informal version numbers (which Josh came up with) to identify who made which change and when. Yvonne made the master file folder tonight and started a version history document. I created a "busy" flag – basically a text file which identifies who is actively working on the project and when they expect the prototype to be updated online with their changes. This is mainly to prevent team members from writing over each other's work by labeling either "No one is working on this version" or something to the effect of "Jay Fuller - got the file at 1:41 am - expect to return updates at 3:00 am. Coding about 70% of import module." Also, team members would change the name of this file to reflect the version number and add a "-busy" flag if they are working on it in real time. (example: 01.01.01.02.txt or 01.02.01.03-busy.txt). With those organizational tasks out of the way, I've looked into the coding of the module to import patient data from the camera and have noticed too many fields in the incoming data. This process works by the camera creating a "patients.txt" file internally which is read by the visual basic program when it is importing information from the camera. An example of this file would appear like this: Number:1234567890 Path:/DC_290 Filename:P0000331.JPG Date: Time: Far: Close: First:Adam Last:Helewski Gender:M Keyword1:AA Keyword2:B Keyword3:Q The number would correspond to the patient number in the database. The path would correspond to the directory on the camera's virtual drive that the photos reside on. The date and time correspond to the date and time the file was created. Far and Close, however, do not correspond to anything found in either the database nor the most recent documentation we have turned in. The file will have to be read line by line to accommodate for additional keywords. Example code as retrieved from the BBS system can help to read each side of the colon to see what information is being read. January 12, 2000, 3:05 am More replies came in through the BBS system which can assist me in the project: =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-11-00 (17:47) Number: 268 From: CHRIS CRANFORD Refer#: NONE To: JAY FULLER Recvd: NO Subj: Reading a Text File 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:379/1200.0 387BB1D7 -> Number:1234567890 -> Path:/DC_290 -> Filename:P0000331.JPG -> something (i guess i could do that manually..) - is there a way to look -> for the colon and 'record' only what is on the right side of it? Jay, in order to pull the text from the left-hand side, use: LeftHandSideVariable = Mid(InputText, 1, Instr(1, InputText, ":", vbtextcompare)-1) What this means is to pull out of the string starting at character 1, and continue through the location of the ":" character minus 1 character location.. So this would pull out: "Number", "Path", and "Filename". If you want to pull out the right side of the colon, you would do something similar as follows: RightHandSideVariable = Mid(InputText, Instr(1, InputText, ":", vbtextcompare)+1) What this does is says to pull out of InputText starting at the location of the ":" plus one character and continue indefinately... If you wanted to stop at a certain character, you would add a third field to the Mid(field1, field, field3) which defines the ending character.. Do remember that all character positions are relative to the first character of the string.. That is what always gets me when using the "Mid" statement. If you have any further questions, let me know. Chris Cranford TKD Software, Inc. --- Mail-ennium v1.0.16a * Origin: tkdsoftware.com - Home to Mail-ennium Mail Tosser - (1:379/1200) =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-10-00 (19:18) Number: 264 From: FRANCOIS ROY Refer#: NONE To: CHARLES GAEFKE Recvd: NO Subj: Re: Reading a Text File Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 387a301b REPLY: 1:129/230 38d4e765 CG> It -is- the way to go if you are using VB. Which happens to be the subject of this conference, and the only language I can knowledgeably talk about. And, if you open your sequential files with a largish buffer size (using the Len parameter), performance is quite acceptable. Using String variables instead of Variants helps too. If you're really in a rush, though, PowerBasic Console Compiler will blow the doors off VB when it comes to reading files. Often, too, the way you code the thing has lots to do about what kind of performance you get. I still have routines that use VB file I/O to do some specialized processing on a proprietary-format database that will outperform the "re-designed" database now running on an 4-CPU, 2gig RAM, Unix Oracle machine. To give you just one more example: how long do you think it would take for a program (you pick the language) that needs to open a large Web server log file (approaching 300Mb) and display the last 5 records (lines) in it to run? --- Msged TE 05 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-10-00 (07:27) Number: 269 From: PETER DALTON Refer#: NONE To: JAY FULLER Recvd: NO Subj: Reading a Text File 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 28cad8ac REPLY: 1:3603/140 150713ef On (08 Jan 00) JAY FULLER wrote to ALL... Hi Jay, JF> Keyword5:AA JF> ...as you can see....there are variable lines...depending on how many JF> "keywords" the person who took the photo selected. On top of this, I JF> need to be able to read the fields ONLY on the right hand side of the JF> colon. I've started by trying to read everything out of the text file, this part is relatively simple using InString... Dim Test as String Dim Point as Byte Open File For Input as #1 Input #1, test Trim Test 'get rid of leading and trailing spaces Point = InStr(Test, ":") 'finds the position of ":" Test = Left(Test, Len(Test) - Point - 1) or something, you may need to play around with this as I've written it 'on the fly' without testing. The helpfile will give a better understanding of InString... Success Peter --- PPoint 1.88 * Origin: Peter Points at last! (2:25/108.9) =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-11-00 (17:47) Number: 268 From: CHRIS CRANFORD Refer#: NONE To: JAY FULLER Recvd: NO Subj: Reading a Text File 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:379/1200.0 387BB1D7 -> Number:1234567890 -> Path:/DC_290 -> Filename:P0000331.JPG -> something (i guess i could do that manually..) - is there a way to look -> for the colon and 'record' only what is on the right side of it? Jay, in order to pull the text from the left-hand side, use: LeftHandSideVariable = Mid(InputText, 1, Instr(1, InputText, ":", vbtextcompare)-1) What this means is to pull out of the string starting at character 1, and continue through the location of the ":" character minus 1 character location.. So this would pull out: "Number", "Path", and "Filename". If you want to pull out the right side of the colon, you would do something similar as follows: RightHandSideVariable = Mid(InputText, Instr(1, InputText, ":", vbtextcompare)+1) What this does is says to pull out of InputText starting at the location of the ":" plus one character and continue indefinately... If you wanted to stop at a certain character, you would add a third field to the Mid(field1, field, field3) which defines the ending character.. Do remember that all character positions are relative to the first character of the string.. That is what always gets me when using the "Mid" statement. If you have any further questions, let me know. Chris Cranford TKD Software, Inc. --- Mail-ennium v1.0.16a ? Origin: tkdsoftware.com - Home to Mail-ennium Mail Tosser - (1:379/1200) =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-10-00 (07:27) Number: 269 From: PETER DALTON Refer#: NONE To: JAY FULLER Recvd: NO Subj: Reading a Text File 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 28cad8ac REPLY: 1:3603/140 150713ef On (08 Jan 00) JAY FULLER wrote to ALL... Hi Jay, JF> Keyword5:AA JF> ...as you can see....there are variable lines...depending on how many JF> "keywords" the person who took the photo selected. On top of this, I JF> need to be able to read the fields ONLY on the right hand side of the JF> colon. I've started by trying to read everything out of the text file, this part is relatively simple using InString... Dim Test as String Dim Point as Byte Open File For Input as #1 Input #1, test Trim Test 'get rid of leading and trailing spaces Point = InStr(Test, ":") 'finds the position of ":" Test = Left(Test, Len(Test) - Point - 1) or something, you may need to play around with this as I've written it 'on the fly' without testing. The helpfile will give a better understanding of InString... Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) January 14, 2000, 1:55 am Drudgery continues. I'm glad I'm doing this now and not later. I started about 10:30 this evening really coding some of the import functionality from the camera's text file. I took some of the advice, which came in over fidonet, but instead of overwriting some of the initial string values (which the fidonet fellow suggested), I kept all string values intact. My code, once I had a working "parser" , looked like this: Dim LineContents As String Dim ColonPosition As String 'location of comma counting from left Dim Storewhat As String 'field name of what we are storing, ex. name or number Dim NewLine As String 'actual stored value, ex. fuller or 116814 Open CdlPatient.FileTitle For Input As #1 While Not EOF(1) 'while it's not the end of the file... Input #1, LineContents 'read a line of the file If Len(LineContents) <> 0 Then 'if the line is blank, skip it Trim LineContents 'gets rid of extra spaces ColonPosition = InStr(LineContents, ":") 'at which point is the comma? Storewhat = Left(LineContents, ColonPosition - 1) 'This should be the field we're storing, ex. name NewLine = Right(LineContents, Len(LineContents) - ColonPosition) 'contents of stored field, ex. fuller returnval = MsgBox(Storewhat, vbOKCancel) returnval = MsgBox(NewLine, vbOKCancel) If returnval = vbCancel Then Exit Sub End If Wend I include this here now incase I manage to improve or modify this code later. I continued work in trying to figure out how to setup the Access 2000 database in our prototype. I went ahead and setup some text boxes and areas in my prototype and tried to work on bringing in some fields, but the first attempt at writing a field to the database crashed my computer. Since upgrading to VB 6, "autosave" was never turned back on – so, ZAP, 30 minutes worth of research in reading back over ITE 370 notes were gone. We'll pick back up here tomorrow. =) I hope to have this module complete by the weekend. I'm very excited with the progress I made with it tonight. That progress, by the way, is when you read in 'patients.txt' , the file containing the values needed for the database, the parser I have completed can separate the text on the left side of the colon and it can also tell you what is on the right side of the colon. I hope to use the information on the left hand side of the colon (and ask Adam to change the field name on the left side of the colon) to match that piece of information up with an actual field in the database. For example, currently, the first field in the text file is Number, followed by a : and then the PatientID. I would rather the identifier in the text file actually read "PatientID:" – so I could verify the PatientID went into the database as the PatientID. This is where I'll pick up next time. January 14, 2000, 8:51 am When I got up this morning, I went ahead and wrote a progress report / reply in the fidonet visual_basic conference so they will know where I am. Here is a copy of that message: =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-14-00 (08:50) Number: 843 From: JAY FULLER Refer#: 269 To: ALL Recvd: NO Subj: Text File / Database Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- PD> JF> ...as you can see....there are variable lines...depending on how many PD> JF> "keywords" the person who took the photo selected. On top of this, I PD> JF> need to be able to read the fields ONLY on the right hand side of the PD> JF> colon. I've started by trying to read everything out of the text file, PD>this part is relatively simple using InString... PD>Dim Test as String PD>Dim Point as Byte PD>Open File For Input as #1 PD>Input #1, test PD>Trim Test 'get rid of leading and trailing spaces PD>Point = InStr(Test, ":") 'finds the position of ":" PD>Test = Left(Test, Len(Test) - Point - 1) PD>or something, you may need to play around with this as I've written it PD>'on the fly' without testing. The helpfile will give a better PD>understanding of InString... Well, I started using what you gave me and played with it and played with it until I got something that worked. :) Here's my result when i finally got done with this little section: Private Sub CmdProcess_Click() Call selectfile 'asks the user to select a file Dim LineContents As String Dim ColonPosition As String 'location of comma counting from left Dim Storewhat As String 'field name of what we are storing, ex. name Dim NewLine As String 'actual stored value, ex. fuller or 116814 Open CdlPatient.FileTitle For Input As #1 While Not EOF(1) 'while it's not the end of the file... Input #1, LineContents 'read a line of the file If Len(LineContents) <> 0 Then 'skip blank lines Trim LineContents 'gets rid of extra spaces ColonPosition = InStr(LineContents, ":") 'at which point is the comma? Storewhat = Left(LineContents, ColonPosition - 1) 'This should be the field we're storing, ex. name or number NewLine = Right(LineContents, Len(LineContents) - ColonPosition) 'contents of stored field, ex. fuller or 116814 returnval = MsgBox(Storewhat, vbOKCancel) returnval = MsgBox(NewLine, vbOKCancel) If returnval = vbCancel Then Exit Sub End If Wend ...you'd told me to use a byte data type...I'm not even sure what a byte data type is..and it threw me off for a little bit. This might not have been the easiest way to do this, or it might have some bugs in it. Please inform me if I've overlooked something as I'm not the best in the world at this stuff. :) My next step is to try to bring those fields into a database. In continuing working with this project, we are using a Access 2000 database which means we are having to use ADO to access the database instead of the regular DAO which they taught us here in school. (I also had most of the vb classes in v5). I had setup some lines in the above loop to open the recordset (setup by a design time data control) and .addnew a record and used a .recordset.fields("PatientID") to associate the incoming value (from the txt file) into the database. This was flawed (probably my logic, becuase I wrote it at 12:30 after doing the other for 2 hours...) - and it locked up the app. :) I also hadn't saved it......and, of course, although in v5 I had auto-save turned on, that setting didn't carry on to v6... :) - so..um...I'll let ya know how this works. :) In the meantime, if I'm completely on the wrong track with this...please..someone...set me straight asap before I drown. :) Thanks! Jay Fuller ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- ------------------------------------------------------------------------ * OLX 2.1 TD * Captain!!!!.....The ship is coming apart!!! January 18, 2000, 1:18 a.m. Upon checking my email on my typical Sunday night catch up session, I noticed Yvonne had run into a few problems using the ADO database objects instead of the DAO database objects in Visual Basic. She had requested in her progress report, which was emailed out on the 15th, that I asked the fidonet group if they knew much about the DAO objects. I do recall, at one point, a discussion was taking place in the conference when I was first evaluating the conference. I have posted the following update and request from Yvonne in the echo: =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-17-00 (01:13) Number: 843 From: JAY FULLER Refer#: NONE To: ALL Recvd: NO Subj: Project Update... Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- Well, folks, I have successfully got the code written to parse the text file coming in (i think I already said this...) - it's showing up in MSG boxes right now. =) However...the team, as a whole, is having some trouble with the ADO vs DAO components of visual basic. I've noticed in the past some confusion on these components in this conference before. Here's an email I've been asked to relay and pray for some help on :) ======================================================================= PROBLEMS The code I got is not updating the buttons correctly. The .AddNew and .Edit methods do not work right with the ADODC ** The .Edit does not work at all: it is not an available method and I have not found (as yet) a compatible method. I expect 2 new books in on Monday, though. ** The .AddNew method does not go to an empty record: when I tested it, over-wrote the existing record. (I think I did put a .MoveLast in there and it still didn't work, but can't remember for sure). JAY: If you could ask your BBS connection what the deal is on the .AddNew and .Edit, I would appreciate it. ======================================================================= If you guys need more information on this, just ask. :) I appreciate it. This is also the next step in my module, as after I've parsed the file (which is technically done), i need to read what is on the left side of the text file (to confirm which field i'm reading), and write a value (which is on the right side) to a table in the database. more on this later this week, hopefully. ;) School has a tendency to stress you out and eat all your time up =) thanks! Sincerely, Jay Fuller ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- ------------------------------------------------------------------------ ? OLX 2.1 TD * Riker to Enterprise: Beam down Troi and a six pack!! January 18, 2000, 6:30 p.m. – 9:45 p.m. Tonight I worked on producing the meeting minutes from December 2, 1999. I was shocked at how much we had discussed at that actual meeting. It took me several iterations of the tape to get all the material on paper but I eventually made it. January 21, 2000, 12:02 a.m. The team received an email earlier in the week from Joshua Carter – one of our fellow team members. He was not happy receiving so many updates from the team at one time and notified us of this. This is Yvonne's message with my reply attached and Josh's original message filing my formal protest. Date: Friday, 21-Jan-00 12:01 AM From: Jay Fuller \ Internet: (jfuller@airnet.net) To: Yvonne Totty [USOUTHAL] [CIS] \ Internet: (webyvonne@bigfoot.com) Subject: RE: Problem > Date: Wednesday, 19-Jan-00 07:51 AM > From: Yvonne Totty [USOUTHAL] [CIS] \ Internet: (webyvonne@bigfoot.com) > Well, Josh, since the message board is not getting backed up, I am using this > as a means to keep information for my personal journal. > > If you had a problem with this means of communication, you should have said so > when I asked everyone to email a progress report when they work on the project. > > If you want to delete this as it comes in, fine; it should say "Progress > Report" in the subject line. However, I have a distribution list set up so all > I have to write is "SrProj" in the subject line and it addresses all of you at > one time. > > But, hey, if you want to be cut off my list, so be it. well, i don't know if it's my job to complain or not but hey...you do it on occasion so...yah...this _REALLY_ pisses me off. I mean, we (you and me and usually adam) handle our email in pretty good time and josh usually doesn't have much to say. sometimes he hasn't even read what we're sending out and isn't briefed on whats going on. sure, we could hold everything until the meetings, but that would tripple our meeting times. some weeks there's little flowing...some weeks there's lots flowing. we can't force him to read...so what can we do? ------- FORWARD, End of original message ------- > ok now.. as much as i enjoy all your emails abuot the senior project ..i have > to cut ya off.. those of you emailign me everyday are completely bombarding > me with them..i dont even read them now i just delete..please keep it on the > site.. so i can absorb it all when i get on the site rather than havign it > mixed with all my other emails..now i dont mind if ya email me for other > things and i dont mind if you even email about specificsyou need form > me..jsut not what you did. or what your problem was or how you > fixed it..or if you fixed it. > > thanks i appreciate it.. > > josh January 28, 2000, 12:24 a.m. Well, I have been off the project for quite a while now – mostly because I've had quite a busy week. Over last weekend I did a lot of reading in the newsgroups and on the fidonet network. There were a few replies to the original messages I had posted a few weeks back and a few suggestions as to how to handle solving ado/dao problems: =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-19-00 (07:22) Number: 312 From: PETER DALTON Refer#: NONE To: JAY FULLER Recvd: NO Subj: Project Update... Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 95434428 REPLY: 1:3603/140 d5065e6e On (17 Jan 00) JAY FULLER wrote to ALL... Hi Jay, JF> The .AddNew and .Edit methods do not work right with the ADODC I'm in the process of writing my first VB database, and up to a couple of days ago I was wishing that I'd stuck with my QB method of writing the data into Random Access Files as I know that works! Take a look at Microsofts web-site, Developers area, there are two Service Packs for VB5 and VB6. If you're using VB6 then the Addnew won't work without the Service Pack. JF> ** The .AddNew method does not go to an empty record: when I tested JF> it, JF> over-wrote the existing record. (I think I did put a .MoveLast in there and I'm using VB5 with an Access 97 database. The answer that I came up with was to have a blank record at number one which gets 'loaded' up on-screen. The code allocates a new 'record number' and when it's 'saved' by the user it goes into the correct place in the database rather than over-write record one. It took many hours of tweaking and running to get the finished result! I found that I couldn't use Edit for a new record, but it was needed for an existing record, the code's a bit of a mess, but it works now! Sucecss Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) Also, some suggestions as to how to implement the database part of my program were suggested: =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-19-00 (19:12) Number: 313 From: PETER DALTON Refer#: NONE To: JAY FULLER Recvd: NO Subj: Text File / Database Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 2:25/108.9 ffb7216d REPLY: 1:3603/140 d60e8ea0 On (14 Jan 00) JAY FULLER wrote to ALL... Hi Jay PD>Dim Point as Byte JF> Dim ColonPosition As String 'location of comma counting from left InStr returns a number, the number of characters from the start to where the (first) 'selected' character is. That's why I dimmed the variable as Byte. JF> ...you'd told me to use a byte data type...I'm not even sure what a byte JF> data type is..and it threw me off for a little bit. This might not have Byte holds a number between one and 255, like Integer but smaller and only uses one byte of storage. JF> Please inform me if I've overlooked something as I'm not the best in the JF> world at this stuff. :) I tend not to worry as long as it works... JF> database which means we are having to use ADO to access the database JF> instead of the regular DAO which they taught us here in school. (I also JF> had most of the vb classes in v5). I had setup some lines in the above I had a one year evening classes course in VB to pick up the basics, and in the last few weeks I've downloaded a couple of tutorials from Kidsware on the Net 'VB' and 'VB and Databases'. Both of these give the first half- dozen lessons free with a small charge for the last half-dozen lessons. I've almost finished the VB and Databases tutorial, it's 600 plus pages, and it covers DAO and ADO (though for now I've just looked at the DAO as that's all I have with my copy of VB5. JF> loop to open the recordset (setup by a design time data control) and JF> .addnew a record and used a .recordset.fields("PatientID") to associate JF> the incoming value (from the txt file) into the database. I found that I needed to do an Addnew at the start and then again immediately before the Update. I have no concerns about wheather this is right or wrong, a bug in VB or a bug in my code, it works! JF> auto-save turned on, that setting didn't carry on to v6... :) - JF> so..um...I'll let ya know how this works. :) ah, always save...etc, etc... JF> In the meantime, if I'm completely on the wrong track with JF> this...please..someone...set me straight asap before I drown. :) I'm sure a few more experianced programmers will jump in and let you know, which will also help me... Success Peter --- PPoint 1.88 ? Origin: Peter Points at last! (2:25/108.9) Because of the suggestions made, I have changed the data type in my module from "string" to "byte" as suggested. February 2, 2000, 2:16 a.m. I am getting quite frustrated because I have been unable to spend more time on coding my particular module for our project. My module is only one of the basic goals and I have more modules to code after this one. However, our senior project team meeting did go quite well today. We got into an entire interface discussion and wound up getting quite a bit of our design on paper. I got the impression many of our team members were unconsciously wondering where they were going to link their modules in (instead of developing modularly), and thus, had not worked too hard on their modules. I had also posted this message earlier in the week: From : JAY FULLER Number : 2944 of 2975 To : JOSH EINSTEIN Date : 1/28/00 3:08 PM Subject : Re: 32-bit CRC Reference : NONE Read : No (0 replies) Private : No Conf : 868 - FIDO-VISUAL_BASIC International Echo JE>-> And very inefficient. Based on your comment, I'd assume you've never u JE>-> file manipulation very extensively outside of VB. JE>Right on that one... however, I have naturally used programs written in othe JE>languages and file manipulation is not a real problem in VB. As I said befor JE>too... without learning a new language you CAN use Windows API for file JE>operations and the file routines there were I believe ASM if not ASM/C++. This is coming up for me relatively quickly...I need to make directories and copy files on a windows system....from within vb.... (where's my batch files? :-) ) hehe :) * OLX 2.1 TD * t:\jules. --- Platinum Xpress/Win/Wildcat5! v3.0pr3 * Origin: QWK MAIL & Y2K READY! WWW.DOCSPLACE.ORG (1:3603/140) Fortunately, I have already received some replies as to how to handle this in visual basic before I even had time to do more coding. I did test these results tonight and they do work! =========================================================================== BBS: Doc's Place Bbs Online. Date: 01-30-00 (09:12) Number: 406 From: CHARLES GAEFKE Refer#: NONE To: JAY FULLER Recvd: NO Subj: Re: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:129/230 3838085c REPLY: 1:3603/140 943413b3 PID: CDRMAIL v1.22FO TID: GE 1.11+ JF> This is coming up for me relatively quickly...I need to make directories JF> and copy files on a windows system....from within vb.... This works okay in VB. It uses the same commands (I believe) as DOS: mkdir copy Though I suspect the copy file command is different. I've used it once, and I remember it not being as obvious as mkdir. C. Gaefke cdgaefke@earthlink.net ... Have your dreams come true? --- Renegade 98-310 Dos/CDRMail v1.23.b1.1 ? Origin: LOTL/2 * www.icubed.com/~cdgaefke (1:129/230) =========================================================================== BBS: Doc's Place Bbs Online. Date: 02-01-00 (13:45) Number: 409 From: VICTOR LOBERGER Refer#: NONE To: JAY FULLER Recvd: NO Subj: Re: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:154/731.0 389737ee REPLY: 1:3603/140 943413b3 Hi Jay, JF> This is coming up for me relatively quickly...I need to make directories JF> and copy files on a windows system....from within vb.... Check the HELP in VB. It really does cover a lot of things, of course finding what you're looking for is another thing. 8-) Here's the help for copying a file: Syntax FileCopy source, destination The FileCopy statement syntax has these named arguments: Part Description source Required. String expression that specifies the name of the file to be copied. The source may include directory or folder, and drive. destination Required. String expression that specifies the target file name. The destination may include directory or folder, and drive. Remarks If you try to use the FileCopy statement on a currently open file, an error occurs. As Charlies told you, the MKDIR is the command. Good luck! Victor --- Maximus 3.01 ? Origin: Aarrgghh! BBS-West Bend, WI USA (262) 334-7041 (1:154/731) …I replied… =========================================================================== BBS: Doc's Place Bbs Online. Date: 02-02-00 (00:34) Number: 843 From: JAY FULLER Refer#: 409 To: VICTOR LOBERGER Recvd: NO Subj: Re: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- VL> JF> This is coming up for me relatively quickly...I need to make directorie VL> JF> and copy files on a windows system....from within vb.... VL>Check the HELP in VB. It really does cover a lot of things, of course VL>finding what you're looking for is another thing. 8-) oh...my....goodness....yes, i learned this already. =) took me a while just to learn to close everything to just the vb help =) VL>Here's the help for copying a file: VL>Syntax VL>FileCopy source, destination VL>The FileCopy statement syntax has these named arguments: VL>Part Description VL>source Required. String expression that specifies the name of the VL> file to be copied. The source may include directory or folder, VL> and drive. VL>destination Required. String expression that specifies the target file VL> name. The destination may include directory or folder, and VL> drive. VL>Remarks VL>If you try to use the FileCopy statement on a currently open file, an VL>error occurs. VL>As Charlies told you, the MKDIR is the command. VL>Good luck! VL>Victor Terrific! Thanks, -jf ? OLX 2.1 TD * When Klingons pluck their eyebrows,they do it with HONOR! February 3, 2000, 1:06 a.m. Well, I've done it again. I had a basically free night and I spent it updating the team's minutes and doing some personal cleanup on my own. I'm still not up to date – I've still got this week's to document, but I did record who was having problems with what so I could ask questions in the fidonet conference such as this one: =========================================================================== BBS: Doc's Place Bbs Online. Date: 02-02-00 (22:29) Number: 843 From: JAY FULLER Refer#: NONE To: ALL Recvd: NO Subj: Importing pictures Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- Another function of the program my team is working on here at the University of South Alabama is to be able to display a group of pictures on a visual basic form. One of my teammates is apparently looking into 'thumbnail objects' , and they are not working for him. He's considering using the regular picture boxes to load the associated images (which will come from a database...as filepaths only) onto the form. My question is.....has anyone played with this any yet, and do you have any suggestions for him? I appreciate it! Later, Jay Fuller ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- ------------------------------------------------------------------------ ? OLX 2.1 TD * Data!!..I Thought you were dead!!..No Sir!I Rebooted!!!! February 4, 2000, 1:24 a.m. I received more information on how to copy files and make directories – This message eventually, although it was lost for a while on my temp drive, helped me solve the problem with filecopy: =========================================================================== BBS: Doc's Place Bbs Online. Date: 02-04-00 (01:24) Number: 465 From: KURT KUZBA Refer#: 406 To: CHARLES GAEFKE Recvd: NO Subj: Re: 32-bit CRC Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- CG> JF> This is coming up for me relatively quickly... CG> JF> I need to make directories and copy files on a CG> JF> windows system.... from within vb.... CG> This works okay in VB. It uses the same commands CG> (I believe) as DOS: CG> mkdir CG> copy CG> Though I suspect the copy file command is different. CG> I've used it once and I remember it not being as CG> obvious as mkdir. I just went and checked on it. In VB5, at least, it is a simple command and two strings: Filecopy FileA$, FileB$ I did this: MkDir "c:\temp\test" FileCopy "c:\temp\serwave.inf", "c:\temp\test\serwave.inf" and it worked perfectly. Using a common dialog for file copying, it might work like this: dstPath = dstDrive & "Program Files\MyApp" MkDir dstPath FileCopy dlgCopy.FileName, dstPath & "\" & dlgCopy.Filetitle It seems rather simple and straightforward, but it seems you need to supply a whole path and filename for the destination. I tried just supplying a path and it did not like it. In this way, it differs from the command line interface. --- > ] Opossums on the Information Rustic Road................ February 5, 2000, 1:06 a.m. I had to deal with a member of the team tonight who didn't seem to be pulling his weight. Quite unpleasant. Also, however, I managed to receive a response in regard to the issue of which kind of control would be more efficient and reliable in displaying jpg images: =========================================================================== BBS: Doc's Place Bbs Online. Date: 02-03-00 (18:36) Number: 429 From: FRANCOIS ROY Refer#: NONE To: JAY FULLER Recvd: NO Subj: Importing pictures Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- MSGID: 1:163/506 3899ca48 REPLY: 1:3603/140 dee379aa JF> He's considering using the regular picture boxes to load the associated JF> images Well, image boxes are "lighter" (on Windows resources) than picture boxes, if you can live with their limitations. Place one image box on the form, give it an index value of 0 (therefore creating a control array) and load (and position) additional image boxes as required, by loading additional elements in your control array. --- Msged TE 05 ? Origin: Ready & Determined (819) 772-9277 (1:163/506) February 6, 2000, 1:57 a.m. Wow! A successful day not only in getting things done, but also in moving forward with my import module. I am now breaking each record apart based on blank lines between each record and I am pulling in the data from the text file and putting it on the text boxes. I was ready to bind the text boxes to the data control and just add the incoming information with an .addnew, but I realized shortly into that process that some of the information is going into the patient table and some of it is going into the image table. I could not remember right off if this is possible with the current setup of the ado control (which uses a recordsource of simply 'patient'). Instead of fiddleing more with that tonight, I went ahead and wrapped up that module minus the database part and posted it online. I then wrote a message in fidonet, doing a little research on how to add these fields using SQL, and am awaiting more information on this topic. That message: =========================================================================== BBS: Doc's Place Bbs Online. Date: 02-06-00 (01:30) Number: 843 From: JAY FULLER Refer#: NONE To: ALL Recvd: NO Subj: database problem Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- Back on the topic of the project i'm working on for senior project: Many of you helped me 2-3 weeks ago parse a text file into several fields which can then be imported into a database. That is where I am at now - I am currently attempting to bring the data parsed out into a database that looks like this: (this is the way I was taught to list databases, if i'm wrong, or have any questions, please ask) Patient (_PatientID_, FirstName, MiddleName, LastName, Gender, Memo) Keyword (_KeywordID_, Keyword) Image (_ImageID_, _PatientID_, DateTaken, Picture, Keyword1, Keyword2, Keyword3, Keyword4, Keyword5) now...a sample of the file I am importing, once again, looks like this: Number:98765 Path:DC290_01/ Filename:P0000676.JPG Date:1/23/00 Time:8:40 PM First:Furby Last:Lulu Gender:F Keyword1:A Keyword2:D ok - now I have a data control (ADO) setup using microsoft jet v4 engine and it's setup for the recordsource to be patient. that's fine - for now, except when i am importing information, FILENAME and KEYWORDS do not belong to the patient table. Therefore, my standard "addnew" will not work (unless I am overlooking something ) because my recordset (as part of adocontrol1) points ONLY to the patient table. I'm assuming I'd need to use SQL to get this into the database since I had a lab in getting SQL queries executed within VB. If I were writing a SQL query to add this information, from the back of memory, I'd write something like: insert into patient values ('98765', "Furby" , "" , "Lulu" , "F" , "") insert into keyword values ("A", "D" , "" , "" , "") insert into image values ('?98765?', '98765', "1/23/00", "P0000676.JPG" , "A" , "D") wow....some of this appears flawed. Anyway, I'll get with the team on that. My question is....am i best off to use SQL here for this particular function, IS this the proper syntax to write to a recordset using all three tables in the database, and what is the proper sequence for using sql to write to the database? For example, for DAO object in VB5, it was: .recordset.addnew populate the text boxes with your data .recordset.update I'm assuming I'll have to change the type of access I'm using in ADO (or create one manually somehow....it's got to be compatable with access 2000) , and i'll need instructions on which options to set there as well. If anyone can guide me towards where in the help file to locate this, I'd appreciate that as well. Thank you very much! Sincerely, Jay Fuller jfuller@airnet.net ------------------------------------------------------------------------ Internet: jfuller@airnet.net Fidonet Netmail: 1:3607/22 -->> Internet HOMEPAGE: http://www.airnet.net/jfuller <<-- ------------------------------------------------------------------------ * OLX 2.1 TD * "Scotty, I've fallen and I can't beam up!" February 9, 2000, 1:57 a.m. I typed one complete set of minutes earlier tonight and started on the other set. I also managed to solve some dilemmas during the process. Rather these solutions will actually be utilized, however, I have no way of knowing. February 15, 2000, 12:24 a.m. Well, I have been trying to figure out how to write code (sql code) to interface with the ADO model (Active Data Objects). So far, I have not had much code, but it is very difficult to code and test when it takes 30 minutes to perfect the actual SQL code and then write something to the database. I believe I am going to try to get something out of the fidonet conference before continuing this attempt. I have spent about five hours on this tonight. February 17, 2000, 2:49 a.m. Finally! Another night of, well, some sort of progress. I worked primarily on using a tutorial I downloaded night before last to setup my module to work with SQL queries. I then put in a sample query and had it return to a dbgrid like Yvonne had said she was doing at the meeting yesterday. After following those suggestions and linking in a dbgrid like I had done in ITE 370, I was able to get results of SQL queries! – something I believe other team members had difficulty getting. Eventually, I realized I was only getting two results containing images when I had asked for them all (at this point I had entered 5 images) – but I soon realized it was because the patient id numbers did not match ones in the patients table. I eventually did fix this, and was having no trouble. I then spent about an hour playing with MS access itself – I used SQL syntax to actually add some information to the tables (which is what my module will have to do) and my next step is to attempt these updates from VB itself. I'm assuming if I follow this tutorial and substitute a insert into command instead of a query string and then execute it – maybe, just maybe, it'll write to the table like access was doing! February 18, 2000, 12:17 a.m. So far tonight is making pretty good progress. I goofed up last night and did not save the actual SQL syntax I was using to write the records to the table inside access itself so I've had to reconstruct those queries tonight and save them in a temporary text file for safe keeping. Then, as my next planned step, I pasted them into the SQL window over in visual basic to see if those queries would add new rows there. Some interesting things happened…….. Firstly, I got an error from visual basic: The operation requested by the application is not allowed if the object is closed. As I went ahead and ran the application, I discovered it was not a fatal exception. I performed the SQL query and noticed that visual basic did indeed add the record to the patient table! I did some research on the error I received – here is some information from one of the webpages I was able to find using fantastic internet search engines: ADO Error Codes In addition to the provider errors that are described in the Error object and Errors collection, ADO itself can return errors to the exception-handling mechanism of your run-time environment. Use your programming language's error trapping mechanism, such as the On Error statement in Microsoft® Visual Basic®, to trap and handle the following errors. Both decimal and hexadecimal error code values are shown. AdErrObjectClosed - 3704 - 0x800A0E78 The operation requested by the application is not allowed if the object is closed. AdErrObjectClosed and Solution and Visual Basic returned no matches. So, since the documentation I found suggested that this was an error generated that should be a trappable error, I am going to try to implement that code if it becomes a problem. I might spend another hour or so tonight trying to actually code the sql string(s) required. Sample error handling code: Description, NativeError, Number, Source, and SQLState Properties Example (VB) This example triggers an error, traps it, and displays the Description, HelpContext, HelpFile, NativeError, Number, Source, and SQLState properties of the resulting Error object. Public Sub DescriptionX() Dim cnn1 As ADODB.Connection Dim errLoop As ADODB.Error Dim strError As String On Error GoTo ErrorHandler ' Intentionally trigger an error. Set cnn1 = New ADODB.Connection cnn1.Open "nothing" Exit Sub ErrorHandler: ' Enumerate Errors collection and display ' properties of each Error object. For Each errLoop In cnn1.Errors strError = "Error #" & errLoop.Number & vbCr & _ " " & errLoop.Description & vbCr & _ " (Source: " & errLoop.Source & ")" & vbCr & _ " (SQL State: " & errLoop.SQLState & ")" & vbCr & _ " (NativeError: " & errLoop.NativeError & ")" & vbCr If errLoop.HelpFile = "" Then strError = strError & _ " No Help file available" & _ vbCr & vbCr Else strError = strError & _ " (HelpFile: " & errLoop.HelpFile & ")" & vbCr & _ " (HelpContext: " & errLoop.HelpContext & ")" & _ vbCr & vbCr End If Debug.Print strError Next Resume Next End Sub February 18, 2000, 2:39 a.m. I stuck with it – and because of that, I have some results. I'm now building the sql string on the fly based on the information coming in from Adam's camera script. Unfortunately, Adam's script is presenting the information in a bad order – so I'm going to talk to Adam and try to get him to rework his script so I can import the fields in the same order they appear in the database. I'm having some programming difficulties, but so far, I've got two of the import fields coded. It's just very time-consuming. I'd keep going tonight if it weren't already 2:41. ;-) February 19, 2000, 3:31 p.m. I started about 6 pm last night working towards completion of this module. I finished it at about 9:30 last night – at least the patients part of it. I've reworked Adam's text file (and haven't heard back from Adam about rather this was an ok thing to do or not) so it will work better with the SQL statements I'm building. I have now successfully built a SQL statement and used it to successfully add a record to the database. I also decided to substitute a memo field to label which patients were added using Portable Patients. I guess I just remembered a whole new problem – if a patient already exists in the database, it will not need to add the patient. As a matter of fact, the doctor only wanted to use a chart number, so I may only be adding to the images table. My only problem so far is the above error message I continue to get. I suppose it's about time to post a message about that in the fidonet conference. February 21, 2000, 10:31 p.m. I got a reply tonight concerning how I should go about doing my SQL coding. However, I have made a good bit of progress towards making code that works. The SQL queries I have created from Access have allowed me to successfully code parts of the import module. Official report from the first working version (.51): Program now supports Adam's modifications and works with extensive camera data (sort of). More modifications coming soon to improve upon this. Middle Name Glitch exists here – when Adam makes a decision on the middle name field I can account for this glitch. February 22, 2000, 9:12 p.m. I spent an hour and a half this evening producing the meeting minutes from February 15, 2000 and emailing them out to the group. February 23, 2000, 12:25 a.m. I kept working after typing the minutes from the 15th and went ahead and typed them for the 22nd. ;-) February 23, 2000, 3:25 a.m. After typing the minutes, I got into a discussion online with Joshua Carter about some problems he was having with his code. I pulled a copy of his code from the visto website and attempted to help him isolate what was happening. In determining the path using the recordset object error was because his data control had no current record to it. So, the way I tested this theory was to draw a dbgrid onto his prototype form (which was in his Joshua's Prototype directory on our webserver) and bind it to a recordset, which was guaranteed to have at least one record (due to a SQL query I had access build). Since there was now a current record, it could access the field of one of the records contained within the recordset. However, explaining to Joshua what I had done (especially since he had gone to bed) proved to be quite difficult. I started to write out instructions for testing my hypothesis, but I later decided it would be easier for me just to go ahead and test it for him. I discovered the variable worked, but I could not get the picture up in the image box. Joshua later solved this problem somehow. From a message I later wrote explaining what I did: When you were coding using the adopatients.recordset.fields code, there was no current record (because when Yvonne's data control started up, it was on record #1) - Josh's didn't bind ANY record...therefore, there was no data to call up. When we put in the datagrid, it bound a current record, thus, giving the information instead of an error. It was a temporary fix which can go away once Josh codes a current record and his navigation functionality -rather it be via SQL or what not... February 25, 2000, 12:34 a.m. We decided at the meeting on the 22nd to go ahead and put together a prototype (alpha, of course) to send to Dr. Brown so he could see what the interface was supposed to look like in action and he could get a rough idea of how the program is supposed to work. In creating this prototype, I downloaded the most recent prototype from the website to integrate my code into it. Unfortunately, there were several errors within other parts of the code – and I thought those problems were from other members of the team not testing their code before adding it into the prototype. Some errors I got were: Unrecognized DB format, keyword problems, object variable not set, and "automation errors". I pointed these problems out to the team and attempted to set a date for getting a copy out to the good doctor. February 28, 2000, 12:46 a.m. I had reported problems in getting my copy of the prototype to work. Upon further investigation, I replaced the database (as some fields and information in it had been changed) and updated some of the supporting files. After some tweaking and playing, I was able to get a working prototype (one of the things I had to do was actually compile the modules into an EXE and run that actual EXE). I'm going to try to spend some time tomorrow away from Web Services (work) and see if i can't get my import module finished and installed into the main prototype by Tuesday's meeting. I suggest we simply email mark and see if he'd like to come by at some point during the week and play with the prototype in our lab. I'd suggest that instead of packaging it up and sending it out, but I'll obviously go either way. :) February 29, 2000, 7:46 p.m. After today's meeting, we've decided to send a compressed prototype to the client. I'm going to try to finish my import module ASAP (although the interface will most definitely need some help later) - and then once Steve adds his search module, he should package it up and ship it off to Brown – just in time for Spring Break. I have notified Dr. Brown it is coming: Date: Wednesday, 01-Mar-00 01:01 AM From: Jay Fuller \ Internet: (jfuller@airnet.net) To: Dr. Mark Brown [Client] \ Internet: (mark@eyeplastics.com) Subject: import module and beta test. Dr. Brown, Jay Fuller here again, I am currently working on the import module which will allow you to connect to the camera and import the pictures into our database. We are pleased to annouce we have an alpha working product (after many debugging hours this last weekend) and we would like to send it to you once it is fully intregrated in a few days for you to work with and see if you have any questions. We regret to add that major changes are not really an option at this point in the semester, but we will still take suggestions to pass along to the senior project class structure. Perhaps another team can make further enhancements in the semesters to come. Our next phase is to begin the user documentation phase and to begin alpha and beta testing which will last around a month. This is where you will have a semi working prototype to use and evaluate. The team has decided to let you use it for a period of time on your own before documenting what questions you have for us in a group session. Finally, to my import module, the main question I had for you is this. We will tell you in the user documentation and on the screen to be sure to input patients into the system before trying to import their pictures via the import module. In making a picture on the camera, however, you do have an option to enter patient information if they are a new patient and you do not have time to input them into the system before importing the pictures. This option comes from the camera's interface itself. As pointed out, this is not the recommended way to input patients, but we are trying to support both sides of the issue. Would you prefer a dialogue pop up automatically upon importing pictures asking for a name if you forgot to enter a name during the import process? In order to fully understand my question, picture this example: You are seeing a new patient. You are ready to take pictures and you have assigned them a chart number knowing they are not in the system yet. When asked on the camera "Enter name data?" you enter yes, knowing it will allow you to enter a first, middle, and last name. Somehow you get distracted and forget to enter the last name which is a required field for the import process. The pictures are made and there is a flaw in the data -- no last name. The import module typically would crash here. So, in the spirit of trying to recover from a possible crash, would you mind being prompted for the name automatically by the import module? Your other option is to simply abort the process whereas you would have to edit the text file generated by the camera and run the import module again. [records are added one at a time, so it would attempt to write duplicate patient records and you would have to bypass those warning messages]. I know this is in great detail - I just felt an import module would need to be more like a wizard - you would not want to interact with the process at all while it is running. If you were prompted for a name, you would have to interact. Then again, the chances of this happening seem slim. Please let me know your opinion as soon as possible. We will also contact you hopefully by the end of the week with an installable alpha version of the software. Sincerely, Jay Fuller The doctor responded that he would prefer to be prompted upon import if data is missing. March 1, 2000, 4:32 a.m. In doing additional testing of my import module, I noticed one single line of the test file was crashing my code. I discovered on this line that Keyword5 was listed right after Keyword1. I reported this glitch to Adam: Date: Wednesday, 01-Mar-00 04:32 AM From: Jay Fuller \ Internet: (jfuller@airnet.net) To: Adam Helewski [CIS] [USOUTHAL] \ Internet: (usacompsci@bigfoot.com) Subject: another camera glitch Please dont' allow the doctor to input a keyword as "#1" and "#5" like some samples you gave me did ;-) for example: Number:2221333 NameInfo:Y First:Phone Middle:Lame Last:Booth Gender:F Date:2/21/00 Time:1:32 AM Filename:P0000953.JPG Keyword1:10 Keyword5:4 it crashed my sql statement. ;) for you others.....i'm checking to make sure there is a patient record and if there isn't, i'm adding it. i'm checking to see how many images exist for a patient and i'm adding #'s there.....some complex code here....but it mostly works with the testing i've done on it except for the small glitches related to adam's text file. finally i'm going to spend a little more time trying to code the file directory code and copy file code. that shouldn't be hard, but it's almost 5 am. :) -jf March 1, 2000, 5:10 a.m. I discovered in the process of writing to the database in the actual prototype (we're no longer working in my "clean room" of an import module anymore – it's associated with the full prototype now), upon selecting the location of the data file on the camera (whatever drive letter that is on), app.path appears to change to that location. The result? All of a sudden, the program thinks the database is located on the same drive as the camera. I reported this to the team via email: Date: Wednesday, 01-Mar-00 05:10 AM From: Jay Fuller \ Internet: (jfuller@airnet.net) To: Adam Helewski [CIS] [USOUTHAL] \ Internet: (usacompsci@bigfoot.com) To: Jay Fuller \ Internet: (jfuller@airnet.net) To: Joshua Carter [CIS] [USOUTHAL] \ America Online: (ALTRNATEME) To: Steven Grimes \ Internet: (sgrimes@acm.org) To: Yvonne Totty [USOUTHAL] [CIS] \ Internet: (webyvonne@bigfoot.com) Subject: app path? folks , can i use app.path or something to figure out what drive letter the camera will be on, or at least where the database will be stored? I'm discovering when I select the path for the patients.txt file that it all of a sudden it thinks the db is on the p drive. ;-( anyway.......i've added my import module (writes patients and images) to the masterfile. all that is left is the copy thing and i could have done it, but damnit at 5 am.....i'm tired. :) anyway....i'll update the version history and stuff when i wake up :) -fj March 2, 2000, 10:45 a.m. I am still having difficulty getting the program to run successfully. Here is a copy of the email I sent out: hey gang, about 8 out of 10 times i run the current prototype (including my changes, but not limited to my changes) - i get some errors. Not compile time- errors, but runtime errors. I've gone through a lot of the prototype and tried to figure out what is causing them but I'm not convinced yet it's not just my computer. Would someone please download it and let me know what you think about it? I'm also completely done "coding" the file copy commands and create directory commands for the images - unfortunately, the filecopy refuses to copy the file. I'm wondering if it's because I'm using MSDOS'S "SUBST" command to create the virtual drive. Nevertheless.....issues issues. Someone please download that prototype and see what happens and if possible - what's causing those glitches. thanks!, jay fuller March 3, 2000, 12:05 a.m. I have solved some of the "runtime" glitches by simply compiling the entire program and running the exe standalone. A majority of these problems, I believe, have been caused by my module changing the active 'app.path' of the program – thus changing the database location in memory. Making directories and copying files proved to be more difficult than I thought. I had to tap into the windows API to actually copy the files because filecopy refused to work - even with hard coding the information into the command. The only remaining error is the "The operation requested by the application is not allowed if the object is closed" error that I am still attempting to trap. There were some minor SQL problems in a few of the patients import routines as well and a few duplicate entries being reported. I believe this is related to the faulty patients.txt file but will trace them eventually to be sure it is not a flaw in my coding. At this point, here are the instructions for running this module from scratch: Step 1: Download masterFile.zip from visto and uncompress it into C:\Program Files\Portpat Step 2: Download images.zip from visto and uncompress it into C:\Program Files\Portpat\images. Unzip folder names with this one. Step 3: Download cameradrive.zip from visto and uncompress it into a temp directory on your card drive, perhaps C:\PICS Step 4: Start an MS-DOS window. Type this command at your C:\> prompt: SUBST P: C:\PICS This command can change depending on what you did in steps 3 and 4 - the format is: SUBST [drive letter to be created] [folder you wish to make on that drive] This command simply assigns the contents of a directory / folder on your hard drive to a drive letter. It does not even duplicate the files. This is essentially exactly how a camera would connect - as a drive letter, making for the perfect test. Step 5: Start portable-patients.exe from the C:\Program Files\PortPat directory. [Do not run with full compile from within visual basic 6.0, as this has caused some unidentifed problems with directory locations, data controls, and connection strings. You can try this, but be warned, there will likely be errors. These errors have not been duplicated when running from the stand-alone .exe file]. Step 6: Browse the records which currently exist using the add / update feature. You should see images associated with those records and 24 total records. Click Main Menu from here. Step 7: Select Import Images from this point. After reading and acknowledging your directions there, select import data. You will be asked for the location of patients.txt - the data file which contains your patient information. Select this from the camera drive you created in step 4. You will have to acknowledge each warning message for now until that glitch is resolved. Step 8: Once all patients are imported, select add/update to browse the new patients. March 4, 2000, 10:46 a.m. Well, I am not sure if this is really worth mentioning, but it was kind of a funny, tricky problem. I am using a temporary variable in my program to be able to store values that are needed to add or delete objects in various places. Specifically, I had a problem with the directory names I was trying to create using mkdir – instead of making a directory like 1210987890 like it was supposed to, it was making the directories in scientific notation! The solution to this, as I figured, was either the type of SQL command I was using to add to the database (using single quotes – ' instead of quotation marks – " to add might signify an integer rather than a string). Instead, I had declared a variable as an integer instead of a string – thus causing the problem. This took me about 10 minutes to solve. ;-) March 4, 2000, 4:56 p.m. I uploaded the "cameradrive.zip" archive containing a huge amount of Adam's test data (16 megabytes of images and patients.txt) to my internet website for the team members to access and test their data if necessary. It would appear this new prototype alpha, which is in working condition, is making its way around the team. Quite a feeling! I remember a few nights ago calling Adam over to my room so I could demonstrate the working alpha (import process than going back into the scan patients mode and seeing the imported patients). It was quite a sight! ;-) March 6, 2000, 10:52 p.m. Hey! This is Spring Break! Why am I here? Actually, I'm not. I am writing this in the following week, but hey. ;-) I am in Cullman on my mother's cyrix computer – downloading the installable alpha version Yvonne created for us. I noticed with the pictures and display functions it runs extremely slow on her cyrix processor. Note to self – don't get a cyrix. However, I have proven the install file will work fine with some tweaks to the install parameters. Unfortunately, I do not recall right off what they are. Hopefully by the final version, they will be null points. March 9, 2000, 4:15 p.m. Hey! This is Spring Break! Whew! I'm still here! Actually, I was simply trying to go to Florida but it was pointed out that the "filecopy" function was once again not copying files. Upon further investigation, it was determined that the source location, which was hard-coded into the import module – based on whatever drive letter you select as the camera from the common dialogue control, seemed to be changing. I had coded the module for the pictures being in the root directory, as Adam's sample file had clued me to. According to Yvonne who had the camera temporarily – the pictures should have been in Dc_290 [example: P:\Dc_290]. I changed the path internal to the import module and uploaded it before leaving town. March 11, 2000, 6:15 p.m. Hey! This is Spring Break! Whew! I'm still here! Again! Hehe. This time Yvonne and I discovered the camera was writing to the folder Dc290_01. Later in the evening, we discovered it writing to Dc290_02. When running the import module, I will need to revise it to support whatever directory the camera happens to write the newest images to. I pointed this possible expansion in for the future out in a message on our website's message board: ok - another option for the import module - an input box asing the doctor to enter the path to the camera files. ex: P:\DC290_01 or something. That could easily go into a variable...but I'd rather test the camera more before trying to code something like this. Perhaps Adam should contact Digita and see if they can explain this issue. ;-) ? -jf March 13, 2000, 1:29 a.m. School is about to startup again. I have spent the majority of the evening attempting to bring all of my documentation up to date so I can continue moving forward without worrying about backlog in documentation. I have spent about two hours comparing old email messages and message board messages alongside senior project notes. I also made some recommendations to Yvonne that were referred to me earlier in the weekend [specifically changing the mouse to an hourglass while loading a time-consuming object and correcting a bug I found in her module]. March 14, 2000, 3:12 a.m. I worked for several hours tonight improving and modifying my import module. It now corrects several reported glitches and adds some support requested by the doctor. Here's a list of changes made this evening since about 9 o'clock: 1. Renamed filename of form from Import.frm to FrmImport.frm to match the naming conventions. 2. Attempted to preserve app.path internal to this module to prevent crashing other modules where the databases are not coded to a specific directory. I also tested the contents of app.path upon leaving my form and discovered that was not the problem. The problem appears exactly when these steps are followed: a. User opens common dialogue b. Selects a file c. Clicks open ß important If the user does not select open (or the location is changed internal to code back to the app.path), the database still gets changed to the cameradrive path. This is one of two remaining bugs in the module. 3. Rearranged labels on form so picture data is first / name data is under the picture filename and date / time information (since names aren't always there) 4. If a user selects cancel or does not enter a filename on the patients.txt dialogue, the program now takes you back to the main menu. It no longer closes the entire program. 5. Implemented meaningful error boxes / input boxes asking the doctor to provide information not supplied from the camera. If he clicks ok without entering anything or clicks cancel it exits the import module without writing any data and returns him back to the main menu. 6. Verified a "destination and source fields are not the same" warning error was a glitch caused by Adam's old camera script leaving out certain keyword #'s (example, keyword3 was followed by keyword5) 7. Coded a segment to insure a patient has not already been added to the database before an attempt is made to add a patient. This previously was causing a duplicate notice to appear on the import module. The only remaining bugs I am aware of are the common dialogue bug described in #2 of the above update and the "Requested action is not supported by the application if the object is closed" error. March 14, 2000, 3:19 a.m. I posted this message to the fidonet looking for responses concerning my glitches. I have also spent considerable time panning the newsgroups with search engines, but not in any organized manner. That is coming next – perhaps tomorrow night. Here is a copy of that message I sent out: =========================================================================== BBS: Doc's Place Bbs Online. Date: 03-14-00 (03:06) Number: 843 From: JAY FULLER Refer#: NONE To: ALL Recvd: NO Subj: Assistance, Please. ; 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- Well, you've all heard me moaning and groaning as I've been struggleing through this process of creating the final program for the capstone course of my school. Fortunately, we are now entering beta testing with only a few minor bugs. Unfortunately, the only bugs, so far, we have not been able to solve yet are from my module. Here are the circumstances and examples of what is happening. I am building SQL queries to add records to a database. I am using a data control [ADO] to connect to this database and am using the Microsoft Jet 4.0 engine. [the database is Access 2000 format]. I am then setting the recordsource for the data control to my SQL query for the data I need to add, for example, insert into patient values ... et cetera... then I am refreshing the data control. sql_temp (contains the sql statement) adcpatient.recordsoruce = sql_temp adcpatient.refresh On this refresh statement, I get the message: The operation requested by the application is not allowed if the object is closed. According to information I found on the web: ============================================= In addition to the provider errors that are described in the Error object and Errors collection, ADO itself can return errors to the exception-handling mechanism of your run-time environment. Use your programming language's error trapping mechanism, such as the On Error statement in Microsoftr Visual Basicr, to trap and handle the following errors. Both decimal and hexadecimal error code values are shown. AdErrObjectClosed - 3704 - 0x800A0E78 The operation requested by the application is not allowed if the object is closed. AdErrObjectClosed and Solution and Visual Basic returned no matches in the VB / MSDN resource. So, since the documentation I found suggested that this was an error generated that should be a trappable error, I am going to try to implement that code if it becomes a problem. I might spend another hour or so tonight trying to actually code the sql string(s) required. Sample error handling code: =========================== Description, NativeError, Number, Source, and SQLState Properties Example (VB) This example triggers an error, traps it, and displays the Description, HelpContext, HelpFile, NativeError, Number, Source, and SQLState properties of the resulting Error object. Public Sub DescriptionX() Dim cnn1 As ADODB.Connection Dim errLoop As ADODB.Error Dim strError As String On Error GoTo ErrorHandler ' Intentionally trigger an error. Set cnn1 = New ADODB.Connection cnn1.Open "nothing" Exit Sub ErrorHandler: ' Enumerate Errors collection and display ' properties of each Error object. For Each errLoop In cnn1.Errors strError = "Error #" & errLoop.Number & vbCr & _ " " & errLoop.Description & vbCr & _ " (Source: " & errLoop.Source & ")" & vbCr & _ " (SQL State: " & errLoop.SQLState & ")" & vbCr & _ " (NativeError: " & errLoop.NativeError & ")" & vbCr If errLoop.HelpFile = "" Then strError = strError & _ " No Help file available" & _ vbCr & vbCr Else strError = strError & _ " (HelpFile: " & errLoop.HelpFile & ")" & vbCr & _ " (HelpContext: " & errLoop.HelpContext & ")" & _ vbCr & vbCr End If Debug.Print strError Next Resume Next End Sub Of course, I am quite confused -- all I want is for this warning message to go away. The SQL query, by the way, is executed, and it does add the records just as it should. I've tried using the .open command, obviously, and it tells me this is not supported if the object is open. :-) The other bug occurs when a common dialogue is used to select a file to open for reading (which powers this module, used to import data). In our connection strings, built by clicking on the build button on the properties grid, we select our database as simply "Patients.Mdb" - no path or anything. This is fine, until the common dialogue is used. After which, the path for the database in my form (and in everyone else's form - about 6-7 data controls) - the path becomes P:\Patients.Mdb [as P:\ is the drive letter of the camera - and the data file]. Of course, we prefer for the Patients.Mdb to be in the App.Path directory, but even coding that does not seem to work. Any suggestions for handleing these glitches? I've thought of using another interface other than the common dialogue to get the location of the text file [just have the user type in a path], but surely these bugs have been come across before? _ANY_ suggestions would be greatly appreciated. So far, I've tried re-assigning the common dialogue properties in code to possibly go back to the app.path before exiting my module, but that is not working either. [apparently you have to select something _AND_ hit ok in the showopen before it will work]. - it'd be stupid to have a showopen just before exiting the import module just to prevent that fatal error. ;-) Thank you very much! Sincerely, Jay Fuller Senior, School of Computer and Information Sciences University of South Alabama, (Graduate in 7 weeks!) March 20, 2000, 1:50 a.m. I received a reply to the above request. Unfortunately, it did not solve the problem. The message I received: =========================================================================== BBS: Doc's Place Bbs Online. Date: 03-19-00 (14:30) Number: 523 From: LILA GODEL Refer#: NONE To: JAY FULLER Recvd: NO Subj: Assistance, Please. ; 1/2 Conf: (843) VISUAL_BAS --------------------------------------------------------------------------- _TID: PX/Win v3.0pr3 PX96-0423M2 _MSGID: 1:10/345 ae2ca49b _TZUTC: -1000 JF>The other bug occurs when a common dialogue is used to select a file to JF>open for reading (which powers this module, used to import data). In our JF>connection strings, built by clicking on the build button on the JF>properties grid, we select our database as simply "Patients.Mdb" - no JF>path or anything. This is fine, until the common dialogue is used. After JF>which, the path for the database in my form (and in everyone else's form JF>- about 6-7 data controls) - the path becomes P:\Patients.Mdb [as P:\ is JF>the drive letter of the camera - and the data file]. Of course, we JF>prefer for the Patients.Mdb to be in the App.Path directory, but even JF>coding that does not seem to work. Try entering the code X.InitDir = "P" where x is the name of the common dialog control and P is the desired start path before the code to display the dialog box. --- þ OLXWin 1.00b þ If (Wife = "yes") then (MONEY = "Gone") else Single * Origin: BBS Networks @ www.bbsnets.com 808-839-5016 (1:10/345) March 21, 2000, 2:21 a.m. SUCCESS! – at least with my other problem. ;-) Using a coded ADO control instead of the data control for writing in combination with opening and closing the connection just before and just after making the update. I no longer get the "closed" message. ;-) I also took some time to code some real message boxes and put in an image count as well. March 25, 2000, 5:39 p.m. Well, during the mid afternoon – we received a report that beta 2 was still crashing out due to the database relocation error caused by the common dialogue control. Yvonne tracked this but down as stated a few entries ago by using chdir to change the 'working system path' or whatever. Unfortunately, this did not solve the glitch between modules like we thought it did – instead, it simply fixed it within each individual module. After testing and more testing and putting chdir's in just about every location, I changed several things – (as the email read) : Dr. Brown [and Yvonne] I believe I have corrected the database glitch where it moves it to the virtual camera drive internal to the software. I solved this glitch [finally] by putting back in the flag with the common dialogue and also changing the line: open cdlpatient.filetitle for #1 to open cdlpatient.filename for #1 This had thrown an error in development but apparently did not cause problems after running and making an .EXE Dr. Brown - since you have already installed this package, I believe you can simply replace your Portable Patients.exe with the one included in this email and it will fix that glitch. Of course, with your new camera script Adam emailed you earlier today, you should be good to go. We were unable to duplicate the and bugs you described. However, I _DID_ test this implantation extensively [I imported roughly 25 pictures into the database either by manually adding them from the add/update module or via the import module using my "virtual" camera drive. Please keep us posted as to how this update has helped you! Thanks, Sincerely, Jay Fuller Portable Projects Development Team :) March 26, 2000, 8:15 p.m. Report came in from the client, Dr. Brown – about the beta sent out yesterday correcting the database glitches: Date: Sunday, 26-Mar-00 05:37 PM From: Dr. Mark Brown [Client] \ Internet: (mark@eyeplastics.com) To: Yvonne Totty [USOUTHAL] [CIS] \ Internet: (webyvonne@bigfoot.com) cc: Jay Fuller \ Internet: (jwfuller@hiwaay.net) ok, with the new empy database, the 2.3 sript, beta 2: the import all seems to work well, I do note that if you re-import an the same data, the image gets added again to the existing record the add new images works 30% of the time, seems to work better for existing record and much less so for a "new patient' images are distorted in thumbnail view and when printed are confined to particular jpg size rather than original file dimension? search mode: no change: is there a way to manually edit the mdb with access? mark Guess I would be better off documenting my reply, too: > the import all seems to work well, I do note that if you re-import an the same > data, the image gets added again to the existing record Yup - this is normal proceedure. The best I can do is change your summary message box there at the end of the import to remind you to run your camera flush script "at this time". > the add new images works 30% of the time, seems to work better for existing > record and much less so for a "new patient' Have you figured out exactly what pattern causes it to work? We only have test data - that is why it was vital we get this to you in a beta mode . > images are distorted in thumbnail view and when printed are confined to > particular jpg size rather than original file dimension? not my part - but I believe based on what I have seen the origional is never modified. The print size and thumbnail size _ARE_ proportional for that size display. to print the actual picture would take several sheets of paper I'm sure. You can try it, thou - the actual images are in their patents folder.....fire up the image in Netscape - [type in C:\ in the location bar] and click your way to program files , portable patients , images, patient # - and click the jpg file. It'll call it up in Netscape and you can select Print from there. > search mode: no change: We've noted the request for a textbox in addition to the combo box - it's coming. Spoke with Steve on that this afternoon [the search is his part] > is there a way to manually edit the mdb with access? I better stay out of this one. ;-) March 30, 2000, 12:15 a.m. After meeting with Dr. Brown earlier in the week, I had documented a few more changes the doctor preferred with the import module. I did not feel they would be too difficult to code and I finally got around to them tonight. [we met on Monday, this is Thursday night]. Here they are: 1. Updated the import module to check for duplicate entries in the image table for both patient number and picture filename. The hypothesis is if an image is being imported associated with a patient with the same filename, chances are the image was already imported. If not, he's going to overwrite a file that already exists for that patient. Either way, he'll get a notice now upon import that he could have possibly already imported these images. I think I will also change the dialogue to report "You may have already imported these images, or there is a possibility you may be able to overwrite an image – do you wish to continue". 2. The first name field of a patient is no longer required to import. Now, instead of the program prompting for the first name upon import, it will write a space [similar to middle name] – as the doctor requested.