Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
R

roman_s

@roman_s
About
Posts
32
Topics
19
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • How do I go about recording a playlist to stream to a large mp3?
    R roman_s

    So I have a program that creates a playlist on the grid, it can play the playlist and mix the songs together. I am trying to find a library/code that will either stream or record the entire playlist and mixes to mp3 I was thinking of capturing the audio playback and recording it?

    C# question css

  • Sorting objects in a dictionary into corresponding Pairs...
    R roman_s

    Ive used sorteddictionary to now group the different dates..

    C# database algorithms help

  • Sorting objects in a dictionary into corresponding Pairs...
    R roman_s

    So here is my dilemma, rather then describe it I will show you it. Let say we take back a certain amount of records records from the DB Called Inventory Count and they have a corresponding number attached to them indicating if they are an opening Count (1) or a closing count (2) Date-Product-Quantity-Opening/Closing 1. 1/1/2010, Ice Cream Cones, 10, 1 2. 1/1/2010, Bananas, 8, 1 3. 1/1/2010, Chocolate Bars, 9, 1 4. 2/1/2010, Ice Cream Cones, 5, 2 5. 2/1/2010, Bananas, 4, 2 6. 2/1/2010, Chocolate Bars, 3, 2 7. 4/1/2010, Ice Cream Cones, 12, 1 8. 4/1/2010, Bananas, 8, 1 9. 4/1/2010, Chocolate Bars, 9, 1 10. 5/1/2010, Ice Cream Cones, 1, 2 11. 5/1/2010, Bananas, 2, 2 12. 5/1/2010, Chocolate Bars, 3, 2 I need to build a dictionary that will take the first group (Openings = 1) and do the subtraction of quantity for closing(Closing 2), This will make up Session 1, Session 2 will be the next corresponding groups of Opening = 1 - Closing = 2 Thanks for the help in advance, hopefully this is understandable

    C# database algorithms help

  • Is there a library to read/stream MP3, detect beats per minute, create a mix between 2 different MP3/Wav
    R roman_s

    Is there a library to -read/stream MP3 - detect beats per minute - create a mix between 2 different MP3/Wav

    C#

  • Parsing csv file with commas and quotes as deliminators
    R roman_s

    So Im reading a csv file and splitting the string with "," as the deliminator but some of them have quotes as to not split the specific field because it has a comma in it. 1530,Pasadena CA,"2008, 05/01","2005, 12/14" with just comma it would be: 1530 Pasadena CA "2008 05/01" "2005 12/14" I need it to take commas into consideration when splitting so its like this 1530 Pasadena CA "2008 05/01" "2005 12/14"

    C# json

  • RE: Save user's re-order grid preferences
    R roman_s

    yes I persist on columnheaderclick. So it looks like I would have to save the column header index when user navigates from that specific panel. question is: (XML is going to be best option) each column will have an index.. on build the grid builds the columns in order to the columns index. what columnheader property is this and how would I go on to save and read from xml to populate these index #s

    C# css question

  • RE: Save user's re-order grid preferences
    R roman_s

    So I've set my grid to allowReorder , this causes persistence on the grid order but once the program is restarted it goes back to default can someone let me know how I can save a user's re-order preference. Thinking it can be a property? If not maybe build a method to take care of this

    C# css question

  • Help: Can't format string using String.Format
    R roman_s

    I cant seem to format my strAverageDensity which originally is in this example strAverageDensity = 30.000000123 using: string.Format("{0:0.00}", strAverageDensity); need it to equal 30.00 in this case but 2 decimal places instead its still strAverageDensity = 30.000000123 so this is the code:

                EditSubCategory E = new EditSubCategory();
    
                    SubCategory C = GlobalContextManager.Instance.Cache.GetSubCategory((int)R.Cells\[0\].Value);
                    Category CC = GlobalContextManager.Instance.Cache.GetCategory(C.CategoryId);
    
                  string strAverageDensity = Convert.ToString(GlobalContextManager.Instance.Conversions.ConvertMetricWeightToDefault(C.AverageDensity));
    
                    E.ParentCategory = CC;
                    E.Category = C.Name;
                    E.IsActivated = C.IsEnabled;
                    E.OriginalCategory = C.Name;
    
                    strAverageDensity = string.Format("{0:0.00}", strAverageDensity);
                    E.AverageDensity = strAverageDensity;
    
    C# help tutorial

  • How come I get a rounded number when I multiply doubles?? [modified]
    R roman_s

    Sorry there is a mathematical mistake what I needed to know is when dividing an integer with a remainder I was getting double variable(2425) / 100 would give you 24.0 , I was wondering why I wasn't getting 24.25 solution was because I was dividing an integer into another integer, I corrected this simply by multiplying 100.00 instead of 100

    C# help question

  • How come I get a rounded number when I multiply doubles?? [modified]
    R roman_s

    How come I get a rounded number when I multiply and assign value to a double??

    dbRecipeTotal = (RI.Quantity / dbRecipeTotalQuantity) * (InvItem.Price / 100);

    double dbRecipeTotal = 0.0;
    RI.Quantity is = 28.88887
    dbRecipeTotalQuantity is = 28.88887
    InvItem.Price is = 2425

    I get dbRecipeTotal = 24.0 in quickview it should be 24.25 Any help is appreaciated

    modified on Wednesday, July 28, 2010 9:44 AM

    C# help question

  • Creating a function using Dictionary and Datetime help??
    R roman_s

    Hi Luc, I tried the above code, just trying to debug the last line if (strcmp(curr.Substring(0,curr.LastIndexOf('_')), next.Substring(0,next.LastIndexOf('_'))!=0) { strcmp is a c++ concept, is that similiar to StringComparer? also my ide complains !=0 that it cannot be applied to an int and a string. Tried playing around with the brackets and to no function. let me know what I can do.

    C# help tutorial question

  • Creating a function using Dictionary and Datetime help??
    R roman_s

    Thank you for your reply I don't need the for example the last 4 latest records in the array... as I can have several days and the oldest date has 3 times it was altered creating 3 different files for that day... I would need the newest one.

    C# help tutorial question

  • Creating a function using Dictionary and Datetime help??
    R roman_s

    So I created a dictionary DICTIONARY1

    dicFilesDT.Add(dateParts[1], (dateParts[1] + dateParts[2] ));

    so that I would have just the: KEY as the Date and VALUE as the Date+Time I need help in making another dictionary (DICTIONARY2) that would 1. If there are no Duplicates from checking DICTIONARY2 using foreach keyvaluepair in DICTIONARY1 add Key Pair to DICTIONARY2 2. Check for duplicates of the Key (Date) (thinking ex. dictionary.ContainsKey) if the dictionary has the KEY then Compare the KEY VALUE from DICTIONARY 1 to DICTIONARY 2 to see which one is larger ex. 230132 compared to 100425 if DICTIONARY1 KEY VALUE is larger Delete KeyValuePair from DICTIONARY 2 and add DICTIONARY 1 KEY VALUE else do nothing and continue the loop Thank you folks for helping me wiht this.

    C# help tutorial question

  • Creating a function using Dictionary and Datetime help??
    R roman_s

    I am importing another system's files therefor I do cannot change the file naming convention so Im thinking of parsing the file into: datetime, full name How can I compare the each record against each other with the first 8 digits for example 20100719 and if it finds another string node with 20100719 to then look at the substring/node which would be the next 6 digits after the date. then delete the record that is not the most current for that date. Thanks in advance

    C# help tutorial question

  • Creating a function using Dictionary and Datetime help??
    R roman_s

    I am first getting a list of strings from files that have dates in them ex. fileabc_20100612_1020.txt in a certain directory(expression S.ImportFolder) my objective is to get a list of these dates in from a folder. My problem is that there will be some files with same dates in this case I want to select the newest one for that date like closest to 23:59 of that Date. for example in c:\Temp there is fileabc_20100612_1020.txt fileabc_20100613_1020.txt fileabc_20100614_1020.txt fileabc_20100614_2320.txt I would want to only import fileabc_20100612_1020.txt fileabc_20100613_1020.txt fileabc_20100614_2320.txt or exclude fileabc_20100614_1020.txt

            string\[\] fileEntries = Directory.GetFiles(S.ImportFolder);
            foreach (string fileNameWithRoot in fileEntries)
            {
                string fileName = System.IO.Path.GetFileName(fileNameWithRoot);
    

    ....String manipulation.....
    DateTime dtFileName = new DateTime();
    try
    {
    DateTime dtFileName = Convert.ToDateTime(fileName);
    }
    catch (Exception e)
    {
    }

                dicFiles.Add(dtFileName, fileName);
    
    C# help tutorial question

  • Help with Reports: Within one of my .rdlc there 2 tables from 2 datasets....
    R roman_s

    Hi, I need help with my report I have created 2 tables: Table1: >>Datasource: Datasource1 >>Dataset: ReportItemLevelDetail1 Its grouped by category: CategoryGroup1, expression =Fields!CategoryName.Value The field creates a running value of =Sum(Fields!ActualCost.Value,"CategoryGroup1") Table2: >>Datasource: Datasource2 >>Dataset: ReportItemLevelDetail2 Its grouped by category: CategoryGroup1, expression =Fields!CategoryName.Value The field creates a running value of =Sum(Fields!ActualCost.Value,"CategoryGroup2") Both create the same data but at different time periods I need to make a table3 and with The difference between =Sum(Fields!ActualCost.Value,"CategoryGroup1") and =Sum(Fields!ActualCost.Value,"CategoryGroup2")

    Windows Forms help

  • How do I format Column when a Gridview loads?
    R roman_s

    Cellformating worked. Thank you!

    C# question css wpf wcf

  • How do I format Column when a Gridview loads?
    R roman_s

    Thanks, this is what I have: Class:

    private void dataGridView1_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
    {
    }

    What args do I use in designer?? I tried this event to trigger cellformating: this.SubcategoryGrid.DataBindings += ........

    C# question css wpf wcf

  • How do I format Column when a Gridview loads?
    R roman_s

    How do I format Column when a Gridview loads? Details: I have a grid named : SubcategoryGrid the grid is binded to a data binding source. there is a column in that grid(double type), I need to apply a simple conversion formula after the data binding completes what gridview argument do I use? or how would I go on about this?

    C# question css wpf wcf

  • DataGrid Column: How to create simulated mouse click event or column header click event.
    R roman_s

    right now I have one column header that does not alphabetically sort its self when column header is clicked. so I figured I can make an event if that column header is clicked to a column header that sorts the it how I need to Column header Im targeting is gridView.columnFlags so far I have

        private void OnColumnHeaderClick(object sender, Divelements.SandGrid.GridColumnEventArgs e)
        {
            if (e.GridColumn.Equals(columnTest))
            {
                //this.OnMouseClick(new MouseEventArgs(MouseButtons.Left, 1, 100, 100, 0));
    
              //THIS IS WHERE I CAN SIMULATE MOUSE CLICK ON THE gridView.columnFlags COLUMN HEADER 
             // THE ABOVE CODE DOESNT WORKS
            }
    
            gms.HandleSort(e.GridColumn);
    
    C# tutorial
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups