Click here to Skip to main content
15,892,674 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Help with calculating percentage in C Pin
ForNow20-Mar-22 9:02
ForNow20-Mar-22 9:02 
QuestionMessage Closed Pin
18-Mar-22 15:23
Member 1496877118-Mar-22 15:23 
AnswerRe: How to pass pointers and process them using ellipsis ? Pin
Richard MacCutchan18-Mar-22 23:08
mveRichard MacCutchan18-Mar-22 23:08 
GeneralMessage Closed Pin
19-Mar-22 4:06
Member 1496877119-Mar-22 4:06 
GeneralRe: How to pass pointers and process them using ellipsis ? Pin
k505419-Mar-22 5:01
mvek505419-Mar-22 5:01 
GeneralMessage Closed Pin
19-Mar-22 8:44
Member 1496877119-Mar-22 8:44 
GeneralRe: How to pass pointers and process them using ellipsis ? Pin
k505419-Mar-22 12:00
mvek505419-Mar-22 12:00 
GeneralRe: How to pass pointers and process them using ellipsis ? Pin
Richard MacCutchan19-Mar-22 6:11
mveRichard MacCutchan19-Mar-22 6:11 
Questionworking with pointers Pin
Calin Negru17-Mar-22 21:48
Calin Negru17-Mar-22 21:48 
AnswerRe: working with pointers Pin
Victor Nijegorodov17-Mar-22 23:16
Victor Nijegorodov17-Mar-22 23:16 
GeneralRe: working with pointers Pin
Calin Negru18-Mar-22 0:12
Calin Negru18-Mar-22 0:12 
GeneralRe: working with pointers Pin
Victor Nijegorodov18-Mar-22 1:39
Victor Nijegorodov18-Mar-22 1:39 
GeneralRe: working with pointers Pin
Calin Negru18-Mar-22 10:20
Calin Negru18-Mar-22 10:20 
Generalgoing a bit further: working with pointers Pin
Calin Negru20-Mar-22 7:47
Calin Negru20-Mar-22 7:47 
I have an update. This is a function for inserting nodes in the middle of the list. Is this a good approach? I did a quick test and it looks like it`s doing what it should.
void InsertTo(SomeNode ** FrontTip, int NewNodeData, int InsertInFrontOfNodeCount, int TotalNodeCount)
{
	SomeNode * Temp;
	SomeNode * NewNode;
	SomeNode * Previous;
	NewNode = (SomeNode*)malloc(sizeof(SomeNode));
	NewNode->data = NewNodeData;

	bool firstrun = true;

	for(int i =0; i < TotalNodeCount;i++)
	{
		if(i == InsertInFrontOfNodeCount)
		{
			NewNode->next = Temp;
			Previous->next = NewNode;
		}
		else
		{
			if(firstrun)
			{
				Temp = (*FrontTip)->next;
				firstrun = false;
			}
			else
			{
				Previous = Temp;
				Temp = Temp->next;

			}
			
		}
		 
	}

}

AnswerRe: working with pointers Pin
Mircea Neacsu18-Mar-22 10:19
Mircea Neacsu18-Mar-22 10:19 
QuestionRe: working with pointers Pin
David Crow21-Mar-22 3:16
David Crow21-Mar-22 3:16 
AnswerRe: working with pointers Pin
Calin Negru21-Mar-22 5:15
Calin Negru21-Mar-22 5:15 
QuestionCode to Figure out x,y cords for CDC::Pie inside an CDC::Ellipse given % Pin
ForNow13-Mar-22 9:37
ForNow13-Mar-22 9:37 
AnswerRe: Code to Figure out x,y cords for CDC::Pie inside an CDC::Ellipse given % Pin
Mircea Neacsu14-Mar-22 16:41
Mircea Neacsu14-Mar-22 16:41 
GeneralRe: Code to Figure out x,y cords for CDC::Pie inside an CDC::Ellipse given % Pin
ForNow15-Mar-22 5:01
ForNow15-Mar-22 5:01 
QuestionIPv6 address compression code using vc++ Pin
Member 1252773510-Mar-22 17:12
Member 1252773510-Mar-22 17:12 
AnswerRe: IPv6 address compression code using vc++ Pin
Victor Nijegorodov10-Mar-22 21:06
Victor Nijegorodov10-Mar-22 21:06 
QuestionQuestions about EM_SETWORDBREAKPROC message and EDITWORDBREAKPROCA function Pin
ForNow10-Mar-22 6:02
ForNow10-Mar-22 6:02 
AnswerRe: Questions about EM_SETWORDBREAKPROC message and EDITWORDBREAKPROCA function Pin
RedDk10-Mar-22 8:22
RedDk10-Mar-22 8:22 
GeneralRe: Questions about EM_SETWORDBREAKPROC message and EDITWORDBREAKPROCA function Pin
ForNow10-Mar-22 9:35
ForNow10-Mar-22 9:35 

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.