AutoCAD Tables

AutoCAD Tables

Anonymous
Not applicable
345 Views
2 Replies
Message 1 of 3

AutoCAD Tables

Anonymous
Not applicable
Hi all
I'm trying to create a simple table with:
--------------------------------------------
Sub Example_AddTable()
' This example adds a table in model space

Dim pt(2) As Double
Dim Tabela As AcadTable
Dim Numlinhas, Numcolunas As Integer
Dim Lcounas As Double
Dim pStr As String


Numlinhas = 3
Numcolunas = 7
Lcounas = 7

Set Tabela = ThisDrawing.ModelSpace.AddTable(pt, Numlinhas, Numcolunas,
10, Lcounas)
pStr = "121"
Tabela.SetText (1, 1, pStr)
ZoomExtents

End Sub
--------------------------------------------
create is OK but when I write de line
Tabela.setText (1,1, Pstr)
I get the compile error:
Expected: =


????
Apreciate Any help.

Thanks
0 Likes
346 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable
Remove the parentheses.

Joe
--

"Luís Laíns "
<=?UTF-8?Q?Lu=C3=ADs_La=C3=ADns_?=> wrote in message
news:4923634@discussion.autodesk.com...
Hi all
I'm trying to create a simple table with:
--------------------------------------------
Sub Example_AddTable()
' This example adds a table in model space

Dim pt(2) As Double
Dim Tabela As AcadTable
Dim Numlinhas, Numcolunas As Integer
Dim Lcounas As Double
Dim pStr As String


Numlinhas = 3
Numcolunas = 7
Lcounas = 7

Set Tabela = ThisDrawing.ModelSpace.AddTable(pt, Numlinhas, Numcolunas,
10, Lcounas)
pStr = "121"
Tabela.SetText (1, 1, pStr)
ZoomExtents

End Sub
--------------------------------------------
create is OK but when I write de line
Tabela.setText (1,1, Pstr)
I get the compile error:
Expected: =


????
Apreciate Any help.

Thanks
0 Likes
Message 3 of 3

Anonymous
Not applicable
Thanks
Now it works fine

"Joe Sutphin" wrote in message
news:4923732@discussion.autodesk.com...
Remove the parentheses.

Joe
--

"Luís Laíns "
<=?UTF-8?Q?Lu=C3=ADs_La=C3=ADns_?=> wrote in message
news:4923634@discussion.autodesk.com...
Hi all
I'm trying to create a simple table with:
--------------------------------------------
Sub Example_AddTable()
' This example adds a table in model space

Dim pt(2) As Double
Dim Tabela As AcadTable
Dim Numlinhas, Numcolunas As Integer
Dim Lcounas As Double
Dim pStr As String


Numlinhas = 3
Numcolunas = 7
Lcounas = 7

Set Tabela = ThisDrawing.ModelSpace.AddTable(pt, Numlinhas, Numcolunas,
10, Lcounas)
pStr = "121"
Tabela.SetText (1, 1, pStr)
ZoomExtents

End Sub
--------------------------------------------
create is OK but when I write de line
Tabela.setText (1,1, Pstr)
I get the compile error:
Expected: =


????
Apreciate Any help.

Thanks
0 Likes