Click here to Skip to main content
15,902,635 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi, I have a small project in VS2010. With my RDLC Report, I am using Image Control called - Image4 and I added 3 Images to my resource file [resx]

C#
static Reflection.Assembly pxAssembly = Reflection.Assembly.GetExecutingAssembly();
static String pxResName = pxAssembly.GetName().Name + ".ImageResources";
static ResourceManager s_pxResourceManager = (new Resources.ResourceManager(pxResName,pxAssembly));
static System.Drawing.Image MyLogoImg1 = (safe_cast<System.Drawing.Image>(s_pxResourceManager.GetObject("Logo_S1")));
static System.Drawing.Image MyLogoImg2 = (safe_cast<System.Drawing.Image>(s_pxResourceManager.GetObject("Logo_P1")));
static System.Drawing.Image MyLogoImg3 = (safe_cast<System.Drawing.Image>(s_pxResourceManager.GetObject("Logo_C1")));


I wish to change the Image4 according to my field value during runtime...Is it possible?

C#
Image4.Value=IIf(First(Fields!company_name.Value, "DataSet1").ToString().Trim().Contains("C.N"), ? , ? )

Thanks For The Helps
Posted

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