Search found 6 matches

by WAGNERLIP
May 30, 2013 19:03
Forum: Beginners
Topic: Open "filename" for output as #1
Replies: 10
Views: 3944

Re: Open "filename" for output as #1

Seriously though, your config file doesn't need to be made hidden, just put it in a standard location like APPDATA. Normal users will never find it there. If there is sensitive data stored in the config file then you should encrypt it either using the winapi functions or a trusted 3rd party library...
by WAGNERLIP
May 29, 2013 19:22
Forum: Beginners
Topic: Open "filename" for output as #1
Replies: 10
Views: 3944

Re: Open "filename" for output as #1

Some tips ;) - first line in code- unneeded - "fb" is default choice - use 'freefile' for file handle, not constants - wrong using of 'close' - in block - bad way 'opening file 'immediate read/write actions 'closing file - missing 'declare' if coding in non-spaghetti style - use '()' with...
by WAGNERLIP
May 29, 2013 19:20
Forum: Beginners
Topic: #lang "qb" + Dim Varx as Byte
Replies: 9
Views: 1461

Re: #lang "qb" + Dim Varx as Byte

I think instead of RANDOM ... LEN=1, I would recommend using BINARY for reading bytes. This can be done using a __byte/__ubyte variable, or for a method that will also work in QB, a var-length string containing a single character. Dim A as String Dim B as __UByte Open "filename" for binar...
by WAGNERLIP
May 27, 2013 23:34
Forum: Beginners
Topic: #lang "qb" + Dim Varx as Byte
Replies: 9
Views: 1461

#lang "qb" + Dim Varx as Byte

Okay, I am trying to make a big QBasic file works in FreeBasic. It is 98% working, now just little bits of problems that is causing me to desperate. First: In QB I was using Open "filename" for Random as #1 len=1 Field #1, 1 as A$ Get #1 or Get #1,,A$ So, the "random" filename co...
by WAGNERLIP
May 27, 2013 19:08
Forum: Beginners
Topic: Open "filename" for output as #1
Replies: 10
Views: 3944

Re: Open "filename" for output as #1

The root directory is a protected directory and you would need admin permissions to write there. I would suggest storing your configuration files in %APPDATA%/yourapp, the directory is hidden by default. Thank you for the hint. Even if in a subdirectory, it doesn't work. #lang "fb" #INCLU...
by WAGNERLIP
May 27, 2013 6:51
Forum: Beginners
Topic: Open "filename" for output as #1
Replies: 10
Views: 3944

Open "filename" for output as #1

Hi friends, this is my first post in this forum. I've being programming in compiled basic from decades, and was using QuickBasic + BasicCompiler (BC.EXE) since then. Then, by complete accident I found FreeBasic, and wow, no words. I am still smiling for more than 48 hours already. I converted some o...

Go to advanced search