Web Based. Drag From Palette To View


#1

how do we drag nodes from a palette to a View and then link them?


#2

At this time there isn’t any support for drag-and-drop in the browser between controls.
We have been considering adding such support for particular cases, such as the case you are asking about, but we haven’t figured out how to do so in portable JavaScript.


#3

Thanks Walter,
how do we display images on a node. I have been trying to use one bust cant get it to work. My work flow diagram has its own set of bmp images…

thanks


#4

Yes, if you are used to using Windows Forms, it is disappointing that there is no support for ImageList. Using resources (ResourceManager) is the natural alternative, of course, and that works on both platforms.
If you have the images in files, you just need to set the GoImage.Name property to the filename, including the path. You’ll note the convenient definition of the FileRoot property on the Page of several sample web applications:
public String FileRoot {
get { return MapPath(this.TemplateSourceDirectory) + “/”; }
}


#5

Actually, drag-and-drop within a GoView is supported, so it might be possible to do some sort of hack where a single GoView is split up into two parts, with one part acting as if it were a GoPalette.
Maybe you could do this by creating a non-Selectable GoGroup containing each of the palette items, positioned appropriately, and with all the properties set so that users can’t modify them: Movable, Resizable, Reshapable, Deletable, et al. You’ll also need to override DoMove on all those objects so that the user can’t move them over your fake palette.
I’m just speculating here–I don’t know if anyone has ever done anything like this.