Click here to Skip to main content
15,885,792 members
Home / Discussions / C#
   

C#

 
QuestionHow to loop through a currencyManager Pin
Ista2-Sep-03 16:58
Ista2-Sep-03 16:58 
GeneralOverriding DataGrid::OnPaint Pin
Ista2-Sep-03 16:57
Ista2-Sep-03 16:57 
GeneralRe: Overriding DataGrid::OnPaint Pin
A.Wegierski3-Sep-03 19:41
A.Wegierski3-Sep-03 19:41 
GeneralRe: Overriding DataGrid::OnPaint Pin
Ista4-Sep-03 3:18
Ista4-Sep-03 3:18 
GeneralNetwork Management Tools (NMT) Pin
loveprogramming2-Sep-03 16:39
loveprogramming2-Sep-03 16:39 
Questionun-editable combobox? Pin
zecodela2-Sep-03 16:29
zecodela2-Sep-03 16:29 
AnswerRe: un-editable combobox? Pin
Ista2-Sep-03 16:47
Ista2-Sep-03 16:47 
GeneralGetting the project's/executable's root path Pin
tsigo2-Sep-03 15:04
tsigo2-Sep-03 15:04 
I just wasted a massive amount of time debugging my application and it's all because of a directory path error Smile | :)

I currently save an XML data file "movies.xml" in the root path of my project's .exe file. The problem is that after I use an OpenFileDialog to select some data to add to the XML file, and then save it, the file's saved in the directory that was selected, rather than the root path I need.

How can I point a StreamWriter, for example, to the absolute path of my executable dynamically?

I'd imagine it's something in the System.Reflection namespace, but I can't find it and don't know where to start looking.

Also, is there a way to prevent the directory selection of an OpenFileDialog from overwriting the current "working" path?
GeneralRe: Getting the project's/executable's root path Pin
David Stone2-Sep-03 15:17
sitebuilderDavid Stone2-Sep-03 15:17 
GeneralRe: Getting the project's/executable's root path Pin
tsigo2-Sep-03 15:26
tsigo2-Sep-03 15:26 
GeneralConnection to network shares Pin
Trojan2K2-Sep-03 13:09
Trojan2K2-Sep-03 13:09 
GeneralRe: Connection to network shares Pin
Mazdak2-Sep-03 20:18
Mazdak2-Sep-03 20:18 
GeneralSQLDMO Pin
yyf2-Sep-03 12:18
yyf2-Sep-03 12:18 
QuestionHow I can position a form? Pin
yyf2-Sep-03 11:19
yyf2-Sep-03 11:19 
AnswerRe: How I can position a form? Pin
yyf2-Sep-03 11:31
yyf2-Sep-03 11:31 
GeneralDatabindings Pin
yyf2-Sep-03 10:44
yyf2-Sep-03 10:44 
GeneralRe: Databindings Pin
Gilles B.2-Sep-03 12:41
sussGilles B.2-Sep-03 12:41 
GeneralRe: Databindings Pin
yyf2-Sep-03 12:59
yyf2-Sep-03 12:59 
GeneralRe: Databindings Pin
Ista2-Sep-03 16:54
Ista2-Sep-03 16:54 
GeneralDataBindings Pin
yyf2-Sep-03 10:27
yyf2-Sep-03 10:27 
GeneralRe: DataBindings Pin
Ista2-Sep-03 16:56
Ista2-Sep-03 16:56 
GeneralAuthenticating to a web site Pin
roberthanacek2-Sep-03 10:24
roberthanacek2-Sep-03 10:24 
GeneralRe: Authenticating to a web site Pin
leppie2-Sep-03 12:09
leppie2-Sep-03 12:09 
GeneralSingleCall Objects not Disposing Pin
0siris2-Sep-03 8:03
0siris2-Sep-03 8:03 
GeneralOverride the asterisk and row arrow in datagrid Pin
Ista2-Sep-03 7:02
Ista2-Sep-03 7:02 

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.