• Welcome to Jose's Read Only Forum 2023.
 

O2 Arrays / BASIC Standardization

Started by Eduardo Jorge, September 03, 2022, 11:14:04 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Charles Pegge


I see multidimensional arrays are a problem when migrating code to o2, so I will be implementing it. I've got it for static arrays but not resolved with the redims.

Eduardo Jorge

#16
First, I'm sorry Charles,
if you are going to implement it for my sake, you don't need to, my use of "Basic" is just as a hobby and I use vba even more, I use O2 just to assemble some DLLs, which for me doesn't even make much difference.
and I don't think that's why O2 has few users, I think it's because of the lack of support tools to draw attention as a more professional "IDE", and a form assembler for applications.
after all, what is the difference between "O2" and these others?
differences between them all have.

Zlatko, what would I be complaining about if I'm not even a professional programmer, it makes no difference in my usage,
I just stated a fact.
I'm just one more passionate about "BASIC" that I would like to see being used more professionally without just selling compilers.
from what you said, it can't even be called a "BASIC" language, and should be called so-and-so dialect.

Of course, you couldn't stay in the way the language was created, like having to write "REM" on every line of comment, or having to use line number for jumps "Goto", or "LET" to declare a variable.
but changing both the base, like "if then" without the "then", "endfor" instead of "next", using "end, endif,..." , tells me which code doesn't have "if".

it's like you go to another region of your country, and get cursed, and think it's a compliment because the person used a local dialect,
and you still say thank you.

Eduardo Jorge

#17
o why these differences are problematic in professional use.
a simple example in my case that is not even relevant in terms of dependency.
I have a code that I made at the beginning when I got vba, I didn't even know how to use public variables or functions, so I used "Gosub", nowadays I don't use it anymore, but the code works for me until today,
today I would do it better, yes, but it has a certain complexity that I don't dare to rewrite, it's not that big, I got to rewrite it in "O2", but I had problems with the hd at the time and lost it, so I left it aside since the from vba works fine.
look at the mess, well it works for me...

