Click here to Skip to main content
15,900,816 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionDoubt about the path of the File? Pin
Subin Alex13-May-09 18:40
Subin Alex13-May-09 18:40 
AnswerRe: Doubt about the path of the File? Pin
Ramesh Swaminathan13-May-09 18:49
Ramesh Swaminathan13-May-09 18:49 
AnswerRe: Doubt about the path of the File? Pin
N a v a n e e t h13-May-09 18:54
N a v a n e e t h13-May-09 18:54 
Questionweb.config identity impersonate - pwd in web.config [modified] Pin
devvvy13-May-09 17:38
devvvy13-May-09 17:38 
QuestionPlaying With The Club Starter Kit Again... [modified] Pin
Roger Wright13-May-09 17:16
professionalRoger Wright13-May-09 17:16 
QuestionInsert empty datarow into datatable Pin
cocoonwls13-May-09 17:03
cocoonwls13-May-09 17:03 
AnswerRe: Insert empty datarow into datatable Pin
cocoonwls13-May-09 17:46
cocoonwls13-May-09 17:46 
Questionprint customised footer on every page on client machine while printing Pin
Anand Desai13-May-09 11:37
Anand Desai13-May-09 11:37 
Hi coders,

Currently I am going through a bit complicated problem. It would be great if I get help from you.
The issues is, I have "print this page" button on each page on my site. Where I have called "window.print()". Now my client wants customised footer on that including his logo etc. So now, on that print button, I popup a window and pass the content to another predifed page with footer.
Its working nice if only 1 page print is their, but if content is big and expands to 2 or more pages then my footer is printed on last page only (Obviously). So, I wrote a code for manipulating the Registry Key for "Microsoft\\Internet Explorer\\PageSetup". Code is below:

string strPath = "Software\\Microsoft\\Internet Explorer\\PageSetup";
Microsoft.Win32.RegistryKey oKey = null;

/* The following lines of code takes care that error does not occur if registry settings are not at proper path.*/
oKey = Microsoft.Win32.Registry.CurrentUser.OpenSubKey (strPath, true);
if (oKey != null)
{
    oKey = Microsoft.Win32.Registry.CurrentUser.OpenSubKey(strPath, true);
}
else
{
  oKey = Microsoft.Win32.Registry.LocalMachine.OpenSubKey (strPath, true);
}

string strKey = "footer";
//object oValue = "&u&b&d";
object oValue = "test footer";
oKey.SetValue (strKey, oValue);
strKey = "header";
oValue = "&d";
oKey.SetValue(strKey, oValue);
 /* You can also get the value in registry by following line of code
    string strValue=oKey.GetValue (strKey).ToString();*/
 oKey.Close();


But, I think this will modify Server machine's registry value not client machine's.

Is their any other way to cop-up with this issue??

Any help will be greatful.

Thanks,

Anand Desai
Developer
Atharva Infotech

AnswerRe: print customised footer on every page on client machine while printing Pin
Christian Graus13-May-09 11:45
protectorChristian Graus13-May-09 11:45 
GeneralRe: print customised footer on every page on client machine while printing Pin
Anand Desai13-May-09 12:12
Anand Desai13-May-09 12:12 
QuestionProblem with Persmission for Creating website in IIS Dynamically [modified] Pin
vurugonda13-May-09 10:12
vurugonda13-May-09 10:12 
Questiondeterminte async postback trgger event Pin
C. L. Phillip13-May-09 10:00
C. L. Phillip13-May-09 10:00 
AnswerRe: determinte async postback trgger event Pin
MidwestLimey13-May-09 10:19
professionalMidwestLimey13-May-09 10:19 
Questionmenu items Pin
hahii13-May-09 9:45
hahii13-May-09 9:45 
AnswerRe: menu items Pin
AlexeiXX313-May-09 9:56
AlexeiXX313-May-09 9:56 
GeneralRe: menu items Pin
hahii13-May-09 11:36
hahii13-May-09 11:36 
GeneralRe: menu items Pin
AlexeiXX313-May-09 11:42
AlexeiXX313-May-09 11:42 
GeneralRe: menu items Pin
hahii13-May-09 13:59
hahii13-May-09 13:59 
QuestionBaffling behaviour with IE7 & Jquery Pin
bVagadishnu13-May-09 9:18
bVagadishnu13-May-09 9:18 
AnswerRe: Baffling behaviour with IE7 & Jquery Pin
bVagadishnu13-May-09 11:03
bVagadishnu13-May-09 11:03 
QuestionPlease Help Me in GridView Pin
mohanbalal13-May-09 8:05
mohanbalal13-May-09 8:05 
AnswerRe: Please Help Me in GridView Pin
Christian Graus13-May-09 9:07
protectorChristian Graus13-May-09 9:07 
GeneralRe: Please Help Me in GridView Pin
mohanbalal13-May-09 9:57
mohanbalal13-May-09 9:57 
GeneralRe: Please Help Me in GridView Pin
Christian Graus13-May-09 11:12
protectorChristian Graus13-May-09 11:12 
GeneralRe: Please Help Me in GridView Pin
CaptainSeeSharp29-May-09 15:05
CaptainSeeSharp29-May-09 15:05 

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.