Click here to Skip to main content
15,894,825 members
Home / Discussions / C#
   

C#

 
GeneralRe: Reason for no display of data in the pdf. Pin
Mausam Bharati9-Jul-13 20:58
Mausam Bharati9-Jul-13 20:58 
Questionlistview Pin
Member 99613129-Jul-13 0:56
Member 99613129-Jul-13 0:56 
AnswerRe: listview Pin
Eddy Vluggen9-Jul-13 3:07
professionalEddy Vluggen9-Jul-13 3:07 
AnswerRe: listview Pin
Jay Nardev11-Jul-13 21:01
Jay Nardev11-Jul-13 21:01 
AnswerRe: listview Pin
Kevin Bewley15-Jul-13 5:41
Kevin Bewley15-Jul-13 5:41 
QuestionMVC Grid Pin
_BrijeshSingh8-Jul-13 23:37
_BrijeshSingh8-Jul-13 23:37 
AnswerRe: MVC Grid Pin
Pete O'Hanlon9-Jul-13 0:35
mvePete O'Hanlon9-Jul-13 0:35 
Questiontwo lists with dates and values need to match them Pin
lordoftrades8-Jul-13 21:25
lordoftrades8-Jul-13 21:25 
Hello

I have to separate lists containing two columns: Dates - Values

One of the lists have all dates from startdate to enddate, while the other list is missing weekends and holidays. So this missing holes I need to replace by the value from day before and then add these values to a new list with all dates in one column, and then values-list1 and values-list2 in two next columns...

C#
public override void OnShutdown()
        {
			string[] row = new string[7];
			double Close;
			string currentLine;
			long dates_in_IQB;
			
   			//This loop to get a complete list of dates and values 
		   	for (int i=0;i<AccountHistoryCount(0);i++){
		   	dates_in_IQB = (long)AccountHistoryDateTime(0, i); 
		  	DateTime newDate = new DateTime(dates_in_IQB);
			OutputWriteLine(String.Format("Date {0}", newDate));
			}
			
			
			//Opening .csv files from Yahoo...
            using (StreamReader sr = new StreamReader("d:/documents/SPY Ref1.csv")){
				
			sr.ReadLine();
            
            // This loop will pull all data from the .csv file, in this case downloaded with
			//the exact same start and end dates.... when running in the program it will
			//be automatically matched so no need to verify start and end date then...
            while((currentLine = sr.ReadLine()) != null)
            {
				row = currentLine.Split(',');

				DateTime Date = DateTime.ParseExact(row[0], "dd.MM.yyyy", null);
				//string Date = (row[0]);
				Close = double.Parse(row[6]);
				
	//			OutputWriteLine(String.Format("Date {0}, Close {1}", Date, Close));
				} 
        	} 
				//Match lists and create new list here:
						
						
		}


I'm pretty new to the programming, so I guess I need the information down to every details.

Kind regards
Espen Smile | :)
Questionmd5 hash c# Pin
paulpro1098-Jul-13 17:10
paulpro1098-Jul-13 17:10 
AnswerRe: md5 hash c# Pin
Dave Kreskowiak8-Jul-13 19:04
mveDave Kreskowiak8-Jul-13 19:04 
GeneralRe: md5 hash c# Pin
paulpro10912-Jul-13 15:47
paulpro10912-Jul-13 15:47 
GeneralRe: md5 hash c# Pin
Dave Kreskowiak12-Jul-13 16:17
mveDave Kreskowiak12-Jul-13 16:17 
AnswerRe: md5 hash c# Pin
Manfred Rudolf Bihy8-Jul-13 19:24
professionalManfred Rudolf Bihy8-Jul-13 19:24 
GeneralRe: md5 hash c# Pin
paulpro10912-Jul-13 15:49
paulpro10912-Jul-13 15:49 
AnswerRe: md5 hash c# Pin
Bernhard Hiller8-Jul-13 23:03
Bernhard Hiller8-Jul-13 23:03 
QuestionRe: md5 hash c# Pin
Manfred Rudolf Bihy9-Jul-13 1:53
professionalManfred Rudolf Bihy9-Jul-13 1:53 
AnswerRe: md5 hash c# Pin
paulpro10912-Jul-13 15:51
paulpro10912-Jul-13 15:51 
QuestionThanks for your help Fig. image displayed on the GridControl and XtraReport Pin
nhanlaptrinh8-Jul-13 15:13
nhanlaptrinh8-Jul-13 15:13 
QuestionHow to get rid of interval checkings Pin
leone8-Jul-13 10:49
leone8-Jul-13 10:49 
AnswerRe: How to get rid of interval checkings Pin
Eddy Vluggen9-Jul-13 0:28
professionalEddy Vluggen9-Jul-13 0:28 
Question" System.UriFormatException: Invalid URI : The format of the URI could not be determined " Pin
ChinnuKodali15088-Jul-13 7:06
professionalChinnuKodali15088-Jul-13 7:06 
AnswerRe: " System.UriFormatException: Invalid URI : The format of the URI could not be determined " Pin
Pete O'Hanlon8-Jul-13 7:10
mvePete O'Hanlon8-Jul-13 7:10 
GeneralMessage Closed Pin
8-Jul-13 10:24
professionalChinnuKodali15088-Jul-13 10:24 
GeneralRe: " System.UriFormatException: Invalid URI : The format of the URI could not be determined " Pin
Pete O'Hanlon8-Jul-13 10:29
mvePete O'Hanlon8-Jul-13 10:29 
GeneralRe: " System.UriFormatException: Invalid URI : The format of the URI could not be determined " Pin
ChinnuKodali15088-Jul-13 10:41
professionalChinnuKodali15088-Jul-13 10:41 

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.