Private Sub Realoar_Click()
     If Limit = 1 Then MsgBox "Favor não Executar essa tarefa Nesta Planilha": Exit Sub
     If Quant <> "" And Quant < 3 Or Quant <> "" And Quant > 1000 Then MsgBox "Quantidade de Colunas impossivel de processar": GoTo Saida
     inicio
     '----------------------------------------------------------------------------------( Variaveis de Controle )-----------
     Dim Ddo As Variant, ddai As Long    '----------------------Dados
     Dim Tv As Long    ' ---------------------------------------Teste de Valores 1 = passa no teste  : 0 = Não passa
     Dim T As Long    '-----------------------------------Teste  de teste  0 = Negativo : 1 = Positivo
     Dim K As Long, f As Long
     ''-----------------------------------( ORIGEM )-----------------------------------------------------------
     Dim Op As Long, iCo As Long    '--------------------Direção prioritaria Op="0 = Coluna: 1 = Linha"; Controle Zig Zag Coluna iCo ="0 =Não faz: 1= Faz "
     Dim OLi As Long, OLf As Long, TLo As Long     '------------------------------------Linha inicial e final,"podem ser de quadrante"
     Dim Lio As Long, Lfo As Long    '------------------------------------Linha inicial e final,Total linhas da origem

     Dim OCi As Long, OCf As Long    '------------------------------------Coluna inicial e Final "podem ser quadrante"
     Dim Cio As Long, Cfo As Long, TCo As Long    '-------------Total de colunas ,Coluna inicial e Final "Ci e Cf"

     Dim Coi As Long, Loi As Long    ' ---------------------------------------Posição da celula "Coi = Coluna"   "Loi  = linha"
     Dim Zig As Long, Lig As Long    '-----------------------------------incremento  de Coluna e Linha

     Dim OqC As Long, OqL As Long    '-------------------------quantidade de Colunas e Linhas do quadrante
     Dim OqLi As Long, OqLf As Long    '------------------Linha inicial e final do quadrante
     Dim OqCi As Long, OqCf As Long    '-------------Coluna  inicial e final do quadrante

     '---------------------------------( DESTINO )-----------------------------------------------
     Dim Dp As Byte    '-----------------------------------------------------Direção prioritaria do Destino 0 = coluna: 1 = Linha
     Dim DLi As Long, DLf As Long, TLd As Long    '------------------------------------Linha inicial e final,Total linhas do Destino
     Dim Dci As Long, Dcf As Long    '------------------------------------------------Coluna inicial e Final

     Dim cdi As Long, Ldi As Long    ' ---------------------------------------PosiçãD Coluna Destino
     Dim Zag As Long, Lag As Long    '-----------------------------------incremento  de Coluna e Linha

     Dim DqC As Long, DqL As Long    '-------------------------quantidade de Colunas e Linhas do quadrante
     Dim DqLi As Long, DqLf As Long    '------------------Linha inicial e final do quadrante
     Dim DqCi As Long, DqCf As Long    '-------------Coluna  inicial e final do quadrante
     '---------------------------------------------------------------------------------------------------------( definição de variaveis )--------------------------

     '--------------------------------------------------------------------------------------------------------------
     'Plan Auxiliar
     PlanAtual = ActiveSheet.Name

     If Selecsetrel = True Then
          cs = Cells(10, Selection.Column).Value2

          cs = Cells(1, cs).Column
          If cs > 0 And cs < 10 Then
               Call Copia_SetorO(cs, Plan_list)
          Else
               MsgBox "Seleção não pertence a nenhum Setor"
               Exit Sub
          End If
     Else
          Call Copia_SetorO(De_1, Plan_list)
     End If

     If ExecAçõesOrigem Then
          Executa_Ação TxtbAçõesOrigem.Value
     End If

     Sheets("AUXIa").Select
     Call Colar_Setor(1, ColunO, Li, "AUXIa")


     If Relocatd Then crit = 0 Else crit = 3
     ti_o = Cells(1, Cells(14, 1).Value2).Column  '--------------------- primeira coluna da origem    ti
     ci_o = ti_o + crit    '------------------------------------------------------- primeira coluna da origem    ci
     Cq_O = Cells(1, Cells(18, 1).Value2).Column - ci_o + 1  '----------Total de Colunas da origem
     Gd = Cells(1, Cells(14, 2).Value).Column + crit   ' ----------------------Destino

     Li_O = Cells(Rows.COUNT, ci_o).End(xlUp).Row + 1


     'Range(Cells(1, Cells(14, 2).Value), ActiveCell.SpecialCells(xlLastCell)).ClearContents
     '--------------------------------------------------------------------------------------------------------------
     If Quant = "" Then Cq = Cq_O Else Cq = Quant    ': If Relocatd Then Cq = Cq + crit
     'Cq = Cq - crit

     OLi = Cells(3, ti_o).End(xlDown).Row - 1                                       '----------------------------define a primeira linha com dados da Origem
     OLf = Cells(Rows.COUNT, ti_o).End(xlUp).Row + 1    '                   ' -------------------define a ultima linha com dados da Origem
     TLo = OLf - OLi   ' ---------------------------------------------------------------------define total de linhas da Origem

     K = (TLo - 2) * Cq_O    '- 1 '--------------------------------------------------------------------Total de Celulas da origem
     OCi = ci_o - 1             ' -----------------------------------------------------Coluna inicial em NUMERO  ORIGEM
     OCf = OCi + Cq_O + 1  ' ------------------------------------------Coluna Final em NUMERO  ORIGEM
     TCo = Cq_O + 1   '--------------------------------------------------------------------Total de Colunas da origem
     Dci = Gd - 1      '--------------------------------------------------------------------        'Coluna inicial em numero  DESTINO  "AuxB"
     Dcf = Dci + Cq + 1                                       ' Coluna Final em NUMERO  DESTINO
     TLd = (Int(TLo / Cq) * Cq_O) + Int(TLo Mod Cq)    'ns            ' QUANTIDADE DE LINHAS DO Destino
     dcdo = Dci - OCi    'diferença coluna inicial da origem para a coluna inicial do destino
     'MsgBox Cq_O

     If OLf - TLd < Li Then
          OLi = OLi + ((Li + (OLf - TLd) * -1) / ((Cq_O - 1) / Cq))

          TLo = Range(Cells(OLi, ci_o), Cells(OLf, ci_o)).Rows.COUNT       ' ---------------define total de linhas da Origem
          K = (TLo - 2) * Cq_O   '--------------------------------------------------------------------Total de Celulas da origem
          TLd = (Int(TLo / Cq) * Cq_O) + Int(TLo Mod Cq)    'ns            ' QUANTIDADE DE LINHAS DO Destino
     End If

     '--------------------------------------------------------
     DLi = OLi - 12                                                       'Linha inicial do Destino
     DLf = OLi + TLd - 1                                            'Linha Final do Destino
     Cio = OCi  ' -<<----- ( Coluna inicial Origem )--
     Cfo = OCf    'Oci + Cq_O 'Ocf ' -<<----- ( Coluna Final Origem )--

     '-----------------------------( DESTINO)------------
     Lag = 1    '  ------------------------------------------  incremento Linha de Destino
     If Alinhar_Baixo = True Then Lag = Lag * -1: DLi = OLf: DLf = DLi - TLd   '- 1)

     Ldi = DLi:     ' ------------------------------------------------Posição Linha Destino
     If Dinvert_L = True Then DLi = DLf: DLf = Ldi: Ldi = DLi: Lag = Lag * -1    'inverte linha

     Zag = 1  ' -----------------------------------------------------   incremento Coluna de Destino
     If Dinvert_C = True Then Zag = Zag * -1
     If DdpL = True And Dquadante_L = False Then Dp = 1: Dci = Dci + Zag: Dcf = Dcf + Zag Else Dp = 0: Ldi = Ldi + Lag    '-----0 = coluna: 1 = Linha
     cdi = Dci
     If Dinvert_C = True Then Dci = Dcf: Dcf = cdi: cdi = Dci    'inverte coluna
     If DdpL = True And Dquadante_L = True Then Dp = 1: Ldi = Ldi + Lag: cdi = cdi + Zag

     If Dquadante_L = True Then
          If DQuatL <> "" And DQuatL < TLd And DQuatL > 0 Then DqL = DQuatL Else DqL = Cq_O
          DLf = DLi + ((DqL + 1) * Lag)    '----------------------------------( Linha de baixo )----------------------------
          DqL = DqL * Lag: Ldi = DLi
          If Dinvq_L = True Then DLi = DLf: DLf = Ldi: Ldi = DLi: Lag = Lag * -1
          If Dp = 0 Then Ldi = Ldi + Lag
     End If

     If Dquadante_C = True Then
     End If
     Loi = 23
     '----------------------------------------------------------( ORIGEM )------------
     Lig = 1  '    incremento Coluna de origem
     Loi = OLi:     ' Posição Linha origem

     If Oinvert_L = True Then OLi = OLf: OLf = Loi: Loi = OLi: Lig = -1    'inverte linha de cima para baixo
     Zig = 1  '    incremento Coluna de origem
     If Oinvert_C = True Then Zig = Zig * -1:     'Cio = Cfo: Cfo = Oci: iCo = 1 Else iCo = 0

     If OdpL = True And Oquadante_L = False Then Op = 1: OCi = OCi + Zig: OCf = OCf + Zig Else Op = 0: Loi = Loi + Lig    'Linha com prioridade
     Coi = OCi
     If Oinvert_C = True Then OCi = OCf: OCf = Coi: Coi = OCi:     'inverte coluna
     If OdpL = True And Oquadante_L = True Then Op = 1: Loi = Loi + Lig: Coi = Coi + Zig

     If Oquadante_L = True Then
          If OQuatL <> "" And OQuatL < TLo And OQuatL > 0 Then OqL = OQuatL Else OqL = Cq
          OLf = OLi + ((OqL + 1) * Lig)    '----------------------------------( Linha de baixo )----------------------------
          OqL = OqL * Lig: Loi = OLi
          If Oinvq_L = True Then OLi = OLf: OLf = Loi: Loi = OLi: Lig = Lig * -1
          If Op = 0 Then Loi = Loi + Lig
     End If

     If Oquadante_C = True Then
          If OQuatC <> "" And OQuatC < Cq_O And OQuatC > 0 Then OqC = OQuatC Else OqC = Cq_O    ': MsgBox "Valo de quadrante  entre " & "1 " & TLo / 2
          ' If Op = 0 Then OLi = OLi - 1
          If Oinvq_C = True Then iCo = 1 Else iCqo = 0   '-<<----( controle invert )--
          'If iCo = 1 Then: Cio = Cfo: Cfo = Oci
          OCf = OCi + ((OqC + 1) * Zig)    '----------------------------------( coluna Esquerda )----------------------------
          OqC = OqC * Zig: Coi = OCi
          If iCqo = 1 Then OCi = OCf: OCf = Coi: Coi = OCi: Zig = Zig * -1
          If Op = 1 Then Coi = Coi + Zig
     End If
     '------------------------------extras
     If invert69 = True Then t69 = 1 Else t69 = 0
     If invertvalMax.Value <> "" Then tmax = invertvalMax.Value Else tmax = 0

     '-----------------------------( LOOP )----------------------------------------
     For w = 1 To K
          'Origem --( Leitura )--

          If Op = 0 Then GoSub OCoL: If T = 1 Then T = 0: GoSub OLin
          If Op = 1 Then GoSub OLin: If T = 1 Then T = 0: GoSub OCoL
          Ddo = Cells(Loi, Coi).Value2    '= w  '
          'Destino --(Escrita )--

          'If invertValTbx = True Then If IsNumeric(Ddo) And Ddo <> "" Then Ddo = invertVal(Ddo, t69, tmax)
          ' pp = 0
          '        If ReTr_M = False Then
          '        Else
          '            If ReTr_Ec = True Then If Ddo = Cells(Loi - 1, Coi - 1).Value2 Then pp = 1
          '            If ReTr_Mc = True Then If Ddo = Cells(Loi - 1, Coi).Value2 Then pp = 1
          '            If ReTr_Dc = True Then If Ddo = Cells(Loi - 1, Coi + 1).Value2 Then pp = 1
          '            If ReTr_Eb = True Then If Ddo = Cells(Loi + 1, Coi - 1).Value2 Then pp = 1
          '            If ReTr_Mb = True Then If Ddo = Cells(Loi + 1, Coi).Value2 Then pp = 1
          '            If ReTr_Db = True Then If Ddo = Cells(Loi + 1, Coi + 1).Value2 Then pp = 1
          '        End If
          '  If Ddo <> "" Then
          ' If pp = 0 Then
          If Dp = 0 Then GoSub DCoL: If T = 1 Then T = 0: GoSub DLin
          If Dp = 1 Then GoSub DLin: If T = 1 Then T = 0: GoSub DCoL
          'If IsNumeric(Ddo) And Ddo <> "" Then Ddo = Ddo + (Cdi - (Coi + dcdo))
          Cells(Ldi, cdi).Value2 = Ddo   'w
          ' End If
          '   End If
     Next
     ''-------------------------------------------------------------( Fim do loop )----
     GoTo Saida
     '----------------------------( ORIGEM )------------
