Click here to Skip to main content
15,921,467 members
Home / Discussions / C#
   

C#

 
QuestionRe-Question Pin
Dong Cher, Ryu25-Jun-09 3:56
Dong Cher, Ryu25-Jun-09 3:56 
AnswerRe: Re-Question Pin
Luc Pattyn25-Jun-09 4:06
sitebuilderLuc Pattyn25-Jun-09 4:06 
AnswerRe: Re-Question Pin
EliottA25-Jun-09 4:09
EliottA25-Jun-09 4:09 
QuestionActive directory Users Pin
caiena25-Jun-09 3:51
caiena25-Jun-09 3:51 
AnswerRe: Active directory Users Pin
Manas Bhardwaj25-Jun-09 4:18
professionalManas Bhardwaj25-Jun-09 4:18 
QuestionDynamic crystal reports Pin
rajeshkiduvath25-Jun-09 3:48
rajeshkiduvath25-Jun-09 3:48 
AnswerRe: Dynamic crystal reports Pin
EliottA25-Jun-09 4:47
EliottA25-Jun-09 4:47 
AnswerRe: Dynamic crystal reports Pin
Behrooz_cs27-Jun-09 21:31
Behrooz_cs27-Jun-09 21:31 
dont try any more. i had your question for a long time.
it has no answer.i searched a lot on the web.but you search again for it. you may find it. i made a
code to serialize it into xml and create a dynamic report.
i have this code for microsoft reports(.RDLC) it is not CrystalReport but it may solve your problem. it is incomplete. and also has errors. its incomplete because i tried to print my views directly.
if you fixed it send it to me.
namespace Proj.RDLC_Reports
{
    enum Alignment
    {
        Right,
        Left,
        Center
    }
    interface IXMLExportable
    {
        string ToXml();
        bool IsAvailable { get; }
    }
    static class Class_RDLCReportCreator
    {
        static Report CreateReportByGrid(System.Windows.Forms.DataGridView DataGridView, System.Drawing.Printing.PaperKind PaperKind, bool Portrait, DataSources DataSources, Proj.RDLC_Reports.ReportParameters ReportParameters)
        {
            Report R = new Report();
            R.DataSources = DataSources;
            R.Language = "en-US";
            //R.Body.ReportItems.Add;
            R.ReportParameters = ReportParameters;
            Table T = new Table();
            foreach (System.Windows.Forms.DataGridViewColumn DGVC in DataGridView.Columns)
            {
            }
            return R;
        }
    }
    class Style : IXMLExportable
    {
        private string fontFamily;
        public string FontFamily { get { return fontFamily; } set { fontFamily = value; } }
        private int fontSize;
        public int FontSize { get { return fontSize; } set { fontSize = value; } }
        private int fontWeight;
        public int FontWeight { get { return fontWeight; } set { fontWeight = value; } }
        private int paddingLeft;
        public int PaddingLeft { get { return paddingLeft; } set { paddingLeft = value; } }
        private int paddingRight;
        public int PaddingRight { get { return paddingRight; } set { paddingRight = value; } }
        private int paddingTop;
        public int PaddingTop { get { return paddingTop; } set { paddingTop = value; } }
        private int paddingBottom;
        public int PaddingBottom { get { return paddingBottom; } set { paddingBottom = value; } }
        private Alignment textAlign;
        internal Alignment TextAlign { get { return textAlign; } set { textAlign = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class Report : IXMLExportable
    {
        private int interactiveHeight; internal int InteractiveHeight { get { return interactiveHeight; } set { interactiveHeight = value; } }
        private int interactiveWidth; internal int InteractiveWidth { get { return interactiveWidth; } set { interactiveWidth = value; } }
        private int rightMargin; internal int RightMargin { get { return rightMargin; } set { rightMargin = value; } }
        private int leftMargin; internal int LeftMargin { get { return leftMargin; } set { leftMargin = value; } }
        private int bottomMargin; internal int BottomMargin { get { return bottomMargin; } set { bottomMargin = value; } }
        private int width; internal int Width { get { return width; } set { width = value; } }
        private string language = "en-US"; internal string Language { get { return language; } set { language = value; } }
        private int topMargin; internal int TopMargin { get { return topMargin; } set { topMargin = value; } }
        private DataSets dataSets; internal DataSets DataSets { get { return dataSets; } set { dataSets = value; } }
        private DataSources dataSources; internal DataSources DataSources { get { return dataSources; } set { dataSources = value; } }
        private Body body; internal Body Body { get { return body; } set { body = value; } }
        private ReportParameters reportParameters; internal ReportParameters ReportParameters { get { return reportParameters; } set { reportParameters = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return true; } }
    }
    class DataSources : System.Collections.ObjectModel.Collection<DataSource>, IXMLExportable
    {
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class ConnectionProperties : IXMLExportable
    {
        private string dataProvider;
        public string DataProvider { get { return dataProvider; } set { dataProvider = value; } }
        private string connectString;
        public string ConnectString { get { return connectString; } set { connectString = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class DataSource : IXMLExportable
    {
        private ConnectionProperties connectionProperties;
        internal ConnectionProperties ConnectionProperties { get { return connectionProperties; } set { connectionProperties = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class DataSet : IXMLExportable
    {
        private string name;
        public string Name { get { return name; } set { name = value; } }
        private Fields fields;
        internal Fields Fields { get { return fields; } set { fields = value; } }
        private Query query;
        internal Query Query { get { return query; } set { query = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class Fields : System.Collections.ObjectModel.Collection<Field>, IXMLExportable
    {
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class Field : IXMLExportable
    {
        private string name;
        public string Name { get { return name; } set { name = value; } }
        private string dataField;
        public string DataField { get { return dataField; } set { dataField = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class Query : IXMLExportable
    {
        private string dataSourceName;
        public string DataSourceName { get { return dataSourceName; } set { dataSourceName = value; } }
        private string commandText;
        public string CommandText { get { return commandText; } set { commandText = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class DataSets : System.Collections.ObjectModel.Collection<DataSet>, IXMLExportable
    {
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class Body : IXMLExportable
    {
        private int height;
        public int Height { get { return height; } set { height = value; } }
        private ReportItems reportItems;
        internal ReportItems ReportItems { get { return reportItems; } set { reportItems = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class ReportItems : System.Collections.ObjectModel.Collection<ReportItem>, IXMLExportable
    {
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }

    }
    abstract class ReportItem : IXMLExportable
    {
        private Style style;
        internal Style Style { get { return style; } set { style = value; } }
        public abstract string ToXml();
        public abstract bool IsAvailable { get; }

    }
    class TextBox : ReportItem, IXMLExportable
    {

        private int zIndex; public int ZIndex { get { return zIndex; } set { zIndex = value; } }
        private bool canGrow = true; public bool CanGrow { get { return canGrow; } set { canGrow = value; } }
        private string value; public string Value { get { return this.value; } set { this.value = value; } }
        public override string ToXml() { return ""; }
        public override bool IsAvailable { get { return false; } }
    }
    class ReportParameters : System.Collections.ObjectModel.Collection<ReportParameter>, IXMLExportable
    {
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class ReportParameter : IXMLExportable
    {
        private string dataType = "String";
        public string DataType { get { return dataType; } set { dataType = value; } }
        private bool allowBlank = true;
        public bool AllowBlank { get { return allowBlank; } set { allowBlank = value; } }
        private string prompt;
        public string Prompt { get { return prompt; } set { prompt = value; } }
        private string name;
        public string Name { get { return name; } set { name = value; } }
        public string ToXml() { return ""; }
        public bool IsAvailable { get { return false; } }
    }
    class Table : ReportItem, IXMLExportable
    {
        private string name; public string Name { get { return name; } set { name = value; } }
        private string dataSetName; public string DataSetName { get { return dataSetName; } set { dataSetName = value; } }
        private TableSection details; internal TableSection Details { get { return details; } set { details = value; } }
        private TableSection header; internal TableSection Header { get { return header; } set { header = value; } }
        private TableSection footer; internal TableSection Footer { get { return footer; } set { footer = value; } }
        public override string ToXml() { return ""; }
        public override bool IsAvailable { get { return false; } }
    }
    class TableSection : System.Collections.CollectionBase
    {
        private TableRows tableRows; internal TableRows TableRows_ { get { return tableRows; } set { tableRows = value; } }
    }
    class TableRows : System.Collections.ObjectModel.Collection<TableRow>, IXMLExportable
    {
        #region IXMLExportable Members

        public string ToXml()
        {
            throw new NotImplementedException();
        }

        public bool IsAvailable
        {
            get { throw new NotImplementedException(); }
        }

        #endregion
    }
    class TableRow : System.Collections.CollectionBase, IXMLExportable
    {
        private int height; internal int Height { get { return height; } set { height = value; } }
        private TableCells tableCells; internal TableCells TableCells { get { return tableCells; } set { tableCells = value; } }

        #region IXMLExportable Members

        public string ToXml()
        {
            throw new NotImplementedException();
        }

        public bool IsAvailable
        {
            get { throw new NotImplementedException(); }
        }

        #endregion
    }
    class TableCells : System.Collections.ObjectModel.Collection<TableCell>, IXMLExportable
    {
        #region IXMLExportable Members

        public string ToXml()
        {
            throw new NotImplementedException();
        }

        public bool IsAvailable
        {
            get { throw new NotImplementedException(); }
        }

        #endregion
    }
    class TableCell : System.Collections.ObjectModel.Collection<ReportItem>, IXMLExportable
    {
        #region IXMLExportable Members

        public string ToXml()
        {
            throw new NotImplementedException();
        }

        public bool IsAvailable
        {
            get { throw new NotImplementedException(); }
        }

        #endregion
    }
}

Questionhow to fasten the datareader and insert process Pin
Ersan Ercek25-Jun-09 3:12
Ersan Ercek25-Jun-09 3:12 
AnswerRe: how to fasten the datareader and insert process Pin
harold aptroot25-Jun-09 3:52
harold aptroot25-Jun-09 3:52 
AnswerRe: how to fasten the datareader and insert process Pin
Luc Pattyn25-Jun-09 4:08
sitebuilderLuc Pattyn25-Jun-09 4:08 
AnswerRe: how to fasten the datareader and insert process Pin
PIEBALDconsult25-Jun-09 4:47
mvePIEBALDconsult25-Jun-09 4:47 
Questionstring Pin
arkiboys25-Jun-09 3:02
arkiboys25-Jun-09 3:02 
AnswerRe: string Pin
Keith Barrow25-Jun-09 3:08
professionalKeith Barrow25-Jun-09 3:08 
AnswerRe: string Pin
himanshu256125-Jun-09 3:13
himanshu256125-Jun-09 3:13 
AnswerRe: string [modified] PinPopular
musefan25-Jun-09 3:22
musefan25-Jun-09 3:22 
GeneralRe: string Pin
Keith Barrow25-Jun-09 3:37
professionalKeith Barrow25-Jun-09 3:37 
GeneralRe: string Pin
musefan25-Jun-09 4:07
musefan25-Jun-09 4:07 
GeneralRe: string Pin
EliottA25-Jun-09 4:08
EliottA25-Jun-09 4:08 
JokeRe: string Pin
J4amieC25-Jun-09 5:11
J4amieC25-Jun-09 5:11 
GeneralRe: string Pin
EliottA25-Jun-09 10:21
EliottA25-Jun-09 10:21 
GeneralRe: string Pin
Luc Pattyn25-Jun-09 12:31
sitebuilderLuc Pattyn25-Jun-09 12:31 
GeneralRe: string Pin
J4amieC25-Jun-09 4:45
J4amieC25-Jun-09 4:45 
GeneralRe: string Pin
musefan25-Jun-09 4:59
musefan25-Jun-09 4:59 
QuestionRouter's bytes transferred so far Pin
Muammar©25-Jun-09 2:58
Muammar©25-Jun-09 2:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.