|
Is not app.config part of application assembly? Modifying it would be modifying assembly. Would be easier to just add separate configuration file?
No more Mister Nice Guy... >: |
|
|
|
|
|
I don't think the installer is the right place for this. Instead, on startup, if you haven't got the settings you need, direct the user to the 'database settings' dialogue.
|
|
|
|
|
sathish17 wrote: Can someone guide me with a starting point on this issue
Google using the following phrase
microsoft installer custom action
|
|
|
|
|
Check this link
www.codeproject.com/Tips/446121/Adding-connection-string-during-installation
|
|
|
|
|
RESPECTED SIR/FRIENDS
I AM NEW IN C#.NET & SQL 2005, REPORT DESIGN IN CRYSTAL 10
WHEN REPORT VIEWER CHOOSE FILE RPITEMLST.RPT THEN "Load Report Failed" ERROR COME. PLEASE HELP ME.
|
|
|
|
|
DON'T SHOUT. Using all capitals is considered shouting on the internet, and rude (using all lower case is considered childish). Use proper capitalisation if you want to be taken seriously.
Edit your question and fix it.
If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.
|
|
|
|
|
RESPECTED SIR/FRIENDS
I AM NEW IN C#.NET & SQL 2005 , I AM DEVELOPING WEBBASE APPLICATION , BELOW ERROR COME WHEN DATA SET ADD PLEASE HELP ME. THANKING YOU IN ADVANCE.
---------------------------
Microsoft Visual Studio
---------------------------
Failed to open a connection to the database"A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)"Check the connection and try again.
---------------------------
OK Help
---------------------------
---------------------------
Microsoft Visual Studio
---------------------------
This server version is not supported. You must have Microsoft SQL Server 2005 or later.
---------------------------
OK
---------------------------
|
|
|
|
|
DON'T SHOUT. Using all capitals is considered shouting on the internet, and rude (using all lower case is considered childish). Use proper capitalisation if you want to be taken seriously.
Edit your question and fix it.
If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.
|
|
|
|
|
It is database accessibility issue. Check connection string that you are using in your application.
|
|
|
|
|
I am using Visual studio 2005(.NET framework 2.0) .My project is window application and using c# language. We are having word templates created in office 2003, 2007 and 2010.
I want to search text (string) in word template (.dot/.doc/.docx).This text/string is exist in two places in word doc :
1) table
QuestionTitle Issueno description Pageno Title
x 55 xyz
2) title/subtitle
1.2.1 xyz
I want the page no and title/subtitle to copy into table of word doc.
For an example : table is exist on page 1 and having column value as xyz under column description of word doc. Title/Subtitle 1.2.1 is exist on page no 3 with value xyz in word doc.
Now I want to update table by page no and title/subtitle of word doc:
QuestionTitle Issueno description Pageno Title
x 55 xyz 3 1.2.1
I am not able to find c# code to search text/string(xyz) in word doc and modify table with page no(3) and title(1.2.1) in word doc.
Please help me to find c# code.
|
|
|
|
|
|
Can you please give me c# code to find pageno and update table in word doc ?
|
|
|
|
|
I don't have it. You need to read the documentation for yourself and use the features of the Interop library.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
I read the documentation but not able to find the pageno of searched text and update the table.
|
|
|
|
|
Maybe you need to take a different approach and read the document one page at a time, in order to match the text with its page number.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
Can C# do a real BitBLT in Windows Forms ?
I am having difficulty figuring out the syntax and implementation of doing a BitBLT in C#.
I found This Link [^] about BitBLT on the MSDN site, which is for C++ but couldn't find anything about doing it in C#. All other searches for the two terms, "C#" and "BitBLT" in the same context led to nowhere and worse results.
The two major "Duh" points for me are figuring out what the HDC values are for the source and destination.
They are listed as "...A handle to the [source/destination] device context..." (no quotes, no dots) but when I go looking for how to determine what that is, or how to obtain it, I wind up in circles.
I found some tangential references to the C# Bitmap class, and if that's the way you do a BitBLT in C#, okay, just tell me how.
The Syntax and implementation are the thing.
Let me think, to keep the question simple, lets say I have a rectangle located at X1, Y1, with width W1 and Height H1, (in pixels, I presume) and I want to move that to location X2, Y2.
The BitBLT question is based on a desire to let the hardware do it without the processor spending cycles. I don't care if I use BitBLT or Bitmap or whatever. I just want to know How to do that in C#, and the faster it executes, the better.
If this already has examples waiting to read, somebody please point me to them.
|
|
|
|
|
C# with WPF uses DirectX; why not just change the coordinates of the rectangle to "move" it and observe the performance? The performance may already be satisfactory using C# "native" code. You can even use a WPF "Storyboard" control to animate the movement of the rectangle.
In any event, one should (generally) worry about optimizations later than sooner.
|
|
|
|
|
Thanks Gerry, that is exactly what I'm trying to study and grasp right now.
Clues for the learner are welcome.
I'm trying to find the syntax for moving a rectangle from point A,B to point X,Y on the screen, and It's anything but obvious at this moment. I have been searching here, MSDN, and five or ten other sites with "C#, DirectX, Rectangle, Move" and so on, and I have yet to see the syntax.
I came across "clone" which may lead somewhere.
Anyway, if you can point me to a piece of sample code that shows how to move a rectangle A`B`C`D to a position at X,Y on the screen, please do so.
Certainly that has to be a perennially useful example.
Don't know how to post a screen cap of the form1 here or else I would.
|
|
|
|
|
Are you trying to do this in Windows Forms? If you are, simply use double buffering - it's very easy to set up as shown in this[^] article.
|
|
|
|
|
Here's a small C# WPF "code-only" example that allows you to move a rectangle using sliders. You can decide for yourself if the performance is acceptable. (You can accomplish the same thing using XAML)
using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Media;
using System.Windows.Shapes;
namespace WpfApplication1 {
class Program {
[STAThread]
static void Main( string[] args ) {
Window window = new Window() {
WindowStartupLocation = WindowStartupLocation.CenterScreen,
SizeToContent = SizeToContent.WidthAndHeight
};
Canvas canvas = new Canvas() { Width = 400, Height = 400 };
Rectangle rect = new Rectangle() {
Width = 20,
Height = 20,
Fill = Brushes.MediumBlue
};
canvas.Children.Add( rect );
Slider sliderY = new Slider() {
Orientation = Orientation.Vertical,
Maximum = 300,
Minimum = 100,
Value = 200
};
Slider sliderX = new Slider() {
Orientation = Orientation.Horizontal,
Maximum = 300,
Minimum = 100,
Value = 200
};
StackPanel sp1 = new StackPanel() { Orientation = Orientation.Horizontal };
StackPanel sp2 = new StackPanel() { Orientation = Orientation.Vertical };
sp1.Children.Add( canvas );
sp1.Children.Add( sliderY );
sp2.Children.Add( sp1 );
sp2.Children.Add( sliderX );
window.Content = sp2;
Binding bindingX = new Binding();
bindingX.Source = sliderX;
bindingX.Path = new PropertyPath( Slider.ValueProperty );
rect.SetBinding( Canvas.LeftProperty, bindingX );
Binding bindingY = new Binding();
bindingY.Source = sliderY;
bindingY.Path = new PropertyPath( Slider.ValueProperty );
rect.SetBinding( Canvas.TopProperty, bindingY );
Application app = new Application();
app.Run( window );
}
}
}
|
|
|
|
|
I wanna get the innertext from the html but some divs has not an id. And i cant reach then.. for example in this code how can i get 'İnşaat Mühendisliği' etc.
<div class="liste">
<div style="width:90px;"> </div>
<div style="width:160px;"><a id="ctl00_cphAlt_rpKisiListesi_ctl00_lbAdGuid" href="javascript:__doPostBack('ctl00$cphAlt$rpKisiListesi$ctl00$lbAdGuid','')">Abdulkerim Gökbulut</a> </div>
<div style="width:250px;">İnşaat Fakültesi </div>
<div style="width:250px;">İnşaat Mühendisliği </div>
</div>
<div class="liste">
<div style="width:90px;"> </div>
<div style="width:160px;"><a id="ctl00_cphAlt_rpKisiListesi_ctl01_lbAdGuid" href="javascript:__doPostBack('ctl00$cphAlt$rpKisiListesi$ctl01$lbAdGuid','')">A. Buğrahan Gökso...</a> </div>
<div style="width:250px;">İnşaat Fakültesi </div>
<div style="width:250px;">İnşaat Mühendisliği </div>
</div>
<div class="liste">
<div style="width:90px;"> </div>
<div style="width:160px;"><a id="ctl00_cphAlt_rpKisiListesi_ctl02_lbAdGuid" href="javascript:__doPostBack('ctl00$cphAlt$rpKisiListesi$ctl02$lbAdGuid','')">Abdulmecit Gökçe</a> </div>
<div style="width:250px;">Fen Bilimleri Enstitüsü </div>
<div style="width:250px;">Moleküler Biyoloji ve Genetik </div>
</div>
|
|
|
|
|
Well, if it were me, I'd do it using JavaScript, and not C#.
|
|
|
|
|
Then he can discover that innerText only works in one family of browsers...
Cheers,
Peter
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
|
By reading the html source from top to bottom...
What do you actually want to do? Where does that html come from - is it produced by an application you have the source code?
To me, it looks like a textual representation of objects with 3 properties. And of course, you should find out the subject of study of the correct student...
|
|
|
|