OLin:
     If Op = 0 Then
          If T = 1 Then Loi = Loi + Lig
          If OZig_L = False Then
               If Loi = OLf Then
                    If Oquadante_L = True Then OLf = OLf + OqL: OLi = OLi + OqL
                    Loi = OLi + Lig
               End If
          Else
               If Loi = OLi Or Loi = OLf Then
                    If Oquadante_L = True Then OLf = OLf + OqL: OLi = OLi + OqL: Loi = Loi + OqL
                    Lig = Lig * -1: Loi = Loi + Lig
               End If
          End If
     End If

     If Op = 1 Then
          T = 0: Loi = Loi + Lig

          If OZig_L = False Then
               If Loi = OLf Then
                    T = 1
                    If Oquadante_L = True Then GoSub OCoL: If T = 1 Then OLf = OLf + OqL: OLi = OLi + OqL: T = 0
                    Loi = OLi + Lig
               End If
          Else

               If Loi = OLi Or Loi = OLf Then
                    T = 1
                    If Oquadante_L = True Then GoSub OCoL: If T = 1 Then OLf = OLf + OqL: OLi = OLi + OqL: T = 0: Loi = Loi + OqL
                    '  If OZig_LN = 4 Then
                    Lig = Lig * -1: Loi = Loi + Lig
                    '    Else
                    ' OZig_LN = OZig_LN + 1
                    '  End If
               End If
          End If
     End If
     Return

