Click here to Skip to main content
15,886,857 members
Home / Discussions / C#
   

C#

 
QuestionHow to lock the msi setup for a specific period? Pin
svt gdwl7-May-09 22:20
svt gdwl7-May-09 22:20 
QuestionGPS/GSM application Pin
Nanyoe7-May-09 22:09
Nanyoe7-May-09 22:09 
Questionusing printer driver in vb,net Pin
tauras817-May-09 21:06
tauras817-May-09 21:06 
AnswerRe: using printer driver in vb,net Pin
Mycroft Holmes7-May-09 21:39
professionalMycroft Holmes7-May-09 21:39 
Questionc# Trackbar Arrowkeys bug Pin
VoNa197-May-09 20:32
VoNa197-May-09 20:32 
AnswerRe: c# Trackbar Arrowkeys bug Pin
Dave Kreskowiak8-May-09 1:11
mveDave Kreskowiak8-May-09 1:11 
GeneralRe: c# Trackbar Arrowkeys bug Pin
VoNa198-May-09 1:56
VoNa198-May-09 1:56 
QuestionHow to get Data labels In charts using C# Pin
amitabha20077-May-09 20:11
amitabha20077-May-09 20:11 
I want to put datalabels and legendkeys in powerpoint using c#. how to achieve this? here is the code below

private void button1_Click(object sender, EventArgs e)
{
String strTemplate;
strTemplate =
"C:\\Program Files\\Microsoft Office\\Templates\\Presentation Designs\\Blends.pot";

PowerPoint.Application objApp;
PowerPoint.Presentations objPresSet;
PowerPoint._Presentation objPres;
PowerPoint.Slides objSlides;
PowerPoint._Slide objSlide;
PowerPoint.TextRange objTextRng;
Graph.Chart objChart;
Graph.DataSheet dataSheet;
//Create a new presentation based on a template.
objApp = new PowerPoint.Application();
objApp.Visible = MsoTriState.msoTrue;
objPresSet = objApp.Presentations;
objPres = objPresSet.Open(strTemplate,
MsoTriState.msoFalse, MsoTriState.msoTrue, MsoTriState.msoTrue);
objSlides = objPres.Slides;
objSlide = objSlides.Add(1, PowerPoint.PpSlideLayout.ppLayoutTitleOnly);
objTextRng = objSlide.Shapes[1].TextFrame.TextRange;
objTextRng.Text = "My Chart";
objTextRng.Font.Name = "Comic Sans MS";
objTextRng.Font.Size = 48;

objChart = (Graph.Chart)objSlide.Shapes.AddOLEObject(150, 150, 480, 320,
"MSGraph.Chart.8", "", MsoTriState.msoFalse, "", 0, "",
MsoTriState.msoFalse).OLEFormat.Object;
dataSheet = objChart.Application.DataSheet;


dataSheet.Cells[1, 2] = "abc";
dataSheet.Cells[2, 2] = "50";
dataSheet.Cells[2, 3] = "40";
dataSheet.Cells[2, 4] = "50";
dataSheet.Cells[2, 5] = "50";
dataSheet.Cells[3, 2] = "60";
dataSheet.Cells[3, 3] = "70";
dataSheet.Cells[3, 4] = "80";
dataSheet.Cells[3, 5] = "60";
dataSheet.Cells[4, 2] = "50";
dataSheet.Cells[4, 3] = "40";
dataSheet.Cells[4, 4] = "50";
dataSheet.Cells[4, 5] = "50";
objChart.Application.Update();

objChart.Legend.Position = Graph.XlLegendPosition.xlLegendPositionBottom;

objChart.HasTitle = true;
objChart.ChartTitle.Text = "Here it is...";

objPres.SaveAs("C:\\abc.ppt", PowerPoint.PpSaveAsFileType.ppSaveAsPresentation, MsoTriState.msoTrue);
objPres.Close();
objApp.Quit();
}
QuestionVOIP Pin
imranliaqat7-May-09 20:10
imranliaqat7-May-09 20:10 
AnswerRe: VOIP Pin
Mycroft Holmes7-May-09 21:36
professionalMycroft Holmes7-May-09 21:36 
QuestionQuery to get number of tables Pin
arun_pk7-May-09 19:39
arun_pk7-May-09 19:39 
AnswerRe: Query to get number of tables Pin
Spunky Coder7-May-09 20:51
Spunky Coder7-May-09 20:51 
Questionpop up progress bar Pin
S K Y7-May-09 19:39
S K Y7-May-09 19:39 
AnswerRe: pop up progress bar Pin
N a v a n e e t h7-May-09 19:41
N a v a n e e t h7-May-09 19:41 
GeneralRe: pop up progress bar Pin
S K Y7-May-09 19:52
S K Y7-May-09 19:52 
GeneralRe: pop up progress bar Pin
Dave Kreskowiak8-May-09 1:00
mveDave Kreskowiak8-May-09 1:00 
Questionneed a print monitor component Pin
vijayatbics7-May-09 19:31
vijayatbics7-May-09 19:31 
AnswerRe: need a print monitor component Pin
OriginalGriff7-May-09 22:02
mveOriginalGriff7-May-09 22:02 
Questionlisten to a network printer? Pin
vijayatbics7-May-09 19:18
vijayatbics7-May-09 19:18 
AnswerRe: listen to a network printer? Pin
Spunky Coder7-May-09 20:53
Spunky Coder7-May-09 20:53 
AnswerRe: listen to a network printer? Pin
Dave Kreskowiak8-May-09 0:49
mveDave Kreskowiak8-May-09 0:49 
QuestionDirectoryInfo.GetDirectories() search patterns Pin
dybs7-May-09 18:22
dybs7-May-09 18:22 
AnswerRe: DirectoryInfo.GetDirectories() search patterns Pin
Dave Kreskowiak8-May-09 0:48
mveDave Kreskowiak8-May-09 0:48 
GeneralRe: DirectoryInfo.GetDirectories() search patterns Pin
dybs8-May-09 3:00
dybs8-May-09 3:00 
AnswerRe: DirectoryInfo.GetDirectories() search patterns Pin
cascadtx25-Mar-11 17:20
cascadtx25-Mar-11 17:20 

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.