|
Oops, either he edited his post or I somehow missed it.
|
|
|
|
|
Hi I m writing an add-in for MS office products (Outlook, Word, Powerpoint etc. )
Now, I figured it out for outlook and power point but MS WORD seems different. What I ve used for outlook and power point is: I tried it for WORD too but couldnt get it. If any of u know the application object / commandbar usage for word please let me know.
Or if theres a way to integrate it to all office products at once. Durind the project creation I already picked the office products that im gonna use.
public void OnStartupComplete(ref System.Array custom)
{
CommandBars commandBars = null;
try
{
//outlook
commandBars = ((Outlook.Application)applicationObject).ActiveExplorer().CommandBars;
}
catch{
// powerpoint
commandBars = ((PowerPoint.Application)applicationObject).CommandBars;
}
|
|
|
|
|
When I use;
commandBars = ((Word.Application)applicationObject).CommandBars;
and set the debugging mode for word i get an error even though all the word references and dll s are added to the project.
It works with outlook and powerpoint.
|
|
|
|
|
i want to change the postions of div scrolls so i made function in javascript. now i want to call tht function on "onscroll event" in div tag. i did
div id="div1" onscroll="setscrollpostions();" style="OVERFLOW: auto"
but it doesnt work
pls tell me the solution.
Thanks
Taran
|
|
|
|
|
Does any part of this have anything at all to do with C#? Huh. Does it?
You may have missed that honking great bit at the top that stated that this is a C# discussion board. If you did, let me point this out to you - this is the C# discussion board, not the Visual C++ forum, not the ASP.NET forum, not the SQL/ADO.NET forum - it's the C# forum. Now, given this information do you really think that this is the right place to post this question? Think before you answer, because I will be asking questions of you later on.
Now - you may want to move this over to the Web Development forum. You'll know it when you see it because it's got Web Development in the title. Not to be confused with the C# forum in any way, shape or form.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Hi I am using Enterprise Library Configuration(Application block).
I am getting log date time is 5 hours 30 min difference from actual timings,
Can any one suggest how to get system timings.
I have updated config file as
<formatters>
<add template="Timestamp: {timestamp}
Message: {message}
Category: {category}
Priority: {priority}
EventId: {eventid}
Severity: {severity}
Title:{title}
Machine: {machine}
Application Domain: {appDomain}
Process Id: {processId}
Process Name: {processName}
Win32 Thread Id: {win32ThreadId}
Thread Name: {threadName}
Extended Properties: {dictionary({key} - {value}
)}"
="" type="Microsoft.Practices.EnterpriseLibrary.Logging.Formatters.TextFormatter, Microsoft.Practices.EnterpriseLibrary.Logging, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" name="Text Formatter">
|
|
|
|
|
How to set Column size to DataGrid Column?
As per following code I am setting data into DataGrid
dgRptSpdList.DataBindings.Clear();
if (dsLocalDb != null ) dsLocalDb.Clear();
EOD.cGlobal.stobjGlobal.dbLocalCmd.CommandText = strQuery;
darLocalDb = new OleDbDataAdapter(EOD.cGlobal.stobjGlobal.dbLocalCmd);
dsLocalDb = new DataSet();
darLocalDb.Fill(dsLocalDb,"tmpSuspended");
dgRptSpdList.SetDataBinding(dsLocalDb,"tmpSuspended");
|
|
|
|
|
foreach (DataGridViewColumn col in dgRptSpdList.Columns)
col.Width = 120;
Greetings
Kaine
|
|
|
|
|
I have an app that moves a window left, right, up or down by clicking the appropriate button. At this time, I have to repetitively click the button to move it. How can I make the button continuous, so I only have to hold the button down, and it continues to move until I let off? In addition to that, I still want the ability to move it one click at a time, as well.
I searched everywhere, but haven't found anything that gives me what I'm looking for.
Thanks...
|
|
|
|
|
You need to override the button class, and you need to fire a timer when the mouse is down to generate click events.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Excellent! *rubbing hands together, with an evil grin on my face*
Now, how do I do that?
|
|
|
|
|
You could also just do it the easy way:
Click once on the button, and then keep holding down the Enter-key on your keyboard.
Virtual1ty
"Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
|
|
|
|
|
There's no keyboard. This is for a touch screen.
|
|
|
|
|
Oh, okay
Virtual1ty
"Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
|
|
|
|
|
I created a new windows form with a button and a rich text box. The following code produces the effect you want. Granted, you'll need to add more logic in there, but it should be enough to get your started:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
this.m_Timer = new Timer();
this.m_Timer.Interval = 100;
this.m_Timer.Tick += new EventHandler(m_Timer_Tick);
}
private Timer m_Timer;
private void button1_MouseDown(object sender, MouseEventArgs e)
{
lock (this.m_Timer)
{
if (!this.m_Timer.Enabled)
this.m_Timer.Start();
}
}
private void button1_MouseUp(object sender, MouseEventArgs e)
{
lock (this.m_Timer)
{
if (this.m_Timer.Enabled)
this.m_Timer.Stop();
}
}
private void button1_Click(object sender, EventArgs e)
{
this.richTextBox1.Text += string.Format("Clicked - {0}{1}",
DateTime.Now.ToLongTimeString(),
Environment.NewLine);
}
private void m_Timer_Tick(object sender, EventArgs e)
{
this.button1_Click(this.button1, EventArgs.Empty);
}
}
}
|
|
|
|
|
Yup...that will get me headed in the right direction. Thank you very much.
|
|
|
|
|
Hello Every 1.
I have a strange problem with webclient. I have the following method in a class created to download files from a website. I download files sequentially i.e download one file dispose the download class object then create a new object and call the download method and so on....
public void DownloadVideo()
{
try
{
WebClient wcDownload = new WebClient();
webRequest = (HttpWebRequest)WebRequest.Create(_VideoUrl);
webRequest.Credentials = CredentialCache.DefaultCredentials;
webResponse = (HttpWebResponse)webRequest.GetResponse();
if (webResponse.ResponseUri.ToString() != "http://www.xyz.com/error.htm")
{
Int64 fileSize = webResponse.ContentLength;
strResponse = wcDownload.OpenRead(_VideoUrl);
strLocal = new FileStream(_VideoPath, FileMode.Create, FileAccess.Write, FileShare.None);
int bytesSize = 0;
byte[] downBuffer = new byte[2048];
while ((bytesSize = strResponse.Read(downBuffer, 0, downBuffer.Length)) > 0)
{
strLocal.Write(downBuffer, 0, bytesSize);
UpdateVideoProgressEventArgs uvpea = new UpdateVideoProgressEventArgs(strLocal.Length, fileSize);
UpdateVideoProgressEvent(this, uvpea);
}
}
}
catch (Exception exp)
{
MessageBox.Show("Error in startDownload due to : " + exp.Message);
}
finally
{
if (strLocal != null)
strLocal.Close();
if (strResponse != null)
strResponse.Close();
webRequest = null;
webResponse = null;
}
}
It works fine for the first file download but fails for the second file because it just hangs up @
strResponse = wcDownload.OpenRead(_VideoUrl);
and eventually time out.
o O º(`'·.,(`'·., ☆,.·''),.·'')º O o°
»·'"`»* *☆ t4ure4n ☆* *«·'"`«
°o O º(,.·''(,.·'' ☆`'·.,)`'·.,)º O o°
|
|
|
|
|
Here i am facing a problem
I m displaying a gridview data in that i want the sno is automatically to be generated for each and every row the grid is binding
can any one pls help me
Thanks in advance
sai krishna
|
|
|
|
|
|
such create a dummy cloumn and assign current row index value to the column...that's it..my friend
|
|
|
|
|
i only got it
<
asp:TemplateField HeaderText="Item Count">
<itemtemplate>
<%#Container.DataItemIndex + 1%>
Thanks
sai krishna
|
|
|
|
|
welcome...
|
|
|
|
|
hai Friend,
Please show how to edit / Insert the text to a csv file at middle
when multiuser working with the same file
kannan.R
kannan_chinna@email.com
|
|
|
|
|
RamasamyKannan wrote: when multiuser working with the same file
That's not really possible. If your users write to the same file, either they will do it at the same time and one will fail, or the last one to write, will win, and all changes are lost. Unless you were to do some sort of diff and merge in any changes that occured with your own changes, which is complex.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|