Click here to Skip to main content
15,878,048 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello everybody. I have a problem with allocating system::drawing::bitmap in function.

void image_warp::preview(Bitmap ^ newpic)
        delete newpic;
    newpic=gcnew Bitmap(pic_processed);

bitmap is allocated and "usable" in function but when app skips back to main it is not allocated anymore. Of course I would use "&" in simpler times but seem that it does not work for managed pointers. I tried some google-ing but struggled to get any help. I know that the solution is simple but I have no idea what the correct syntax is. Thanks in advance

1 solution

See here[^]; your call does not seem to be the correct syntax.
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900