Thanks for the info!
massaslayer
Posts
-
Piccolo with Java Drawing & Positioning -
Piccolo with Java Drawing & PositioningHello! First question: I need to draw something like this in Piccolo, and I don't have a clue to get started with that: Image Second question: I have a moving node on
m_canvas.getCamera().addChild(node);
I move it (scale it) by using the following code:
m_canvas.getCamera().animateToPositionScaleRotation(-1,-1, m_canvas.getCamera().getScale()+0.2,0, 1000);
It scales fine but it always moves position like x +10 & y+10 and I can't figure out a way to get it scale in the same place. And when the scale reaches a certain point it has to be replaces with another node so I just do
m_canvas.getCamera().removeAllChildren();
is that the correct way? Final questions - Is there a way for restricting the area where objects may go? So that the an node can't get dragged off screen? - What is the right way to draw a line in the middle of the canvas so I can split the Window in 2 seperate areas? (This line can't be scalled) Thanks a lot to anyone who can help! Greetz!
-
Remove Multiple Gridview Columns before Excel ExportHello! I'm trying to find a code to delete multiple columns because when you delete a column the next column takes his place so for example: If you delete column 6 then column 7 becomes column six. I tried the following code with an for loop & a while loop: Dim field As DataControlField = gv.Columns(i) gv.Columns.Remove(field) & gv.columns.removeat(i) But same case that the column 7 becomes column 6 The variable removeColumns is an array with the column number that need to be deleted. If wanted I can also provide the Header Names Thanks a lot for anyone who can Help me!
Imports System.Data
Imports System.Configuration
Imports System.IO
Imports System.Web
Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.WebControls.WebParts
Imports System.Web.UI.HtmlControlsPublic Class GridViewExportUtil
Public Shared Sub Export(ByVal fileName As String, ByVal gv As GridView, ByVal removeColumns As Integer())
HttpContext.Current.Response.Clear()
HttpContext.Current.Response.AddHeader("content-disposition", String.Format("attachment; filename={0}", fileName))
HttpContext.Current.Response.ContentType = "application/ms-excel"'Gridview column delete code should come here
Using sw As New StringWriter() Using htw As New HtmlTextWriter(sw) ' Create a form to contain the grid Dim table As New Table() ' add the header row to the table If gv.HeaderRow IsNot Nothing Then GridViewExportUtil.PrepareControlForExport(gv.HeaderRow) table.Rows.Add(gv.HeaderRow) End If ' add each of the data rows to the table For Each row As GridViewRow In gv.Rows GridViewExportUtil.PrepareControlForExport(row) table.Rows.Add(row) Next ' add the footer row to the table If gv.FooterRow IsNot Nothing Then GridViewExportUtil.PrepareControlForExport(gv.FooterRow) table.Rows.Add(gv.FooterRow) End If ' render the table into the htmlwriter table.RenderControl(htw) ' render the htmlwriter into the response HttpContext.Current.Response.Write(sw.ToString()) HttpContext.Current.Response.\[End\]()
-
Setting DisplayMember & ValueMember with DataTablePublic Sub s_zoekEntiteit(ByVal i_entiteit As String)
Dim sqlStr As String = "zoekEntiteit '" & i\_entiteit & "'" Dim dataAdapter = New SqlDataAdapter(sqlStr, m\_constring) Dim commandBuilder As New SqlCommandBuilder(dataAdapter) Dim DataGridTable As New DataTable() dataAdapter.Fill(DataGridTable) Form5.ListBox1.DataSource = DataGridTable Form5.ListBox1.DisplayMember = i\_entiteit Form5.ListBox1.ValueMember = i\_entiteit End Sub
The Stored Procedure:
CREATE PROCEDURE zoekEntiteit (@tmpEntiteit nvarchar(40))AS
BEGIN
-- SET NOCOUNT ON added to prevent extra result sets from
-- interfering with SELECT statements.
SET NOCOUNT ON;SELECT @tmpEntiteit FROM tblProduct; --'ByVal i\_prodid As String, ByVal i\_prodnaam As String, ByVal i\_prodomschrijving As String, --'ByVal i\_prodprijs As Int16, ByVal i\_prodinstock As String)
END
The RESULT if @tmpEntiteit would be ProdID : Image to Result What is wrong here I keep getting an error on ' Form5.ListBox1.ValueMember = i_entiteit' the following error : Can't bind to the new DisplayMember. Paramater newDisplayMember
-
Event handling in CI've read this thing: http://www.codeproject.com/KB/winsdk/console\_event\_handling.aspx\[^\] but it's still not clear where i put the codes... the main idea is: that the user is not possible to close the console window by pressing X. Please help me, i've spend houres searching:confused:
-
Event handling in CI've read this thing: http://www.codeproject.com/KB/winsdk/console_event_handling.aspx[^] but it's still not clear where i put the codes... the main idea is: that the user is not possible to close the console window by pressing X. Please help me, i've spend houres searching
-
How can i get a table in richtextboxHello everyone, I would like to get a table in my richtextbox. If this is possible how you do it? And can somebody help me on the way. Best regards, Vincent