I would guess that (say) string newstr (not in code) = msg1+msg2; ....should show up somewhere and that there should be an instruction to print newstr. Since changestr() is of type void the addition of the two strings and the printing of their sum variable should occur within this function.
#include "stdafx.h"
#include <iostream>
#include <string>
using namespace std;
void changestr(string &str1, string str2)
{
int numChar1;
int numChar2;
int totalChar;
int index = 0;
int start1 = 0;
int start2 = 0;
int end = 3;
string TempStr;
char tempstr1[100];
thanks guys. thanks bluecoder. your code works fine with less characters in each string. but when i enter more than 15 characters in each string, the program just stuck halfway. i was then prompt that the program triggered a breakpoint. i'm really confused.