I recently work on a rb to xojo project and i have a lot of headache with the UnsupportedFormatException and the fun part is that if i press on it it gives me ErrorNumber 0, message nothing, Reason nothing, so very helpful.
the code comes like this :
[code] if clinicSet <> nil then
while not(clinicSet.eof)
admnb = clinicSet.field(“nbadm”).integerValue
cliPictFile = clinicSet.field("headername").TextValue
if not(app.SFolderItem.child("cliniques").exists) then
app.SFolderItem.child("cliniques").createAsFolder
end if
[b]if app.SFolderItem.child("cliniques").child(cliPictFile).Exists then[/b] // here is where the exception stops the code and shows .
cliPict = Picture.Open(app.SFolderItem.child("cliniques").child(cliPictFile))[/code]
now if i check the cliPictFile = clinicSet.field(“headername”).TextValue it gives me nothing, so the record was empty, now , logically it is that app.SFolderItem.child(“cliniques”).child(cliPictFile).Exists will be not true because the cliPictFile is nil but now how i can step over this and make the code working ?
i think i`m repeating myself but it would be nice to show at least some info when i press in the debugger on that error , not just to throw it like that .
I recently work on a rb to xojo project and i have a lot of headache with the UnsupportedFormatException and the fun part is that if i press on it it gives me ErrorNumber 0, message nothing, Reason nothing, so very helpful.
the code comes like this :
[code] if clinicSet <> nil then
while not(clinicSet.eof)
admnb = clinicSet.field(“nbadm”).integerValue
cliPictFile = clinicSet.field("headername").TextValue
if not(app.SFolderItem.child("cliniques").exists) then
app.SFolderItem.child("cliniques").createAsFolder
end if
[b]if app.SFolderItem.child("cliniques").child(cliPictFile).Exists then[/b] // here is where the exception stops the code and shows .
cliPict = Picture.Open(app.SFolderItem.child("cliniques").child(cliPictFile))[/code]
now if i check the cliPictFile = clinicSet.field(“headername”).TextValue it gives me nothing, so the record was empty, now , logically it is that app.SFolderItem.child(“cliniques”).child(cliPictFile).Exists will be not true because the cliPictFile is nil but now how i can step over this and make the code working ?
i think i`m repeating myself but it would be nice to show at least some info when i press in the debugger on that error , not just to throw it like that .
[/quote]
[quote]Cross-Platform Formats
These formats are cross-platform: SaveAsPNG, SaveAsJPEG, SaveAsWindowsBMP, SaveAsGIF, SaveAsTIFF. On Windows, these formats require GDI+; if it GDI+ is not available, then QuickTime will be used. If neither QuickTime or GDI+ is available then only BMP is supported on Windows.
Unrecognized formats or formats not supported for the built target will result in an UnsupportedFormatException. The Message property of the exception will contain additional information about what went wrong.
[/quote]