ERROR
This error occurs when using the request Palette.MakeFromFile:Assertion "ValidPalette object" failed at line 447 of file "..\symwin\palette.c"
The specified ODB file does not have a palette as the first object in the file, which is required by the Palette.MakeFromFile request.
Code:
'-- This sample Avenue code demonstrates how to use the
'-- Palette.MakeFromFile request with ODB files that have
'-- palettes as the first object.
"$AVHOME/symbols".asfilename.setcwd
newFileName = filedialog.show("*.avp","ArcView Palette Files (*.avp)","")
if(newFileName = nil) then
return nil
end
testodb = odb.open(newFileName)
firstobject = testodb.get(0)
if(firstobject.is(Palette)) then
newPalette = Palette.MakeFromFile(newFileName)
end
Article ID:000002510
Get help from ArcGIS experts
Download the Esri Support App