GrapeCity Forums

The GrapeCity Message Boards
Welcome to GrapeCity Forums Sign in | Join | Help
in Search

Cell type within child view issue

Last post 02-03-2010, 9:31 AM by jacob. 2 replies.
Sort Posts: Previous Next
  •  02-02-2010, 4:35 PM 87052

    Cell type within child view issue

    Hello, I'm probably doing something boneheaded, but for some reason I'm having an issue with something that should be simple. When I try to set a property for a celltype, hitting the "+" sign on a hierarchy won't expand to show the child view.

     

    e.g.

    Private Sub FpSpread1_ChildViewCreated(ByVal sender As System.Object, ByVal e As FarPoint.Web.Spread.CreateChildViewEventArgs) Handles FpSpread1.ChildViewCreated

    SetChildViewStyle(e.SheetView)

    End Sub

    Sub SetChildViewStyle(ByVal sv As FarPoint.Web.Spread.SheetView)

    Dim curcell As New FarPoint.Web.Spread.CurrencyCellType

    curcell.NumberFormat.NumberDecimalDigits = 2

    sv.Cells(0, 3).CellType = curcell

    End Sub

     

    Commenting out the "curcell.NumberFormat.NumberDecimalDigits = 2", however, solves the issue--but leaves me with the currency amount displaying different from desired.

  •  02-02-2010, 5:48 PM 87056 in reply to 87052

    Re: Cell type within child view issue

    Oi, this should be in the asp.net forum, sorry.
  •  02-03-2010, 9:31 AM 87069 in reply to 87056

    Re: Cell type within child view issue

    Hi, I tried reproducing the problem with minor changes, and was not able to reproduce the case. The code as follows:

    <code>

    Dim curcell As New FarPoint.Web.Spread.CurrencyCellType
    curcell.NumberFormat = New System.Globalization.NumberFormatInfo()
    curcell.NumberFormat.NumberDecimalDigits = 2
    sv.Columns(3).CellType = curcell

    </end of code>

    Here, I initialized the NumberFormat with NumberFormatInfo object, and applied the CellType to the columns instead of the cell.

    Please let me know if this resolves the problem.

    Thanks,

    ~Jacob

View as RSS news feed in XML
     FarPoint Forums Home