OCoL:          '-----------------------------------( Controle de colunas )----------------------------------
     T = 0: Coi = Coi + Zig
     If Op = 0 Then
          If OZig_C = False Then
               If Coi = OCf Then
                    T = 1
                    GoSub OLin:
                    Coi = OCi + Zig:
               End If
          Else
               If Coi = OCi Or Coi = OCf Then
                    T = 1
                    GoSub OLin:
                    Zig = Zig * -1: Coi = Coi + Zig:
               End If
          End If
     End If
     If Op = 1 Then  'If T = 1 Then Coi = Coi + Zig
          If OZig_C = False Then
               If Coi = OCf Then
                    Coi = OCi + Zig: T = 1
               End If
          Else
               If Coi = OCi Or Coi = OCf Then
                    Zig = Zig * -1: Coi = Coi + Zig: T = 1
               End If
          End If
     End If
     Return

     '------------------------------------------------------( DESTINO )-----------------------------------
DLin:
     If Dp = 0 Then
          If T = 1 Then Ldi = Ldi + Lag
          If DZig_L = False Then
               If Ldi = DLf Then
                    If Dquadante_L = True Then DLf = DLf + DqL: DLi = DLi + DqL
                    Ldi = DLi + Lag
               End If
          Else
               If Ldi = DLi Or Ldi = DLf Then
                    If Dquadante_L = True Then DLf = DLf + DqL: DLi = DLi + DqL: Ldi = Ldi + DqL
                    Lag = Lag * -1: Ldi = Ldi + Lag
               End If
          End If
     End If

     If Dp = 1 Then
          T = 0: Ldi = Ldi + Lag
          If DZig_L = False Then
               If Ldi = DLf Then
                    T = 1
                    If Dquadante_L = True Then GoSub DCoL: If T = 1 Then DLf = DLf + DqL: DLi = DLi + DqL: T = 0
                    Ldi = DLi + Lag
               End If
          Else
               If Ldi = DLi Or Ldi = DLf Then
                    T = 1
                    If Dquadante_L = True Then GoSub DCoL: If T = 1 Then DLf = DLf + DqL: DLi = DLi + DqL: T = 0: Ldi = Ldi + DqL
                    Lag = Lag * -1: Ldi = Ldi + Lag
               End If
          End If
     End If
     Return

