Search Results

Search found 56 results on 3 pages for 'imagelist'.

Page 1/3 | 1 2 3  | Next Page >

  • VB6 ImageList Frm Code Generation

    - by DAC
    Note: This is probably a shot in the dark, and its purely out of curiosity that I'm asking. When using the ImageList control from the Microsoft Common Control lib (mscomctl.ocx) I have found that VB6 generates FRM code that doesn't resolve to real property/method names and I am curious as to how the resolution is made. An example of the generated FRM code is given below with an ImageList containing 3 images: Begin MSComctlLib.ImageList ImageList1 BackColor = -2147483643 ImageWidth = 100 ImageHeight = 45 MaskColor = 12632256 BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} NumListImages = 3 BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} Picture = "Form1.frx":0054 Key = "" EndProperty BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} Picture = "Form1.frx":3562 Key = "" EndProperty BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} Picture = "Form1.frx":6A70 Key = "" EndProperty EndProperty End From my experience, a BeginProperty tag typically means a compound property (an object) is being assigned to, such as the Font object of most controls, for example: Begin VB.Form Form1 Caption = "Form1" ClientHeight = 10950 ClientLeft = 60 ClientTop = 450 ClientWidth = 7215 BeginProperty Font Name = "MS Serif" Size = 8.25 Charset = 0 Weight = 400 Underline = 0 'False Italic = -1 'True Strikethrough = 0 'False EndProperty End Which can be easily seen to resolve to VB.Form.Font.<Property Name>. With ImageList, there is no property called Images. The GUID associated with property Images indicates type ListImages which implements interface IImages. This type makes sense, as the ImageList control has a property called ListImages which is of type IImages. Secondly, properties ListImage1, ListImage2 and ListImage3 don't exist on type IImages, but the GUID associated with these properties indicates type ListImage which implements interface IImage. This type also makes sense, as IImages is in fact a collection of IImage. What doesn't make sense to me is how VB6 makes these associations. How does VB6 know to make the association between the name Images - ListImages purely because of an associated type (provided by the GUID) - perhaps because it's the only property of that type? Secondly, how does it resolve ListImage1, ListImage2 and ListImage3 into additions to the collection IImages, and does it use the Add method? Or perhaps the ControlDefault property? Perhaps VB6 has specific knowledge of this control and no logical resolution exists?

    Read the article

  • (C#, WinForms) How to assign an accessibility attribute to an image in ImageList

    - by Yaniv
    Hi all, I'm trying to find a way to make a screen-reader (like JAWS) to read out loud some text that is assigned to images in ImageList. In other controls (like PushButton) there is "AccessibleName" property, that when contains text, it's being read by JAWS. the ImageList consists of four icons that represent priorities, and no text is displayed near them. Is it possible to do it? Can you think of any other creative solution? Thanks, Yaniv.

    Read the article

  • Lack of ImageList in MenuStrip and performance issues

    - by Ivan
    MenuStrip doesn't support using ImageList images. What are performance issues of this? Are there chances of using too much GDI resources and slow-downs? How many items should be considered acceptable, after which one should implement custom control that draws images from ImageList?

    Read the article

  • Mostrar Imagenes en ListView utilizando ImageList WinForms

    - by Jason Ulloa
    El día de hoy veremos como trabajar con los controles ListView e Imagelist de WindowsForms para poder leer y mostrar una serie de imágenes. Antes de ello debo decir que pueden existir otras formas de mostrar imagenes que solo requieren un control por ejemplo con un Gridview pero eso será en otro post, ahora nos centraremos en la forma de realizarlo con los controles antes mencionados. Lo primero que haremos será crear un nuevo proyecto de windows forms, en mi caso utilizando C#, luego agregaremos un Control ImageList. Este control será el que utilicemos para almacenar todas las imágenes una vez que las hemos leído. Si revisamos el control, veremos que tenemos la opción de agregar la imágenes mediante el diseñador, es decir podemos seleccionarlas manualmente o bien agregarlas mediante código que será lo que haremos. Lo segundo será agregar un control ListView al Formulario, este será el encargado de mostrar las imagenes, eso sí, por ahora será solo mostrarlas no tendrá otras funcionalidades. Ahora, vamos al codeBehind y en el Evento Load del form empezaremos a codificar: Lo primero será, crear una nueva variable derivando DirectoryInfo, a la cual le indicaremos la ruta de nuestra carpeta de imágenes. En nuestro ejemplo utilizamos Application.StartUpPath para indicarle que vamos a buscar en nuestro mismo proyecto (en carpeta debug por el momento). DirectoryInfo dir = new DirectoryInfo(Application.StartupPath + @"\images");   Una vez que hemos creado la referencia a la ruta, utilizaremos un for para obtener todas la imágenes que se encuentren dentro del Folder que indicamos, para luego agregarlas al imagelist y empezar a crear nuestra nueva colección. foreach (FileInfo file in dir.GetFiles()) { try { this.imageList1.Images.Add(Image.FromFile(file.FullName)); }   catch { Console.WriteLine("No es un archivo de imagen"); } }   Una vez, que hemos llenado nuestro ImageList, entonces asignaremos al ListView sus propiedades, para definir la forma en que las imágenes se mostrarán. Un aspecto a tomar en cuenta acá será la propiedad ImageSize ya que está será la que definirá el tamaño que tendrán las imágenes en el ListView cuando sean mostradas. this.listView1.View = View.LargeIcon;   this.imageList1.ImageSize = new Size(120, 100);   this.listView1.LargeImageList = this.imageList1;   Por último y con ayuda de otro for vamos a recorrer cada uno de los elementos que ahora posee nuestro ImageList y lo agregaremos al ListView para mostrarlo for (int j = 0; j < this.imageList1.Images.Count; j++) { ListViewItem item = new ListViewItem();   item.ImageIndex = j;   this.listView1.Items.Add(item); } Como vemos, a pesar de que utilizamos dos controles distintos es realmente sencillo  mostrar la imagenes en el ListView al final el control ImageList, solo funciona como un “puente” que nos permite leer la imagenes para luego mostrarlas en otro control. Para terminar, los proyectos de ejemplo: C# VB

    Read the article

  • Delphi - Populate an imagelist with icons at runtime 'destroys' transparency

    - by ben
    Hi again, I've spended hours for this (simple) one and don't find a solution :/ I'm using D7 and the TImageList. The ImageList is assigned to a toolbar. When I populate the ImageList at designtime, the icons (with partial transparency) are looking fine. But I need to populate it at runtime, and when I do this the icons are looking pretty shitty - complete loose of the partial transparency. I just tried to load the icons from a .res file - with the same result. I've tried third party image lists also without success. I have no clue what I could do :/ Thanks 2 all ;) edit: To be honest I dont know exactly whats going on. Alpha blending is the correkt term... Here are 2 screenies: Icon added at designtime: Icon added at runtime: Your comment that alpha blending is not supported just brought the solution: I've edited the image in an editor and removed the "alpha blended" pixels - and now it looks fine. But its still strange that the icons look other when added at runtime instead of designtime. If you (or somebody else ;) can explain it, I would be happy ;) thanks for you support!

    Read the article

  • Delphi, ImageList that handles BOTH png and bitmaps.

    - by michal
    Recently I've found TPngImageList component ( http://cc.embarcadero.com/Item/26127 ) which is very good, but it handles only png images ... I'd like to have some imagelist that allows combining of pngimages with bitmaps, as I'm using lots of bitmaps, and I do not want to spend coming week converting those bitmaps to pngs, yet I want to use be able to add PNG images for coming features ... So far I used to convert the PNGs to bitmaps using GIMP if I wasn't able to find any replacement.

    Read the article

  • handling ImageList with windows hooks

    - by user337309
    Hi, I am programming an application that can catching the information about the screen items by Hooks Now I am trying to get the information of the ImageList when I pass them by mouse, "I want to know the name of the item" how can i do this? Thank you.

    Read the article

  • Related to imagelist

    - by user309063
    dear sir, I m working in delphi-2010 i have a imaglist,in which i have added some .png images. and i have also picture for showing the picture from imagelist. i want to show the picture on picture box from imagelist. i wrote the following code,but here addImage(,) takes 2 argument one is Values:TCustomImagelist and another is Index of Image how i identify the value of customimagelist. image1.Picture:=imagelist1.AddImage( , );

    Read the article

  • How add imagelist in Infragistics.Win.UltraWinGrid ?

    - by Nakul Chaudhary
    In past, I am using Listview and using below code can show a particular image for particular memId. But now I need to replace listview with Infragistics.Win.UltraWinGrid problem arise how i show image for ultragrid. For Each LItem As ListViewItem In Me.dvParticipants.Items If CInt(LItem.SubItems(2).Text) = memid Then LItem.ImageIndex = imageindex End If Next Please suggest.

    Read the article

  • Delphi Imagelist: Load icons with ResourceLoad from a .res

    - by ben
    Hi guys, I', trying to load an icon from a res file into an image list. I created the res file with the delphi ImageEditor. And this way I'm trying to load the icon: //if ImageList1.ResourceLoad(rtIcon, 'TEXT_BOLD', clWhite) then if imagelist1.GetResource(rtIcon, 'TEXT_BOLD', 0, [lrDefaultColor], clRed) then showmessage('loaded') else showmessage('not loaded'); Both ways doesn't work. Any ideas? Thanks!

    Read the article

  • Listview icons show up blurry (C#)

    - by Balk
    I'm attempting to display a "LargeIcon" view in a listview control, however the images I specify are blurry. This is what I have so far: The .png files are 48x48 and that's what I have it set to display at in the ImageList properties. There's one thing that I've noticed (which is probably the cause) but I don't know how to change it. Inside the "Images Collection Editor" where you choose what images you want for the ImageList control, it looks like it's setting the wrong size for each image. As you can see the "PhysicalDimension" and the "Size" is set to 16x16 and not abled to be manipulated. Does anyone have any ideas? Many thanks!

    Read the article

  • How to implement an ListView containing images with style

    - by Alexandergre
    So I have been working with an app where I need to show the thumbnails as clean and use the space in a good way. Style A is my work until now. What I want to accomplish is something like style B. no titles and use the space in a good way. I need help with this. there was no tutorial on the net. Is ListView able to do such a thing? or shall I make picturesboxes and put them in a scrollview? the code: private void button1_Click(object sender, EventArgs e) { ImageList myImageList = new ImageList(); myImageList.ImageSize = new Size(48, 48); DirectoryInfo dir = new DirectoryInfo(@"C:\img"); foreach (FileInfo file in dir.GetFiles()) { try { myImageList.Images.Add(Image.FromFile(file.FullName)); } catch { Console.WriteLine("This is not an image file"); } } myListView.LargeImageList = myImageList; myListView.Items.Add("a", 0); myListView.Items.Add("b", 1); myListView.Items.Add("c", 2);

    Read the article

  • How to Export Images from an Image List in VS2005?

    - by cbuck12000
    Using Visual Studio 2005, is there a way to export the images in an Image List to individual files on my PC? Using the IDE, I select the Image List and view its properties. In the "Images" property, I launch the Images Collection Editor dialog. I can only add and remove images, but I cannot find a way to export an image that is already in the list. Why? The developer who made the original list has left our company and I need the images for an ASP.NET application (will convert to .jpeg). Thank you for the help!

    Read the article

  • Trying to Create a ToolBar with an ImageList, not working.

    - by blaquee
    Im trying to get my toolbar to work, with an imagelist. The images are png's and are individual So i was adding them in the ImageList in succession. But it wasnt working, Here is the code to add the Image to the ImageList HIMAGELIST CreateToolBarImages( HINSTANCE hInst) { HIMAGELIST v_ImageList = NULL; //IMAGE_LIST v_Img; HICON hIcon; HBITMAP hBit; COLORMAP cMap; COLORREF fromColor = RGB( 0,0,0 ); InitCommonControls(); v_ImageList = ImageList_Create( 32,32, ILC_MASK, 1,1 ); cMap.from = fromColor; cMap.to = ::GetSysColor ( COLOR_BTNFACE ); hBit = CreateMappedBitmap( hInst, IDB_CONSOLE, 0, &cMap, 1 ); //hBit = LoadBitmap( hInst, MAKEINTRESOURCE(IDB_CONSOLE) ); consoleImg = ImageList_Add( v_ImageList, hBit, 0 ); if( consoleImg == -1 ) return NULL; DeleteObject( hBit ); Then i create The ToolBar, but it fails at the Image function. HWND CreateToolBarButton( HWND hWndParent ) { const int ImageID = 0; const int numB = 1; COLORREF iColor; HWND hToolBar = CreateWindowEx( 0, TOOLBARCLASSNAME, NULL, WS_CHILD |TBSTYLE_LIST |TBSTYLE_FLAT | WS_VISIBLE, 0,0,0,0, hWndParent, NULL, g_hInst, NULL ); if( hToolBar == NULL ) return NULL; HIMAGELIST ImgList = CreateToolBarImages ( g_hInst); if( ImgList == NULL ) MessageBox( hWndParent, L"No Tool Images", L"BOB", MB_OK ); return NULL; Is there something im missing? or not doing?

    Read the article

  • Cannot delete an image file that is shown in a listview

    - by Enrico
    Hello all, In my listview I show thumbnails of small images in a certain folder. I setup the listview as follows: var imageList = new ImageList(); foreach (var fileInfo in dir.GetFiles()) { try { var image = Image.FromFile(fileInfo.FullName); imageList.Images.Add(image); } catch { Console.WriteLine("error"); } } listView.View = View.LargeIcon; imageList.ImageSize = new Size(64, 64); listView.LargeImageList = imageList; for (int j = 0; j < imageList.Images.Count; j++) { var item = new ListViewItem {ImageIndex = j, Text = "blabla"}; listView.Items.Add(item); } The user can rightclick on an image in the listview to remove it. I remove it from the listview and then I want to delete this image from the folder. Now I get the error that the file is in use. Of course this is logical since the imagelist is using the file. I tried to first remove the image from the imagelist, but I keep on having the file lock. Can somebody tell me what I am doing wrong? Thanks!

    Read the article

  • loaded resources looks ugly

    - by Xaver
    I have the TreeView class using in my project. I use icons for it.First i load icons so: ImageList^ il = gcnew ImageList(); il->Images->Add(Image::FromFile("DISK.ico")); il->Images->Add(Image::FromFile("FILE.ico")); il->Images->Add(Image::FromFile("FOLDER.ico")); treeView1->ImageList = il; All was good. But i dont like that if i delete my icons from directory of project. there is error in my project. I decide to add icons in .resx file. Now icons loading look so: ImageList^ il = gcnew ImageList(); Resources::ResourceManager^ resourceManager = gcnew Resources::ResourceManager ("FilesSaver.Form1", GetType()->Assembly); Object^ disk = resourceManager->GetObject("DISK"); il->Images->Add(reinterpret_cast<Image^>(disk)); Object^ file = resourceManager->GetObject("FILE"); il->Images->Add(reinterpret_cast<Image^>(file)); Object^ folder = resourceManager->GetObject("FOLDER"); il->Images->Add(reinterpret_cast<Image^>(folder)); treeView1->ImageList = il; And why icons in the TreeView looks ugly (they look lighter and have a big black border). Why did this happen?

    Read the article

  • CSS text-decoration rule ignored

    - by Ferdy
    I have found similar questions to mine but none of the suggestions seems to apply to my situation, so here goes... I have a webpage with a buch of images on them. Each image has a title which in markup is between h2 tags. The title is a link, so the resulting markup is like this: <ul class="imagelist"> <li> <a href=""><h2>Title 1</h2></a> <a href=""><img src="" /></a> </li> <li> Image 2, etc... </li> </ul> All I want is for the title links to not be underlined. I tried to address this like this: .imagelist li a h2 { color:#333; text-decoration:none; } It completely ignores the text-decoration rule, yet respects the color rule. From other questions I learned that this could be because a child element cannot overrule the text-decoration of any of its parents. So, I went looking for the parent elements to see if any explicit text-decoration rules are applied. I found none. This is driving me crazy, any help? For the sake of completeness, here is the Firebug CSS output, which shows the full inheritance and such. Probably more than you want, but I cannot see anything conflicting here. .imagelist li a h2 { color:#333333; text-decoration:none; } main.css (line 417) h2 { font-size:14px; } main.css (line 40) h1, h2, h3, h4, h5, h6 { display:block; font-weight:bold; margin-bottom:10px; } main.css (line 38) h1, h2, h3, h4, h5, h6 { font-size:100%; font-weight:normal; } reset-min.css (line 7) body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, th, td { margin:0; padding:0; } reset-min.css (line 7) Inherited froma /apps/ju...mage/745 a { color:#0063E2; } main.css (line 55) Inherited fromli .imagelist li { list-style-type:none; } main.css (line 411) li { list-style:none outside none; } reset-min.css (line 7) Inherited fromul.imagelist .imagelist { border-collapse:collapse; font-size:9px; } main.css (line 410) Inherited frombody body, form { color:#333333; font:12px arial,helvetica,clean,sans-serif; } main.css (line 36) Inherited fromhtml html { color:#000000;

    Read the article

  • retrieve image from gallery in android

    - by smsys
    I have created an Activity where i have a Button. By pressing the button an android Gallery opens. When i choose an image from the gallery it is shows it in an ImageView of my Activity but after choosing second time the following error occuring 01-13 17:55:25.323: ERROR/AndroidRuntime(14899): java.lang.OutOfMemoryError: bitmap size exceeds VM budget Here is the source code i am using: public class MyImage extends Activity { /** Called when the activity is first created. */ Gallery gallery; private Uri[] mUrls; String[] mFiles=null; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); File images = Environment.getDataDirectory(); File[] imagelist = images.listFiles(); mFiles = new String[imagelist.length]; for(int i= 0 ; i< imagelist.length; i++) { mFiles[i] = imagelist[i].getAbsolutePath(); } mUrls = new Uri[mFiles.length]; for(int i=0; i < mFiles.length; i++) { mUrls[i] = Uri.parse(mFiles[i]); } Gallery g = (Gallery) findViewById(R.id.Gallery01); g.setAdapter(new ImageAdapter(this)); g.setFadingEdgeLength(40); } public class ImageAdapter extends BaseAdapter{ int mGalleryItemBackground; public ImageAdapter(Context c) { mContext = c; } public int getCount(){ return mUrls.length; } public Object getItem(int position){ return position; } public long getItemId(int position) { return position; } public View getView(int position, View convertView, ViewGroup parent){ ImageView i = new ImageView(mContext); i.setImageURI(mUrls[position]); i.setScaleType(ImageView.ScaleType.FIT_XY); i.setLayoutParams(new Gallery.LayoutParams(260, 210)); return i; } private Context mContext; } }

    Read the article

  • Jquery ID Attribute Contains With Selector and Variable

    - by User970008
    I would like to search for an image ID that contains a value AND a variable. I need the below script to be something like $("[id*='MYVALUE'+x]") but that does not work. for (x=0; x< imageList.length; x++) { var imageSRC = imageList[x]; //need this to be MYVALUE + the X val //search for IDs that contain MYVALUE + X $("[id*='MYVALUE']").attr('src', 'images/'+imageSRC); }; <!-- These images are replaced with images from the array imageList--> <img id="dkj958-MYVALUE0" src="images/imageplaceholder" /> <img id="mypage-MYVALUE1" src="images/imageplaceholder" /> <img id="onanotherpage-MYVALUE2-suffix" src="images/imageplaceholder" />

    Read the article

  • .net c# cannot find img resources when open with exe

    - by okuryazar
    Hello, My exe processes text documents and I want to be able to right click on documents, select open with and point to my exe file. I can double click on my exe and choose a file to process with OpenFileDialog and it works fine. However, when I do open with, I get FileNotFound error. Here is the error log: System.IO.FileNotFoundException: attention.jpg at System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement) at System.Drawing.Image.FromFile(String filename) at ImzaDogrulamaUygulamasi.frmCertificate.FillTreeView() in D:\VSS\SOURCE\VS2008\EGA\ImzaDogrulamaUygulamasi\ImzaDogrulamaUygulamasi\frmCertificate.cs:line 76 at ImzaDogrulamaUygulamasi.frmCertificate.Form2_Load(Object sender, EventArgs e) in D:\VSS\SOURCE\VS2008\EGA\ImzaDogrulamaUygulamasi\ImzaDogrulamaUygulamasi\frmCertificate.cs:line 244 at System.Windows.Forms.Form.OnLoad(EventArgs e) at System.Windows.Forms.Form.OnCreateControl() at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) at System.Windows.Forms.Control.CreateControl() at System.Windows.Forms.Control.WmShowWindow(Message& m) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ScrollableControl.WndProc(Message& m) at System.Windows.Forms.ContainerControl.WndProc(Message& m) at System.Windows.Forms.Form.WmShowWindow(Message& m) at System.Windows.Forms.Form.WndProc(Message& m) at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) and this is how I add my images in my code, all resources are in the same directory with the exe file: ImageList myImageList = new ImageList(); myImageList.Images.Add(Image.FromFile("attention.jpg")); myImageList.Images.Add(Image.FromFile("sandglass.jpg")); myImageList.Images.Add(Image.FromFile("11.JPG")); myImageList.Images.Add(Image.FromFile("checkGif.jpg")); treeView1.ImageList = myImageList; Any help is much appreciated. Thanks

    Read the article

  • resizing images with imagemagick via shell script

    - by jml
    Hi there, I don't really know that much about bash scripts OR imagemagick, but I am attempting to create a script in which you can give some sort of regexp matching pattern for a list of images and then process those into new files that have a given filename prefix. for example given the following dir listing: allfiles01.jpg allfiles02.jpg allfiles03.jpg i would like to call the script like so: ./resisemany.sh allfiles*.jpg 30 newnames*.jpg the end result of this would be that you get a bunch of new files with newnames, the numbers match up, so far what i have is: IMAGELIST=$1 RESIEZFACTOR=$2 NUMIMGS=length($IMAGELIST) for(i=0; i<NUMIMGS; i++) convert $IMAGELIST[i] -filter bessel -resize . RESIZEFACTOR . % myfile.JPG Thanks for any help... The parts that I obviously need help with are 1. how to give a bash script matching criteria that it understands 2. how to use the $2 without having it match the 2nd item in the image list 3. how to get the length of the image list 4. how to create a proper for loop in such a case 5. how to do proper text replacement for a shell command whereby you are appending items as i allude to. jml

    Read the article

  • C# Silverlight - Delay Child Window Load?!

    - by Goober
    The Scenario Currently I have a C# Silverlight Application That uses the domainservice class and the ADO.Net Entity Framework to communicate with my database. I want to load a child window upon clicking a button with some data that I retrieve from a server-side query to the database. The Process The first part of this process involves two load operations to load separate data from 2 tables. The next part of the process involves combining those lists of data to display in a listbox. The Problem The problem with this is that the first two asynchronous load operations haven't returned the data by the time the section of code to combine these lists of data is reached, thus result in a null value exception..... Initial Load Operations To Get The Data: public void LoadAudits(Guid jobID) { var context = new InmZenDomainContext(); var imageLoadOperation = context.Load(context.GetImageByIDQuery(jobID)); imageLoadOperation.Completed += (sender3, e3) => { imageList = ((LoadOperation<InmZen.Web.Image>)sender3).Entities.ToList(); }; var auditLoadOperation = context.Load(context.GetAuditByJobIDQuery(jobID)); auditLoadOperation.Completed += (sender2, e2) => { auditList = ((LoadOperation<Audit>)sender2).Entities.ToList(); }; } I Then Want To Execute This Immediately: IEnumerable<JobImageAudit> jobImageAuditList = from a in auditList join ai in imageList on a.ImageID equals ai.ImageID select new JobImageAudit { JobID = a.JobID, ImageID = a.ImageID.Value, CreatedBy = a.CreatedBy, CreatedDate = a.CreatedDate, Comment = a.Comment, LowResUrl = ai.LowResUrl, }; auditTrailList.ItemsSource = jobImageAuditList; However I can't because the async calls haven't returned with the data yet... Thus I have to do this (Perform the Load Operations, Then Press A Button On The Child Window To Execute The List Concatenation and binding): private void LoadAuditsButton_Click(object sender, RoutedEventArgs e) { IEnumerable<JobImageAudit> jobImageAuditList = from a in auditList join ai in imageList on a.ImageID equals ai.ImageID select new JobImageAudit { JobID = a.JobID, ImageID = a.ImageID.Value, CreatedBy = a.CreatedBy, CreatedDate = a.CreatedDate, Comment = a.Comment, LowResUrl = ai.LowResUrl, }; auditTrailList.ItemsSource = jobImageAuditList; } Potential Ideas for Solutions: Delay the child window displaying somehow? Potentially use DomainDataSource and the Activity Load control?! Any thoughts, help, solutions, samples comments etc. greatly appreciated.

    Read the article

  • Setting treeview background color in VB6 has a flaw - help?

    - by RenMan
    I have successfully implemented this method of using the Win32 API to set the background color of a treeview in VB 6: http://support.microsoft.com/kb/178491 However, one thing goes wrong: when you expand the tree nodes more than two levels deep, the area to the left of (and sometimes under) the inner plus [+] and minus [-] signs is still white. Does anyone know how to get this area to the correct background color, too? Note: I'm also setting the BackColor of each node, and also the BackColor of the treeview's imagelist. Here's my version of the code: Public Sub TreeView_SetBackgroundColor(TreeView As MSComctlLib.TreeView, BackgroundColor As Long) Dim lStyle As Long, Node As MSComctlLib.Node For Each Node In TreeView.Nodes Node.BackColor = BackgroundColor Next TreeView.ImageList.BackColor = BackgroundColor Call SendMessage( _ TreeView.hwnd, _ TVM_SETBKCOLOR, _ 0, _ ByVal BackgroundColor) 'Now reset the style so that the tree lines appear properly. lStyle = GetWindowLong(TreeView.hwnd, GWL_STYLE) Call SetWindowLong(TreeView.hwnd, GWL_STYLE, lStyle - TVS_HASLINES) Call SetWindowLong(TreeView.hwnd, GWL_STYLE, lStyle) End Sub

    Read the article

  • fill gridview cell-by-cell

    - by raging_boner
    I want to populate GridView below with images: <asp:GridView ID="GrdDynamic" runat="server" AutoGenerateColumns="False"> <Columns> </Columns> </asp:GridView> The code below iterates through directory, then I collect image titles and want them to be populated in gridview. code in bold is not working well, gridview is only filled with the last image in list. List<string> imagelist = new List<string>(); protected void Page_Load(object sender, EventArgs e) { foreach (String image in Directory.GetFiles(Server.MapPath("example/"))) { imagelist.Add("~/example/" + Path.GetFileName(image)); } loadDynamicGrid(imagelist); } private void loadDynamicGrid(List<string> list) { DataTable dt = new DataTable(); DataColumn dcol = new DataColumn(NAME, typeof(System.String)); dt.Columns.Add(dcol); dcol = new DataColumn("NAME1", typeof(System.String)); dt.Columns.Add(dcol); dcol = new DataColumn("NAME2", typeof(System.String)); dt.Columns.Add(dcol); dcol = new DataColumn("NAME3", typeof(System.String)); dt.Columns.Add(dcol); DataRow drow = dt.NewRow(); dt.Rows.Add(); dt.Rows.Add(); **for (int i = 0; i < dt.Rows.Count; i++) { for (int j = 0; j < dt.Columns.Count; j++) { foreach (string value in list) { dt.Rows[i][j] = value; } } }** foreach (DataColumn col in dt.Columns) { ImageField bfield = new ImageField(); bfield.DataImageUrlField = NAME; bfield.HeaderText = col.ColumnName; GrdDynamic.Columns.Add(bfield); } GrdDynamic.DataSource = dt; GrdDynamic.DataBind(); } how to fill gridview cell-by-cell only with available amount of images? i know it is easy, i tried various methods like: dt.Rows.Add(list); and some other attempts, but they didn't work. i'm very stupid. i'd be glad for any help.

    Read the article

  • plupload not working in wordpress theme files

    - by Kedar B
    This is my code for image upload.... <a id="aaiu-uploader" class="aaiu_button" href="#"><?php _e('*Select Images (mandatory)','wpestate');?></a> <input type="hidden" name="attachid" id="attachid" value="<?php echo $attachid;?>"> <input type="hidden" name="attachthumb" id="attachthumb" value="<? php echo $thumbid;?>"> i want upload functionality more than one time in single page in wordpress.i have add js code for that same as first upload block but its not working. This is js code for image upload.... jQuery(document).ready(function($) { "use strict"; if (typeof(plupload) !== 'undefined') { var uploader = new plupload.Uploader(ajax_vars.plupload); uploader.init(); uploader.bind('FilesAdded', function (up, files) { $.each(files, function (i, file) { // console.log('append'+file.id ); $('#aaiu-upload-imagelist').append( '<div id="' + file.id + '">' + file.name + ' (' + plupload.formatSize(file.size) + ') <b></b>' + '</div>'); }); up.refresh(); // Reposition Flash/Silverlight uploader.start(); }); uploader.bind('UploadProgress', function (up, file) { $('#' + file.id + " b").html(file.percent + "%"); }); // On erro occur uploader.bind('Error', function (up, err) { $('#aaiu-upload-imagelist').append("<div>Error: " + err.code + ", Message: " + err.message + (err.file ? ", File: " + err.file.name : "") + "</div>" ); up.refresh(); // Reposition Flash/Silverlight }); uploader.bind('FileUploaded', function (up, file, response) { var result = $.parseJSON(response.response); // console.log(result); $('#' + file.id).remove(); if (result.success) { $('#profile-image').css('background-image','url("'+result.html+'")'); $('#profile-image').attr('data-profileurl',result.html); $('#profile-image_id').val(result.attach); var all_id=$('#attachid').val(); all_id=all_id+","+result.attach; $('#attachid').val(all_id); $('#imagelist').append('<div class="uploaded_images" data- imageid="'+result.attach+'"><img src="'+result.html+'" alt="thumb" /><i class="fa deleter fa-trash-o"></i> </div>'); delete_binder(); thumb_setter(); } }); $('#aaiu-uploader').click(function (e) { uploader.start(); e.preventDefault(); }); $('#aaiu-uploader2').click(function (e) { uploader.start(); e.preventDefault(); }); } });

    Read the article

1 2 3  | Next Page >