Search found 61 matches
- Jan 02, 2016 16:44
- Forum: Beginners
- Topic: gdb: How to print item in array?
- Replies: 1
- Views: 4529
gdb: How to print item in array?
Freebasic 1.04.0 32bit on Windows 7/8 64bit. When I'm in the gdb debugger, how do I print an item in an array? dim filearr(2) as string filearr(0)="zero" filearr(1)="one" At the debugger prompt, I type 'p FILEARR(0)' and I get an error 'Invalid data type for function to be called...
- Jan 02, 2016 0:21
- Forum: Beginners
- Topic: Why do I get "duplicate definition" error?
- Replies: 3
- Views: 1649
Re: Why do I get "duplicate definition" error?
Doh! Thank you. What I could use is a list of reserved words so I can grep though them easily.
- Jan 02, 2016 0:15
- Forum: Beginners
- Topic: Why do I get "duplicate definition" error?
- Replies: 3
- Views: 1649
Why do I get "duplicate definition" error?
Please be patient, I'm still learning Freebasic. Freebasic 1.04.0 32 bit on Win 7/8 64-bit. I get an error 4 "Duplicate definition lpos" in the code below. The below code is a separte BAS file which is not my main program. Beginning with the first line: ' Markdown to XHTML file for Freebas...
- Jan 01, 2016 21:42
- Forum: Libraries Questions
- Topic: How to fix PCRE error -2?
- Replies: 5
- Views: 2068
Re: How to fix PCRE error -2?
Freebasic 1.04.0 32 bit, "target: win32 486 32bit" but my Windows 8 is a 64-bit OS on a 64-bit machine. Is that a problem? I thought Win8 would be backward compatible with 32bit apps.
- Jan 01, 2016 21:35
- Forum: Beginners
- Topic: Does EXE grow as I #include libraries?
- Replies: 2
- Views: 863
Does EXE grow as I #include libraries?
As I use #include "something.bi" does my EXE grow because library codes is being added to the EXE?
Do I have to distribute any DLL files with my EXE file?
Just wondering.
Thank you.
Do I have to distribute any DLL files with my EXE file?
Just wondering.
Thank you.
- Jan 01, 2016 20:29
- Forum: Sources, Examples, Tips and Tricks
- Topic: Read text file into array
- Replies: 1
- Views: 1335
Read text file into array
Given a filename that is a text file, this checks to see if the file exists, and if it does, it reads the file into an array. sub readfile(Byref fn as string, filearr() as string) ' This also ignores comment lines beginning with '#'. ' Usage: ' Dim as string filename ' Dim filearr() as string ' read...
- Jan 01, 2016 20:24
- Forum: Libraries Questions
- Topic: How to fix PCRE error -2?
- Replies: 5
- Views: 2068
Re: How to fix PCRE error -2?
I changed my inc\pcre.bi back to what it was, and I'm still getting an error -2. This is my inc\pcre.bi:
Any ideas?
Code: Select all
#pragma once
#inclib "pcre"
#include once "pcre-common.bi"
- Jan 01, 2016 19:04
- Forum: Libraries Questions
- Topic: How to fix PCRE error -2?
- Replies: 5
- Views: 2068
How to fix PCRE error -2?
Freebasic 1.04.0 on Windows 7/8. When I search for a regex in a string I get an error inside my routine getregexstr which I copied from this forum somewhere I think. Here's the subroutine. function getregexstr(buffer as string, pattern as string) as string ' Returns blank if not found, matched part ...
- Jan 01, 2016 16:50
- Forum: General
- Topic: Win8: CHM help file won't show help topics
- Replies: 3
- Views: 1071
Win8: CHM help file won't show help topics
I have Windows 8. I opened the CHM help file for Freebasic 1.04, and it opens showing the TOC, but when I click on an entry on the TOC, no text shows up in the left hand help pane. This was true of the CHM file for Freebasic 0.90 also. Any ideas how to fix this? I'd be fine if I could download a tre...
- Jan 01, 2016 16:45
- Forum: Beginners
- Topic: How to read text file into array?
- Replies: 5
- Views: 2041
Re: How to read text file into array?
Got it. fxm, would you mind if I posted your routine in the forum for Tips and Tricks?
- Jan 01, 2016 16:35
- Forum: Libraries Questions
- Topic: Regex: how to replace all of given string with back referenc
- Replies: 0
- Views: 1441
Regex: how to replace all of given string with back referenc
Freebasic 1.04.0 on Win 7/8. I'm a Freebasic beginner, long time Perl programmer. I've Googled the forum and the internet and didn't find what I was looking for. Basically I need a Freebasic regex lib that supports back references. I'm a Perl programmer and in Freebasic I want to be able to convert ...
- Jan 01, 2016 16:22
- Forum: Libraries Questions
- Topic: Trying to use regex lib but get error
- Replies: 2
- Views: 1436
Re: Trying to use regex lib but get error
Thank you! I got it working but I did have to update freebasic\inc\pcre.bi to look like this: #pragma once '#inclib "pcre" #inclib "pcre3" #include once "pcre-common.bi" and I did have to put pcre3.dll in the same dir as my EXE and BAS file. Not sure why since my path i...
- Dec 31, 2015 21:48
- Forum: Beginners
- Topic: How to read text file into array?
- Replies: 5
- Views: 2041
Re: How to read text file into array?
I just changed the parameters to outarr() and it worked, which is similar to what you did. Thank you!
- Dec 31, 2015 20:02
- Forum: Beginners
- Topic: How to read text file into array?
- Replies: 5
- Views: 2041
How to read text file into array?
Windows 7 cmd box, Freebasic 1.04.0. New to Freebasic, I'm used to Perl. I'm trying to create a general purpose subroutine where, given the filename, it reads the whole text file into an array. Currently I have: sub readfile(Byref fn as string, filearr() as string) ' Read .BLD file and set global va...
- Dec 31, 2015 18:50
- Forum: Libraries Questions
- Topic: Trying to use regex lib but get error
- Replies: 2
- Views: 1436
Trying to use regex lib but get error
I'm on Win7, cmd window using Freebasic 1.04.0 for win32 and I'm new to Freebasic. I'm normally a Perl programmer so I'm real partial to regex. I'm getting an error when I compile "c:\me\compiler\freebasic104\bin\win32\ld.exe: cannot find -lpcre". From searching around it sounds like I nee...