DCoL:
     T = 0: cdi = cdi + Zag
     If Dp = 0 Then
          If DZig_C = False Then
               If cdi = Dcf Then
                    T = 1: GoSub DLin:
                    cdi = Dci + Zag:
               End If
          Else
               If cdi = Dci Or cdi = Dcf Then
                    T = 1
                    GoSub DLin:
                    Zag = -Zag: cdi = cdi + Zag:
               End If
          End If
     End If

     If Dp = 1 Then
          If DZig_C = False Then
               If cdi = Dcf Then
                    cdi = Dci + Zag: T = 1
               End If
          Else
               If cdi = Dci Or cdi = Dcf Then
                    Zag = -Zag: cdi = cdi + Zag: T = 1
               End If
          End If
     End If
     Return

     '***************************************Fim
Saida:
     Dim Dest As Variant

     If Para_2.Value = "" Then Dest = De_1.Value Else Dest = Para_2.Value
     If Selecsetrel = True And Para_2.Value = "" Then Dest = cs



     If Relocatd Then Cq = Cq - crit Else Cq = Cq + 3
     C = Cells(1, Cells(14, 2).Value2).Column
     If SetTud = True Then
          If Relocatd = False Then
               ColunO = Range(Cells(14, 1).Value2 & Li, Cells(15, 1).Value2 & lf).Value2
               Range(Cells(14, 2).Value2 & Li, Cells(15, 2).Value2 & lf).Value2 = ColunO
          End If
          ColunO = Range(Cells(Li, C), Cells(lf, C + Cq)).Value2
     Else
          ColunO = Range(Cells(Li, C + crit), Cells(lf, C + Cq)).Value2
     End If

     'Range(Cells(1, ti_o), ActiveCell.SpecialCells(xlLastCell)).ClearContents
     'Sheets("AUXIa").
     Range("A23", ActiveCell.SpecialCells(xlLastCell)).Clear    'ClearContents
     Sheets(PlanAtual).Select
     If SetTud Or Relocatd Then
          Call Colar_Setor(Dest, ColunO)
     Else
          CqD = Cq - crit
          Call SetorL(Dest)
          Call ColunasN(CqD)
          Range(Ci & Li, Cf & lf) = ColunO
     End If

     Final
