Delphi 2 & 3 - INT64

Started by DanaPaul, 15 May '03 - 09:23

fredvs

Hi DP.

What is this option "tools-exception...".

I have noted that with my d3, i cant run and debug big apps.
I have to compiled it, close delphi, run the exe, see the debug then, cose the app, reload delphi, change the wrong code, etc...

DanaPaul


QuoteWhat is this option "tools-exception...".

When running apps in the Delphi IDE this option controls whether all Exceptions stop and display a dialog box, or only untrapped exceptions.  The latter being normal behavour when the app is compiled and run outside of the IDE.

QuoteI have noted that with my d3, i cant run and debug big apps.
I have to compiled it, close delphi, run the exe, see the debug then, cose the app, reload delphi, change the wrong code, etc...

This is a seriuos issue.  I'd solve this, or make smaller apps.

fredvs

Hi dp

QuoteWhen running apps in the Delphi IDE this option controls whether all Exceptions stop and display a dialog box, or only untrapped exceptions.  The latter being normal behavour when the app is compiled and run outside of the IDE.


OK perfect, i agree, but please say me where i can change that option with delphi, where is that checkbox...

QuoteI'd solve this,


Hummm, yes, congratulation, and how... :-/

DanaPaul


Quotei dont see the option, : Tools- Exception... in my Delphi 3 Client-server version even not in my Delphi 2 version...

Ummm, how 'bout "Break On Exception" in D2 :)

DanaPaul


QuoteHummm, yes, congratulation, and how... :-/

Rebuild the app, unit by unit, component by component, and test[/u] it every step of the way.  This will isolate the probelm area.

fredvs

#55
Thanks DP

I agree totaly with you.

I dont know if you have test the last release of MixK.
http://members.lycos.co.uk/mixk/

It is compiled with one of your bass.pas, basswma.pas, basscd.pas headers (20/05/03).

On my pc, i dont have find any more exceptions, it is only if i recompile it with your new release that i get this "Handle is not valid" messages...

But perhaps on your pc, you get also those "invalid handle" messages with your old header...

DanaPaul


QuoteOn my pc, i dont have find any more exceptions, it is only with your new release that i get this "Handle is not valid" messages...

Then I think that we agree to disagree :)

QuoteBut perhaps on your pc, you get also those "invalid handle" messages with your old header...

Nope, sorry.  Negative answer for both headers, new and old. :)

DanaPaul

However, I can probably tell you where your ap is having a problem (you can't debug so, in that vein...)

fChannel := BASS_StreamCreateFile()
if fChannel = 0 then
  fChannel := BASS_WMA_StreamCreateFile()
if fChannel = 0 then
  fChannel := BASS_MusicLoad()

Neither BASS_WMA_StreamCreateFile nor BASS_MusicLoad will execute if Bass returns a nil result for BASS_StreamCreateFile.  IE: The media format wasn't supported.

Make sense? :)

fredvs

Hi DP
QuoteNope, sorry.  Negative answer for both headers, new and old.  

Humm, are you token about MixK or your header on your pc ( the relase on the net is with your old release just before you have changed bassdllload into loadbassdll)?


fredvs

#59
Hi DP

QuotefChannel := BASS_StreamCreateFile()
if fChannel = 0 then
 fChannel := BASS_WMA_StreamCreateFile()
if fChannel = 0 then
 fChannel := BASS_MusicLoad()

It is exactly what i use in my app ("fChannel" is "Str").
What have i to change and how can you see the source ?

DanaPaul


QuoteHumm, are you token about MixK or your header on your pc ( the relase on the net is with your old release just before you have changed bassdllload into loadbassdll)?
Reference to the header files.

Fred, in all honesty, until you are able to debug your app all discussions about headers and apps are, well... pointless. Rebuild from scratch and go forth :)

DanaPaul


QuoteIt is exactly what i use in my app ("fChannel" is "Str").
What have i to change and how can you see the source ?

I can't see your source, I guessed :)

Try
  fChannel := BASS_StreamCreateFile();
Except
  on EBass do begin
    Try
      fChannel := BASS_WMA_StreamCreateFile();
    Except
      on EBass do
        fChannel := BASS_MusicLoad();
      else raise;
      end;
    end;
  else raise;
  end;

fredvs

Hi DP

QuoteFred, in all honesty, until you are able to debug your app all discussions about headers

You right, but i can debug my apps, i compile it with the integrated debuging option, and i run the app with the exe then i get my errors.

When i dont find any more error messages, i recompile it without integrated debugging (less Kb) and i give the app for beta test.

I only wanted to say you that all your bass.pas header where perfect, very usefull to find bugs with the integrated debugger, and at one moment, it was perfect, no more errors, but with your very last release, i have get problems.

I m very sorry to have spend your time and your brain.

Excuse-me

DanaPaul


Quotei can debug my apps, i compile it with the integrated debuging option, and i run the app with the exe then i get my errors.

QQps, I stand corrected.  My appologies :)

DanaPaul

Fred, you have mail.  Attached is the header file that fixes Get/Set Position and doesn't have (exception) full error checking (you can do this on your own.)

fredvs

#65
Hi DP.

My appologies, you where right and your last header is perfect for debugging.

Thanks to your last header i have learned lots of things about bass that Ian dont say to us  :o:

For example : Dont try to BASS_ChannelGetLevel(str) if your stream is Paused, you will raise a error, dont try to BASS_ChannelSetAttributes(str) if str = 0, etc...

Thanks a lot  :-*, your header is realy a must. (and i have to re-check my 60.000 lines, no music this we :-/)  




DanaPaul

Thanks to Fred's very helpful suggestion, I have added a more descriptive message string to the more generic error messages.  "Unknown error at : StreamCreate".  This will be very useful if/when nesting calls.  Some of these error strings have already been posted.  The remainder will be a work in progress.

Shiny happy people :)

fredvs

#67
Hi DP

Thanks a lot for your great job.

And if gives a  bemol to Bass, some of the bass-delphi samples raise hidden error (sorry Ian...), if compiled with your header.

Example :
Quotestr := BASS_StreamCreateFile();
          if str = 0 then BASS_WMA_StreamCreateFile();
          if str =0 then BASS_MusicLoad();
Raise a exception with your header (of course i have changed it with a try...expect code.)

DanaPaul

#68
Well, the error is no longer hidden if it is "raised", eh?:)

Every developer has decisions to make as to exactly how they wish to handle very specific situations.  However, any situation that has an application plowing along with a nil stream, or nil channel is a bad situation.

Back to multiple instances and creating a second copy of the Bass library on the fly. Not all developers will stick to creating a Temp file, nor will all developers park files loosely on the disk.  Some may unpack files from a *.cab, and/or make permanent copies once installed.

Quick Reply

Warning: this topic has not been posted in for at least 365 days.
Unless you're sure you want to reply, please consider starting a new topic.

Name:
Email:
Verification:
Please leave this box empty:
Type the letters shown in the picture
Listen to the letters / Request another image

Type the letters shown in the picture:
Shortcuts: ALT+S post or ALT+P preview