Search found 22 matches

by DDastardly71
Tue Aug 18, 2009 4:54 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Modulus
Replies: 4
Views: 10326

I just copied the formula verbatim from the web site that I got it from but it would make sense to divide by something, otherwise, you will get whatever big number ip_number is. This is the part where I'm confused. How to isolate the value of z. Second question: How do I use MOD on double-precision ...
by DDastardly71
Mon Aug 17, 2009 3:49 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Modulus
Replies: 4
Views: 10326

Modulus

I am trying to do a simple math using Modulus on large double-precision numbers and I'm encountering an error. I'm trying to convert an IP address to an IP number and I'm getting an error on the last part. It works fine on paper but not in code. IP_Address To IP_Number w = 202 x = 186 y = 13 z = 4 I...
by DDastardly71
Wed Jul 29, 2009 7:09 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Arrow menues
Replies: 7
Views: 11988

For this example, the first time is in row 1, therefore, I only had to use Choice% as the pointer for the actual row. LOCATE Choice, 8: PRINT ">" LastChoice = Choice However, if you wanted to move the menu items to a different position, change the data statement to reflect the new position...
by DDastardly71
Thu Jul 09, 2009 4:07 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Arrow menues
Replies: 7
Views: 11988

Here is a simple way to dynamically add or delete menu items. This code only looks long because it's indended and its in blocks. ' ' goo1 ' DEFINT A-Z Main: CLS '-- To add or delete items from the array you only need to ' modify the data statement and do two things... ' ' 1. Change the first data st...
by DDastardly71
Tue Jun 30, 2009 11:20 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Array Descriptor
Replies: 2
Views: 6296

Thanks for that reply but that won't work. Even with fixed length string array you still have to set the correct segment before you can peek at the memory. I know this is unorthodox way of doing it when I could easily just pass the array into the procedure. I wrote a user interface function in PDS f...
by DDastardly71
Wed Jun 17, 2009 11:54 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Location
Replies: 3
Views: 7229

If the folder is in the same directory as your program, you can use relative instead of absolute path and without using CHDIR. Works... OPEN "text\text.txt" FOR INPUT AS #1 Will not work...this is an incomplete path as shown from the previous reply. OPEN "\text\text.txt" FOR INPU...
by DDastardly71
Wed Jun 17, 2009 11:43 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Menu
Replies: 4
Views: 8385

I won't lie to you it can get a bit complex. If you are using PDS 7.1, it comes with a very good menu/windowing system with source code. If you have the original box and you have the reference manual, it has an entire chapter dedicated just to the menu/windowing system. Since it's written by Microso...
by DDastardly71
Tue Jun 16, 2009 5:17 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Array Descriptor
Replies: 2
Views: 6296

Array Descriptor

Using ONLY the PEEK function, how would I be able to extract the information of the array descriptor and print each elements. This procedure should be able to print the elements of the array regardless if its 1, 2, or more dimensions. Example: DIM Array1$r(1 to 5) Array1$r(1) = "orange" Ar...
by DDastardly71
Tue Jun 16, 2009 5:12 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Menu
Replies: 4
Views: 8385

Are you talking about like QB's dialog box when saving files??
by DDastardly71
Tue Jun 16, 2009 5:10 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: QB4.5 Multi-Modular Programs?
Replies: 3
Views: 7080

If you are programming inside the QB environment load each sub module(s) (.bas) file using File, Load File individually into your main module.
by DDastardly71
Sat Jun 06, 2009 12:32 am
Forum: QBASIC and QB64 Questions & Answers
Topic: FILE SIZE
Replies: 2
Views: 6686

FILE SIZE

Looking at this procedure that was written by Alex Warren, 18th April 1998, LONG FILENAMES FROM DOS DEMONSTRATION v1.0. does anybody know how to extract & convert the file size thats retured after calling the FindFirst Interrupt? How do you convert QWord & DWord to QB? Please give some examp...
by DDastardly71
Thu Jun 04, 2009 11:43 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Background Colors in Text Mode
Replies: 6
Views: 19396

I don't mean to sound like a noob but how do you insert this into your program.

This is what I want to accomplish...

COLOR 0, 15

without it blinking. Please include a sample code.
by DDastardly71
Thu Jun 04, 2009 6:07 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Background Colors in Text Mode
Replies: 6
Views: 19396

Thanks for that quick reply but I forgot to mention that I needed it for SCREEN 0.
by DDastardly71
Thu Jun 04, 2009 1:56 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: QBL
Replies: 2
Views: 6388

Read the book that Ethan Winer wrote called "BASIC Techniques and Utilities". It covers everything from compiling, quick libraries, database, and other advanced topics on quickbasic. A bible for serious programmers. Go to his web site and download this book that he converted to a text file...
by DDastardly71
Thu Jun 04, 2009 10:23 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Background Colors in Text Mode
Replies: 6
Views: 19396

Background Colors in Text Mode

I have seen some programs that used colors beyond &H8 for its background like the old Norton Utilities that used &HF. How can I do this programmatically?

Can I do this strictly QB or with the aid of ASSEMBLY? Can you provide a code?
by DDastardly71
Thu Jun 04, 2009 10:04 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Time Stamp
Replies: 0
Views: 10495

Time Stamp

Does anybody have a function that can generate a timestamp in seconds and back to date format with a variable date reference? example: seconds& = TimeStamp&(Month%, Day%, Year%, Hour%, Minutes%, Seconds%) with a variable date of 1-1-1970 ..and back to date format dateformat$ = Seconds2DateFo...
by DDastardly71
Sun Jan 18, 2009 1:12 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Fast Line Parser
Replies: 2
Views: 6013

Thanks for the code...exactly what I was looking for...short and sweet.

Thanks
by DDastardly71
Fri Jan 16, 2009 2:58 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Fast Line Parser
Replies: 2
Views: 6013

Fast Line Parser

Anybody have a fast code for parsing a line of text? I have one but it takes about 5 seconds to process 65,000 lines of text. I don't exactly need to extract the word just return the pointer of the first character in the text. Something like this... a$ = "the quick brown fox jumps over the lazy...
by DDastardly71
Fri Jan 16, 2009 2:46 am
Forum: QBASIC and QB64 Questions & Answers
Topic: Passing Array Pointers
Replies: 1
Views: 5313

Passing Array Pointers

I'm writing a program to process a form file created using a form designer. In one form I can have one or more listboxes (i.e. note field or listbox for inventory). Each field is identified by a unique number (1=string, 2=listbox, 3=number, etc). When I inialize the program, I assign the segment/add...
by DDastardly71
Sat Oct 18, 2008 12:57 am
Forum: QBASIC and QB64 Questions & Answers
Topic: HTML to QB Colors
Replies: 4
Views: 8476

Thanks, that works great. The only thing is that I can't get it to work on SCREEN 0, only on SCREEN 12. What I'm trying to do is to display a text starting with black and slowly increasing in intensity until it reaches maximum color. I guess PALETTE doesn't work well on SCREEN 0. SCREEN 12 it is the...