|
This is where Linq to SQL adds elegance to the solution.
Given FormValues is the LinqToSQL representation of your table in which you store the huge array of 130 values.
string value = FormValues.SingleOrDefault(e => e.Name == fieldName);<br />
form[fieldName] = (value == null) ? "Some default" : value;
devboycpp wrote: Is it right majesty
Don't be an ass
only two letters away from being an asset
|
|
|
|
|
Mark Nischalke wrote: Don't be an ass
only two letters away from being an asset
I thought it is a kind of respect .
|
|
|
|
|
is it good? efficient ?
If you are a girl ... then ...
|
|
|
|
|
Hallo
i have a parametric query which fills a TableAdapter. I would like that the parameter value be read from the app config file.
How could I achieve this?
Thanks in advance
|
|
|
|
|
Search for Application Settings on MSDN, or Google/Bing it.
But are you sure?
The config file is an easily editable XML file. You will be leaving yourself open to mischief.
Is that better Luc?
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Hallo Henry and thanks for the reply.
I've already googled but I cannot find any resource to link TableAdapter and Application Settings.
I'm aware of possible issues, but they are not risky for us for the environment we are addressing to.
Thanks again.
|
|
|
|
|
In your original post you said "I would like that the parameter value be read from the app config file.".
Well if you read the stuff you found on Application Settings you should have found how to retrieve the value of the parameter from yourapp.exe.config. It is then a simple matter to use the retrieved value where you use your current parameter.
Or is it that part that you require assistance with? If so I misunderstood your OP.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
hi all
please help me
i am facing a problem in developing dynamic crystal reports
it shows error as "the report has no table"
as i am using kept blank report
following is the code
Dim con As New SqlConnection(ConfigurationManager.ConnectionStrings("satinconnectionstring").ConnectionString)
con.Open()
Dim cmd As New SqlCommand
cmd.Connection = con
cmd.CommandText = "select * from employee"
Dim da As New SqlDataAdapter(cmd.CommandText, con)
Dim ds As New DataSet
da.Fill(ds)
Dim myReportDocument As CrystalDecisions.CrystalReports.Engine.ReportDocument
myReportDocument = New CrystalDecisions.CrystalReports.Engine.ReportDocument()
myReportDocument.Load(Server.MapPath("CrystalReport2.rpt"))
myReportDocument.SetDataSource(ds)
'myReportDocument.Database.Tables(0).SetDataSource(ds)
CrystalReportViewer1.ReportSource = myReportDocument
CrystalReportViewer1.DataBind()
|
|
|
|
|
hiii
hey u found any solution of this error
please mail mee at vks.2009@gmail.com
|
|
|
|
|
can we make some games in .Net
|
|
|
|
|
|
yashwant vaishnav wrote: can we make some games in .Net
Yes.
Which type of game you want to developed ?
Abhijit Jana | Codeproject MVP
Web Site : abhijitjana.net
Don't forget to click "Good Answer" on the post(s) that helped you.
|
|
|
|
|
Pong.NET
|
|
|
|
|
Don't you think that parts of it smell enough already?
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
It could use a little refactoring, and some #5. So what?
|
|
|
|
|
Luc Pattyn wrote: and some #5
You have expensive tastes.
I was thinking more along the lines of air freshener.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Henry Minute wrote: air freshener
that's disgusting.
and if that is all it takes, then open up some windows instead. real cheap and real fresh.
|
|
|
|
|
Luc Pattyn wrote: open up some windows instead
XP, Vista or 7?
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
|
|
A fine example would be Quake II.NET, right here on CodeProject[^]
I are Troll
|
|
|
|
|
Hi,
Please if you can advise on following questions on integration with QuickBooks.
1. I need to connect to QuickBooks database. How can I connect and retrieve data from QuickBooks?
2. What type of connection do you use to connect to database?
3. Is there some tool that makes it easier?
Please answer on any questions of this, if you have programmed with QuickBooks.
Note: I am developing in C#
Thanks in advance
John T.
|
|
|
|
|
Read this[^]. Then read it again.
|
|
|
|
|
sir
how can i load media player control on vb.net when i select by browse any media file then that file will play .
thxx
|
|
|
|
|