home *** CD-ROM | disk | FTP | other *** search
/ Boston 2 / boston-2.iso / DOS / PROGRAM / BASIC / POWBASIC / LIBRARY1 / EXAMP2.ZIP / PB050290 < prev    next >
Text File  |  1990-05-02  |  18KB  |  462 lines

  1. all
  2. H#: 42252 S12/SPECTRA Publishing
  3.     28-Apr-90  16:16:56
  4. Sb: DOS 3.2 vs 2.11 Fixed
  5. Fm: John Carter 72236,154
  6. To: Bob Zale
  7.  
  8. Bob,
  9.   When PB2.0b(4.90) didn't fix my problem, I had to go look for 'real' bugs. It
  10. seems that DOS 3.2 is more forgiving than DOS 2.11.
  11.  
  12. I had a path building subroutine that appended the final "\" and the
  13. appropriate wildcards to the data directory path.  I recently changed the main
  14. program to add the "\" there.  However, I failed to change the subroutine that
  15. also added the final "\".  A path name of "c:\path\\file.ext" works for the DOS
  16. findfirst and findnext calls from PB in DOS 3.2, but not in DOS 2.11. I made
  17. the one character change in the subroutine and now the code works under either
  18. version of DOS.
  19.  
  20. Thanks for your help. John
  21.  
  22. Press <CR> for next or type CHOICES !
  23. H#: 42496 S12/SPECTRA Publishing
  24.     30-Apr-90  07:11:55
  25. Sb: #PB & Paradox Engine
  26. Fm: Tim Schreiner 74017,2570
  27. To: Barry Erick
  28.  
  29. Barry,
  30.         Is it possible to use or link PowerBASIC with 'Turbo C' routines to
  31. utilize Borland's new Paradox Engine ? I have some data entry applications
  32. built in Paradox, but Paradox is too slow to accomplish most of the other
  33. things I need to do. It would be ideal if I could use some of the existing
  34. app's, and blend them with low-level access and the SPEED of PowerBASIC.
  35. Otherwise, I have need a for database toolbox that will handle file/record
  36. locking on a network. (maybe someone has modified Borland's ?)
  37.  
  38. Thanks, --Tim
  39.  
  40. There are 3 Replies.
  41.  
  42. Press <CR> for next or type CHOICES !
  43. H#: 42607 S12/SPECTRA Publishing
  44.     30-Apr-90  16:16:36
  45. Sb: #42496-PB & Paradox Engine
  46. Fm: Barry Erick for Spectra 75300,214
  47. To: Tim Schreiner 74017,2570 (X)
  48.  
  49. Tim,
  50.  I do not thing tc code can be imported into PB for the linking. A small
  51. model's obj 'may' be linkable.. but I do not think it ends correcty. I have not
  52. tried it to find out..  This one is really for Bob to answer..
  53.     --- Barry
  54.  
  55.  
  56.  
  57. Press <CR> for next or type CHOICES !
  58. H#: 42677 S12/SPECTRA Publishing
  59.     30-Apr-90  20:54:49
  60. Sb: #42496-#PB & Paradox Engine
  61. Fm: Bob Zale: PowerBASIC R&D 76304,1303
  62. To: Tim Schreiner 74017,2570 (X)
  63.  
  64.   Tim--
  65.     Due to the difference in calling conventions, I'm a little dubious about
  66. getting that code to work without quite a bit of conversion.  We plan to look
  67. into it closely, very soon, and we'll post our "results" here just as soon as
  68. we can.  How about Novell's BTRIEVE package?  Won't that work for you?  We have
  69. a very simple interface already running and posted in our library.  If not, let
  70. me know.  We'll do our best to help you find something that fits your needs.
  71.  Bob Zale
  72.  
  73. There is 1 Reply.
  74.  
  75. Press <CR> for next or type CHOICES !
  76. H#: 42774 S12/SPECTRA Publishing
  77.     01-May-90  09:38:52
  78. Sb: #42677-#PB & Paradox Engine
  79. Fm: Mike Burns 71551,1353
  80. To: Bob Zale: PowerBASIC R&D 76304,1303 (X)
  81.  
  82. Bob,
  83.  The primary problem in using C code with PB is the use of
  84.  C standard libraries. If you use any C standard function
  85.  (scanf, fseek, atan, etc.) You will need to extract those
  86.  routines from the c library and link them also. If those
  87.  use additional functions, then they also need to be extracted
  88.  and linked.
  89.                 Mike
  90.  
  91.  
  92. There is 1 Reply.
  93.  
  94. Press <CR> for next or type CHOICES !
  95. H#: 42858 S12/SPECTRA Publishing
  96.     01-May-90  17:12:42
  97. Sb: #42774-PB & Paradox Engine
  98. Fm: Tim Schreiner 74017,2570
  99. To: Mike Burns 71551,1353 (X)
  100.  
  101. Barry & Bob,
  102.  
  103. Thanks for the quick reply. I was a little afraid that it may not work with the
  104. 'C' library, more because of the differences in the way the stack is handled.
  105. Mike also pointed out that the 'C' libraries would need to be linked as well. I
  106. may be barking up the wrong tree on this one. I don't care for the Btrieve, as
  107. it stores the indexes and data in the same file, and may prove ddifficult to
  108. recover in the event of a crash. I like to keep the data separate so that you
  109. can re-build the indexes if they get 'dirty'. I will d/l the interface file you
  110. described for a look. --Tim
  111.  
  112. Press <CR> for next or type CHOICES !
  113. H#: 42978 S12/SPECTRA Publishing
  114.     02-May-90  03:26:34
  115. Sb: #42496-#PB & Paradox Engine
  116. Fm: Michael Sawczyn 72245,1721
  117. To: Tim Schreiner 74017,2570
  118.  
  119. Tim,
  120.  
  121. Boy does that sound familiar. I wrote a massive Paradox application that took
  122. 45 minutes to run, and had our Estimating department at my throat. Rewrote it
  123. in PB and it zips in 3-4 seconds.
  124.  
  125. To get around the file/record locking thing on our Novel network, I opened the
  126. data files, found the data I was looking for, and closed the file. Around each
  127. OPEN statement I put an "ON ERROR GOTO ERRORTRAP" and "ON ERROR GOTO 0"
  128. statement, so that if, in the short time needed to find the file someone else
  129. has it open, it'll just wait and retry. ERRORTRAP: was nothing more than a
  130. RESUME. I saved the pointer for the record number so that, when rewriting the
  131. data, it just had to open, write, and close.
  132.  
  133. --Michael
  134.  
  135.  
  136.  
  137. There is 1 Reply.
  138.  
  139. Press <CR> for next or type CHOICES !
  140. H#: 42983 S12/SPECTRA Publishing
  141.     02-May-90  04:49:16
  142. Sb: #42978-PB & Paradox Engine
  143. Fm: Barry Erick for Spectra 75300,214
  144. To: Michael Sawczyn 72245,1721
  145.  
  146. 45 minutes! Yikes. Sounds like a mainframe....
  147.       --- Barry
  148.  
  149.  
  150.  
  151. Press <CR> for next or type CHOICES !
  152. H#: 42500 S12/SPECTRA Publishing
  153.     30-Apr-90  07:36:57
  154. Sb: #TB v. PB compilation
  155. Fm: Rodney Jones 73237,3114
  156. To: Bob Zale 76304,1303 (X)
  157.  
  158. I received v2.00b in Thursday's post and I have already spent a lot of time
  159. trying it out.  I am very impressed with the PowerBASIC compiler's efficiency
  160. with small programs, but am having a lot of trouble with one reasonably large
  161. program in particular.  The program is 5654 lines (and about 5040 statements)
  162. long.  The identical code was used throughout.  The comparison that follows is
  163. for a Toshiba T5100 running DOS 3.3, with no TSRs loaded and maximum memory
  164. (608 832 bytes) free.
  165.  
  166.  TB   120 k free   27 seconds   EXE size = 201985
  167.  PB    10 k free   60 seconds   EXE size = 219537 (reduced to 218353 by $LIB-)
  168.  PBC  100 k free   51 seconds   EXE size = 219537
  169.  
  170. I am very surprised that PB and PBC are so much slower than TB and leave so
  171. much less memory free.  However, what really disturbs me is that the EXE file
  172. is so much larger.  (For all of my smaller programs, the EXE file has been
  173. significantly smaller.)  Am I doing something wrong, or shall I send the ZIPped
  174. source and data files (about 400 k, I guess) to you?
  175.  
  176. Another question:  What is expanded (EMS) memory used for in PB 2.00b? When I
  177. run PB without loading EMM.SYS I have about 10k more memory left after
  178. compiling a program than when EMM.SYS is active.
  179.  
  180. Another problem:  Occasionally, the number of lines of code reported in pass 1
  181. of the compilation differs (by a few lines, e.g. 5630 and 5624) from that
  182. reported in pass 2.
  183.  
  184. There are 2 Replies.
  185.  
  186. Press <CR> for next or type CHOICES !
  187. H#: 42608 S12/SPECTRA Publishing
  188.     30-Apr-90  16:16:43
  189. Sb: #42500-TB v. PB compilation
  190. Fm: Barry Erick for Spectra 75300,214
  191. To: Rodney Jones 73237,3114 (X)
  192.  
  193. Rodney,
  194.  PB uses error checks as the default, while TB didn't. This is in the options
  195. and can be turned off in pb to match and better tb. Or slow down tb's compile
  196. and increase the file size by turning them on.
  197.  Turning this off will decrease the file size of PB. When you tweak its
  198. settings, PB will most definately beat TB.
  199.  ----- Barry
  200.  
  201.  
  202.  
  203. Press <CR> for next or type CHOICES !
  204. H#: 42676 S12/SPECTRA Publishing
  205.     30-Apr-90  20:50:22
  206. Sb: #42500-TB v. PB compilation
  207. Fm: Bob Zale: PowerBASIC R&D 76304,1303
  208. To: Rodney Jones 73237,3114 (X)
  209.  
  210. Rodney--
  211.   The results you mention certainly are different from what we've been seeing
  212. in our tests, but I sure don't want to "dismiss" them.  Whether it's a problem
  213. in something you're doing, or a problem in the compiler, I'd sure like to see
  214. what's causing the difference.  Unfortunately, without the source, there's
  215. little I can do without being able to reproduce the symptoms.  As the size is
  216. probably bigger than the Compuserve file limit, I'll e-mail you my mailing
  217. address, and I hope you can get the source code to us as quickly as possible. 
  218. The current version of PB uses up to 64k of EMS to store source code only. 
  219. This is great if you have the EMS "window" above 640k, but if the driver uses
  220. 64k of your 640k, you're bound to lose some capacity.  Our next version will
  221. make extensive use of EMS, for practically unlimited program size.
  222.   Bob Zale (PowerBASIC R&D)
  223.  
  224. Press <CR> for next or type CHOICES !
  225. H#: 42733 S12/SPECTRA Publishing
  226.     01-May-90  06:35:57
  227. Sb: #MicroStar and PB
  228. Fm: Phil Ihrig 74000,3020
  229. To: PB Tech Support
  230.  
  231.      What is the format of PBC.CFG?  Can it be created with the IDE?  Does
  232. PBC.CFG offer any capability not available by using a batch file containing the
  233. appropriate switches?
  234.  
  235.      What is the meaning of the command line compiler error message "Too many
  236. filenames!"?  What other error messages are likely to occur using PBC?
  237.  
  238.      I am attempting to compile the TB Editor Toolbox MicroStar program with PB
  239. and suspect it may have to be converted to units.  My understanding is that all
  240. SHARED variables in the subroutines have to be declared PUBLIC in the main
  241. program and declared EXTERNAL in the subroutines.  Should I leave the SHARED
  242. declarations in the subroutines?  Would all of the MS subroutines have to be
  243. made PUBLIC (and DECLARED in the main program)?
  244.  
  245.      After changing the variable names that conflict with PB, each of the
  246. present INCLUDE files would then be compiled to a unit and the $INCLUDE
  247. "filename" statements in the main program would be replaced with $LINK
  248. "filename".  If this is not the general approach to doing this please let me
  249. know.  If anyone has already done this or has other ideas about how to convert
  250. MicroStar to PB I would appreciate hearing about it.
  251.  
  252.      How does the size of a PB program (.exe file) change when the program is
  253. created by linking units rather than by a single compilation of all of the PB
  254. source?
  255.  
  256. There is 1 Reply.
  257.  
  258. Press <CR> for next or type CHOICES !
  259. H#: 42832 S12/SPECTRA Publishing
  260.     01-May-90  15:18:56
  261. Sb: #42733-#MicroStar and PB
  262. Fm: Barry Erick for Spectra 75300,214
  263. To: Phil Ihrig 74000,3020 (X)
  264.  
  265. Phil,
  266.  First, the PBC.CFG is not the same as the one for pb made by the ide. The
  267. commands in it are the same that you would use from the command line to run
  268. PBC. My entries only show the directories, but you should get the idea from my
  269. PBC.CFG:
  270.  
  271.  -dusd:\pb\pbus
  272.  -dudd:\pb\pbud
  273.  -did:\pb\inc
  274.  
  275.  This shows my default Unit Source directory is d:\pbus, my default Unit
  276. Destination directory is d:\pb\pbud and my default include directory is
  277. d:\pb\inc.
  278.  The cr at the end of each line is not necessary; you can make it look just
  279. like the command line would following the filename.
  280.  
  281.  Too many filenames means you left off the delimiter.. the - or / below:
  282.       PBC MyFile ce   would produce too many filenames, but I meant to use:
  283.       PBC MyFile -Ce or
  284.       PBC MyFile /Ce
  285.  A space is not a valis switch identifier, and only the one filename is legal.
  286. any other word on the line without being preceeded with a switch indicator - or
  287. / will produce the error.
  288.  More in the next message.
  289.  
  290. [More]
  291.  
  292.  
  293.  
  294. There are 2 Replies.
  295.  
  296. Press <CR> for next or type CHOICES !
  297. H#: 42833 S12/SPECTRA Publishing
  298.     01-May-90  15:19:12
  299. Sb: #42832-MicroStar and PB
  300. Fm: Barry Erick for Spectra 75300,214
  301. To: Barry Erick for Spectra 75300,214 (X)
  302.  
  303. [Continued]
  304.  
  305.  Shared can stay in the subs, but is not necessary. Also, some of th inline
  306. routines have to be changed, and you'll find that info in the Toolfix.zip file.
  307. While the file is for the database, the rouines are used in both.
  308.  Also, note that moving thes to units change one thing... you cannot use FN
  309. functions in units... All FN functiosn have to change to true FUNCTIONS. All
  310. subroutines _can_ be made public, or you can search all over to see who calls
  311. who and make the decision as to which ones would be used outside the units.
  312. However, for the microstar, I think you can leave it as INC files and get away
  313. with only changes to the inline routines. I have not tried it, tho.
  314.  Also, you may want to get LisVar.zip from library. It goes throu the unit
  315. source and makes a file that changes all EXTERNALS to PUBLIC variables for easy
  316. inclusion in the main.
  317.  You are correct about changing the $Include to $link. I usually keep an
  318. include and let the new include to the linking. This allows the include to
  319. carry all PUBLICS and also (unnecessary) Declare statements so the contents of
  320. the PBU is readilly known. Also, any external routines have to be Declared in
  321. each units source code before you can make the pbu.
  322.  And the size of the program does drop a little, but the memory needed to
  323. compile drops signifigantly.
  324.     --- Barry
  325.  
  326.  
  327.  
  328. Press <CR> for next or type CHOICES !
  329. H#: 42920 S12/SPECTRA Publishing
  330.     01-May-90  20:32:24
  331. Sb: #42832-#MicroStar and PB
  332. Fm: Phil Ihrig 74000,3020
  333. To: Barry Erick for Spectra 75300,214 (X)
  334.  
  335. Barry,
  336.  
  337. Thanks for the answers regarding PBC.  I am using the following configuration
  338. for PBC.  Are there any options that would give me more compiler space.
  339.  
  340. ce dec:\atw dic:\pb;c:\tbe eb-/en-/eo-/ep-/eslc-/le-/lg-/lp-/ls-/lvomc=8/omm=8
  341.  
  342. Using PBC, MicroStar runs out of compilation space with this configuration. The
  343. thought of changine MicroStar to use PBUs is not pleasant.  Do I understand you
  344. correctly that DECLARE statements for the subroutines in the PBUs are not
  345. needed?
  346.  
  347. Phil
  348.  
  349.  
  350.  
  351. There is 1 Reply.
  352.  
  353. Press <CR> for next or type CHOICES !
  354. H#: 42982 S12/SPECTRA Publishing
  355.     02-May-90  04:49:11
  356. Sb: #42920-#MicroStar and PB
  357. Fm: Barry Erick for Spectra 75300,214
  358. To: Phil Ihrig 74000,3020 (X)
  359.  
  360. Phil,
  361.  Does that compile line really work? I see things that would (or should) give
  362. "Too many filenames" error in that no switch (- or /) is infront of many
  363. options.
  364.  Anyway, you can drop the comm buffer to 0 to get a little more space, and the
  365. best way is by making a few modules units. that brings in bunches of memory at
  366. times.. depends on many things.. Converting to a unit is not too bad at all...
  367. it can be done real fast, infact. Usually, do an overkill and bring all shared
  368. up with Ctrl QA and changed the shared to External, run ListVars and stick them
  369. in the main.. Place PUBLIC after any routine not used only locally, or do it
  370. for all them... Then, To know exactly what needs to be declared, just compile
  371. to Unit... you'll be told if any declareds were missed. Each Unit _does_ need
  372. declares for any routine external to it. You do not need to declare routines
  373. outside the unit, however.
  374.  The biggest problem you may get, unless you use listvars to get the public
  375. variables, is not matching a PUBLIC for every external... It is ok to have more
  376. Publics than matching Exterals, but it is not ok to leave a External dangling.
  377.        --- Barry
  378.  
  379.  
  380.  
  381. There is 1 Reply.
  382.  
  383. Press <CR> for next or type CHOICES !
  384. H#: 43014 S12/SPECTRA Publishing
  385.     02-May-90  07:03:48
  386. Sb: #42982-MicroStar and PB
  387. Fm: Phil Ihrig 74000,3020
  388. To: Barry Erick for Spectra 75300,214
  389.  
  390. Barry,
  391.  
  392. You're right about the compile line as it showed up in the message.  I forgot
  393. to indent the lines and some characters got lost when the message was posted.
  394.  
  395. Thanks for outlining your approach to converting to units.  I will jump in and
  396. try to get MS converted.  Another application built around the TB Editor
  397. Toolbox works well in PB and demonstrates that the toolbox fixes are okay.
  398.  
  399. Phil
  400.  
  401.  
  402.  
  403. Press <CR> for next or type CHOICES !
  404. H#: 42781 S12/SPECTRA Publishing
  405.     01-May-90  10:55:08
  406. Sb: What am I doing wrong?
  407. Fm: Robert N. Barrett 76530,1452
  408. To:  76304,1303 (X)
  409.  
  410. Bob, I'm having trouble getting a program to work with the new Btrieve
  411. interface. I have uploaded the source and sent it to you via E-plex.  You'll
  412. need PKZ version 1.10 to unzip it.  The program is fairly simple, but it
  413. doesn't run as a stand-alone program.  However, it does run in the IDE if you
  414. step through it. Robert
  415.  
  416. Press <CR> for next or type CHOICES !
  417. H#: 42782 S12/SPECTRA Publishing
  418.     01-May-90  11:02:34
  419. Sb: What am I/Oops!
  420. Fm: Robert N. Barrett 76530,1452
  421. To:  76304,1303 (X)
  422.  
  423. BOB!!!!!!
  424.  
  425. I left off one line of code in the sample I sent to you.  You need to add
  426. the following near the beginning:
  427.  
  428. dim Junk%(288), vislet$(15), visdes$(15)
  429.  
  430. I was trying to clean up the program before I sent it to you and I
  431. deleted one too many lines.  By the way, I am using 2.00b with the
  432. 3/30 patch applied.
  433.  
  434. Robert
  435.  
  436. Press <CR> for next or type CHOICES !
  437. H#: 42998 S12/SPECTRA Publishing
  438.     02-May-90  05:47:27
  439. Sb: ACCESS.BOX TROUBLE
  440. Fm: DOUG MILLER 73757,1300
  441. To:  75300,214
  442.  
  443. BARRY  I AM TRYING TO GET UP TO SPEED WITH PB I AM HAVING A PROGLEM COMPILING A
  444. PROGRAM USING ACCESS.BOX I KEEP HIT AN ERROR DUPLICATE SUB WITH GETREC AND
  445. CANNOT FIND ANY DUPLICATE AND THE CALL STACK PROCEDURE IN DEBUG I AM PROBABLY
  446. NOT USING PROPLERLY
  447.  
  448. Press <CR> for next or type CHOICES !
  449. HPC Vendor B ForumHSections Menu
  450.  
  451. Section names (#subjs/# msgs)
  452.  1 Quarterdeck  (77/261)
  453.  2 Primavera Systems  (1/1)
  454.  3 Korenthal Assocs.  (5/26)
  455.  4 Personics Corp.  (23/116)
  456.  6 TurboPower Software  (31/215)
  457.  7 ChipSoft, Inc.  (3/11)
  458.  8 DacEasy  (23/52)
  459. 10 J.P. Software  (29/134)
  460. 11 PDC Prolog  (14/46)
  461. 12 SPECTRA Publishing  (7/20)
  462. HEnter choice(s) or ALL !