0

I am using TJvTransparentForm (from Project JEDI) on one of my forms. I am also using AlphaControls for my entire project. The problem is, TJvTransparentForm does not work well with the unit "acPNG" from AlphaControls. I need to use the regular PNG class (?).

I tried using an UnregisterClass routine (or something, dont remember what it was), and that didn't do it.

I also tried removing AlphaControls from my project, add the TImage, reenable AC, but it still generates the acPNG in the Uses clause.

What can I do? Thanks! - Jeff

Jeff
  • 12,085
  • 12
  • 82
  • 152

2 Answers2

3
  1. If you mean - to exclude a unit, automatically included into "uses" at design time, when a component was droped on a form. Then the only way - create this component at run time.
  2. If the unit was indirectly used by some linked library, then you cannot to exclude this unit. Or ... do not use the library.
da-soft
  • 7,670
  • 28
  • 36
  • It automatically gets added whenever I have a TImage on my form. The TPNGImage is replaced with TPNGGraphic, which is what I am trying to prevent. – Jeff Feb 03 '11 at 20:18
  • Also, not using the library is not an option. And since I am storing my image in a TPicture at design time, I cant create the image at runtime, unless I load from a file I guess. – Jeff Feb 03 '11 at 20:20
  • @Jeff: You can load it from the .exe's resources. – Andreas Rejbrand Feb 03 '11 at 20:42
  • @Jeff It's almost always better to store such things as resources than in the .dfm. Once they get into the .dfm it can be hard to manage them. – David Heffernan Feb 03 '11 at 20:54
  • well, I tried using my own method 2 (Remove package, add it back), apparently I just had to add back the pngimage unit first. Anyways, this gets market as answer, as it gives good suggestions! – Jeff Feb 03 '11 at 21:00
0

Another option is moved the desired unit after the other

Cheers

APZ28
  • 997
  • 5
  • 4
  • I already tried that, it didn't work, weird enough. I could try again though, will report back when I get home :) – Jeff Feb 04 '11 at 07:37