Dear group
I am unable to solve the problem with the following code and wondering if anybody can
see the problem. It is on line 74 and I have marked it. ' invalid style value 0
Thanks for any advice you may have.
Include "mapbasic.def"
Declare Sub StyleSizeChange
Declare Sub Main
Global num as integer
Sub Main
Dialog
Title "User Info"
position 5, 10
Control StaticText
Title "Enter Point Size"
Control EditText
Into num
ID 1
Position 100, 10 Width 30
Control OKButton
Control CancelButton
call stylesizechange
End Sub
Sub StyleSizeChange
note num
Dim sFontname as String, use as String
Dim num as Integer
Dim nColor, nFontstyle, frotation, ishape as Integer
Dim osel as Object
Dim SymStyle as Symbol
Dim slayname as String, I as Integer
sLayName = LayerInfo(FrontWindow(),i,LAYER_INFO_NAME)
oSel = Selection.obj
If ObjectInfo(oSel, OBJ_INFO_TYPE) = OBJ_TYPE_POINT Then
SymStyle = ObjectInfo(oSel, OBJ_INFO_SYMBOL)
Set Style Symbol SymStyle
note Symstyle
Else
GOTO ON_Error
End if
sFontName = StyleAttr(currentsymbol(), SYMBOL_FONT_NAME)
nColor = StyleAttr(currentsymbol(), SYMBOL_COLOR)
iShape = StyleAttr(currentsymbol(), SYMBOL_CODE)
note ncolor
note sFontname
note ishape
Set Map
Layer 1 Display Global
Global Symbol MakeFontSymbol (ishape,ncolor,num,sfontname,1,0) 'line 74 invalid
style value 0
Exit Sub
ON_Error:
Note "Not point data"
Resume Next
End Sub
Daniel York
MapInfo Specialist
Information Team
Corporate Development
South Tyneside Council
Town Hall and Civic Offices
Westoe Road
South Shields
Tyne & Wear
NE33 2RL
0191 4247558
************************************************************************************************
Please do not print this e-mail if you can help it - and help protect the environment.
************************************************************************************************
This Message may contain confidential information and is protected by copyright.
If you receive it in error please notify us and delete it without making use of or
copying it.
The addressee and other employees within the Council may read and copy any e-mail
reply to this message and other e-mails you send to us.
Whilst we use virus checking procedures we accept no liability for viruses and
recipients
must rely on their own virus checking procedures.
************************************************************************************************
The Council's web site address is www.southtyneside.info
South Tyneside Business Week
7-13th July 2004, Bents Park, South Shields
www.southtyneside.info/businessweek
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 12592