End Sub
''-------------------------------------


but I still use "goto" a lot,
imagine a situation like this in a professional project "of course a professional project wouldn't have a code like that", and that has thousands of lines, changing the name of some word can be easy, but lack of functions, or differences in variables can be fatal.
many languages look like "C", but they are not called "C" language

Theo Gottwald

Quote from: Charles Pegge on September 08, 2022, 10:23:27 AM

I see multidimensional arrays are a problem when migrating code to o2, so I will be implementing it. I've got it for static arrays but not resolved with the redims.

If Macros work, you can still implement it like this "Under the hood" and give End users the normal "DIM [AT] (x,y,z) Syntax".
If these Arrays will be able to be re-dimed without losing content, it will be an advantage even over Powerbasic.
Where only 1 dimensiponal arrays can be REDIMED without losing content (and i am not sure this really works with all Datatypes).

Datatypes and Array are a critical Part of Basic and here is the Part where the Programmer can save a lot of time if the language designer invested a lot of time.


Zlatko Vid

#19
Quoteyou don't need to, my use of "Basic" is just as a hobby and I use vba even more,

so why you then moaning and complain ?
ahh you want to have code for easy translation ..give me a break :(

Also i don't see what is wrong with different syntax..every basic have something different.
but most of syntax is based on old MS QuickBasic.

QuoteI'm not even a professional programmer,
i am not proffesional programmer too..so what? ...
then stop talking about things you don't need ... ???

there is no need for any multi-dimensional arrays ..especially if that things broke other part of Oxygen basic
which work much better than is other compilers.

Eduardo Jorge

I think you are taking the matter personally because of your passion for "O2"
I said in general, there was only the case that the "o2" was multidimensional arrays.
you don't see in "c" people having to change dialects when going from a "C" to another "C".
and it's precisely because you don't use programming in a professional way that you don't see problems in these differences, so you should know that for me these differences aren't problematic either.
but, how are professionals going to adopt a language like that without any standard?
how can a company hire basic programmers, and when they work together, what if each one learned a different "basic"?

Seriously, you just saw this wrong in this code? lol
Simply put, that's all wrong, despite working.
but it was an example that in large and old projects there is always a section that no one wants to touch, but the project depends on it.
I ask you, in a case like this, is there a way to switch from one "basic" to another?

but well, this discussion won't even lead to anything,
as I said, it makes no difference to me, even without multidimensional arrays I'll continue using O2, I just pointed out a characteristic of "basic" and not exactly of "O2"

Eduardo Jorge

why am i contradictory?
you asked why people are leaving Powerbasic and going to freebasic, I talked about why, there is simply more baggage and tools.
yes I prefer the O2 too, but a lot of these people want something for work, so a good IDE and a form builder are important.
about AurelEdit, see that it is not announced as a standard ide, nor is it even announced for valid use with O2, it is a project that, as far as I know, was not even started for O2, but it has been adapted for O2 later, but even so, it is not announced next to the O2, only those who have been here the longest know that it exists as an "ide" for the O2.

if the "basic" were all the same, the tools could be reused, you could try different compilers, different ideas and all the form assemblers you have for Basic, and that would certainly make more people try to use O2

an example is thinbasic, it has more users than O2, it even has O2 built in, O2 is much faster than thinbasic, but what does thin basic have that o2 doesn't have?
tools ,
Of course, O2 doesn't have collaborators like thinbasic, but O2 also had many changes, some because Charles kept meeting demands, some interesting, others just for personal taste.
It works for me, it works for you too.
but is it for everyone?

looks like you're helping with the O2 documentation, it's also an important step, maybe the most important, and for that I also thank you, as well as charles "of course, more to charles , lol "
but seriously, this discussion with me is not going to lead anywhere, I'm just a fly here, my considerations are the same thing as nothing.
it would be valid if I had the ability to help in something and I was doing so, but as you can see, even in vba I'm incompetent, so you can ignore what I write

Zlatko Vid

Quoteabout AurelEdit, see that it is not announced as a standard ide, nor is it even announced for valid use with O2, it is a project that, as far as I know, was not even started for O2, but it has been adapted for O2 later, but even so, it is not announced next to the O2, only those who have been here the longest know that it exists as an "ide" for the O2.

first of all AurelEdit is completely written in o2..
it is made for Oxygen basic in first place and yes it is valid
what i can is to publish it on sourceForge
it is not "announced as a standard ide " probably because Charles have something different on his mind
and i never asked him to announce it as standard IDE for o2

I asked him many times why he don't include it under Scintilla projects?
but looks to me that he ignored that and leave old example called AsciEdit there ...hmm

for thinBasic ..it must be a joke ....did you recently visit tB forum
..there is maybe one or two members and one or two visitors

Eduardo Jorge

being written in O2 does not mean that it was written to be used with O2, the O2 itself was initially made in freebasic, so I prefer o2, should I use freebasic just because o2 was made with it?
after it was completely compiled by o2 itself.
ok thinbasic has been weak lately, but tell me which basic language is booming, from what I saw there was even a recent update in the "thinAir" ide, (at this moment 245 visitors), particularly I don't use it, I downloaded it but I don't use it, I also downloaded it the freebasic, but I left it aside.
was AurelEdit made by you? I didn't even know, it's getting better.

Zlatko Vid


Bernard Kunzy

Eduardo,

I agree, that there is no standard BASIC syntax, and this won't help to gain new users, except in the hobbyist sphere.



Charles Pegge

I think a standard BASIC should definitely include gosub and goto. They are most valuable for occasional use, o2 won't be dropping them any time soon.

I've now coded both static and redimable multidimensional arrays but it will need a period of careful testing. We can set the index-base and select column-major order as in PowerBasic, or row-major order (default) as in C and FreeBasic.

Eduardo Jorge

Charles
I think people think that goto and gosub will bring back the spaghetti code.
forget that at the time it was the only way to have independent sections, there is still the case that nowadays the line number is no longer used to indicate where it is jumping.
occasionally they help to have faster and smaller code, in my case I prefer using conditional jumps than using conditional loops.
gosub sometimes helps me to define the logic of what I'm writing but then I write without it.

well remembered on the basis of multidimensional matrices, VB'a also uses column order,
having the selection option will help you migrate projects

but seriously, this default in basic made such a mess that it was practically impossible to migrate between basic
see the simple case of "IF", which code does not have "IF"
in one there is no "then", each one has a way to end "End, endif, end if", I think I've seen one there that is called basic but uses ")" to end the "IF"
has its own MS that made a kind of successor of VB , but uses "endfor" instead of "next"

it would be good to have an agreement on the syntax of the base between so many developers, what could be added to standardize the various existing basics would bring a lot of strength to the language, it would help even those who market it,
like, the ones that use the " if " without the " then ", if you added the option to use the " then " for example, whoever took the " Goto " put it for default reason " uses who wants ",
you have done a great job in this regard, it's a pity and the others just think about their personal taste, or their pocket and create a dialect that those who adopt cannot easily go to another one.

Zlatko Vid

what you talking about ?

then exists in o2 keywords....but i hate to use it
it sucks if you ask me

every REAL language have GOTO
GOSUB is nice and o2 have it ...so please stop "with wall of text about nothing"

then? OMG

Eduardo Jorge

the subject is standard from "BASIC",
it's not what the O2 has or doesn't have, nor what you or I like to use.

on my shelf there are 2 books that I thought would be a bad read, so I ignored them, and never picked them up to read, you have the right to do the same about what I write.