|
i am creating setup project and i used DataDirectory in Connection string. now i inserted database in setup project but i cant fetch data from it after installing setup. how create setup with database with DataDirectory??? plz help instant....
|
|
|
|
|
alpesh koriya wrote: plz help instant.
That is going to get you ignored in a volunteer environment!
What database are you trying to deploy?
Id the "DataDirectory" a place holder and should be replaced with the path to the folder when the database resides?
What is the error you get?
Try reading the guidelines to get a reasonable response.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
I m not getting any error but after installation of setup when i open app. Cant connect with it.. I m using SqlServer as db
|
|
|
|
|
I used disconnected architecture
|
|
|
|
|
A quick scour of the internet gives this[^] answer. You have some reading ahead of you.
|
|
|
|
|
What's your connection string look like?
I assume it looks something like this:
... connectionString="Data Source=|DataDirectory|\MyDB.sdf" ...
Somewhere in your code (i.e. before you access the database), you should be setting the "DataDirectory" property; e.g.
AppDomain currentDomain = AppDomain.CurrentDomain;
currentDomain.SetData( "DataDirectory", myDbLocation );
Your program should "infer" the location of your installed db using, for xample:
Environment.SpecialFolder.CommonApplicationData
because (assuming your setup did a "typical" install), and based on the operating system, "user/app data" folders (where your db should be) wind up in different locations.
(If you did not install your db in the "standard" location, then you should find out where it did get installed and use that location).
Your installed app is not working because your installed db is not in the same relative location as it was during development.
|
|
|
|
|
dears
now i am in phase of self learning ios8 developing using C# throught using xamarin and vs2010
i am using and vmware in my win7 64bit hosting mac & xamarin developing host
now i tried a lot to built the solution and get the IPA file , but i stuck in phase of code signing , i need to make a self signed code , i will just test the IPA in my ipad
when i make a progress i will purchase the apple develop lic to be able to post it in the AppStore
any tips ??
waitting for your help
thanks all
|
|
|
|
|
For a better response you might want to look at asking your question here[α]
»»» <small>Loading Signature</small> «««
· · · <small>Please Wait</small> · · ·
|
|
|
|
|
Step 1: Read the instructions - no coding questions in the lounge.
Try asking in the coding forums, you have a much better chance of getting an answer there.
|
|
|
|
|
I'd actually dispute that it is a coding question. If the OP had not started the question with Dears and had focused slightly more on a strategy for achieving his goal he would probably have got away with it. I have seen similar from regulars!
Having said that he has obviously strayed into the wrong forum and has rightly been redirected.
I wonder what the word Lounge means in his local language!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
You just need to Hornswoggle your whojemaflip (obviously remembering to protect your tardis code from tachyon emissions) using the Round Tuit API. Once you've done that, it's all pretty obvious!
(other vendors are available)
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
Don't forget to reverse the polarity of the neutron flow before you start.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
My database Access have 3-columns : ID (int), Doc_no(string), Rcv_date(Date). I try to filter the newest row in the rows that have same Doc_no.
i have a query for database Access :
SELECT ID, Doc_No, Rcv_Date,
FROM [SDC Documents Record] A
WHERE (ID =
(SELECT TOP 1 ID
FROM [SDC Documents Record]
WHERE (A.Doc_No = Doc_No)
ORDER BY Rcv_Date DESC))
That query still work well with Query Tool in Access, but in Query Builder in Visual Stuido 12 - C#, there are message : "Error in WHERE clause near 'ORDER'" .
I don't know why. Plesea help me to fix it
leo
|
|
|
|
|
The ( puts the ORDER BY inside your WHERE clause, you have 2x ( and 3x )
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
SELECT ID, Doc_No, Rcv_Date, FROM the last comma is wrong - but with it, the query should not run in MS Access either.
|
|
|
|
|
Does anyone have C# sample code for calling a MySQL stored procedure through SSH connection using .PEM file for the SSH password?
|
|
|
|
|
|
Hi,
I have a grid where i have to filter the columns like multiple search filter and what ever records i get in the grid i am doing export to excel in c#
Everything was went well except the date column in the grid the date column data is in this format 2014/11//15
here is my c# code which i am using to remove special characters
private void getfilterdata(string filter, out string key, out string val)
{
key = string.Empty;
val = string.Empty;
if (!string.IsNullOrEmpty(filter))
{
string[] retval2 = filter.Split(new string[] { "data" }, StringSplitOptions.RemoveEmptyEntries);
if (retval2 != null && retval2.Count() > 1 && !string.IsNullOrEmpty(retval2[1]))
{
string[] strkeys = retval2[0].Split(new char[] { '"' }, StringSplitOptions.RemoveEmptyEntries);
if (strkeys.Length >= 3 && !string.IsNullOrEmpty(strkeys[3]))
{
key = strkeys[3];
val = RemoveSpecialCharacters(retval2[1]);
}
}
}
}
In the key its shows column name and in the val it shows data..
in the val i am getting data as 20141115.
So its not matching and while exporting its empty i am not getting any records becaus e of this
this is my code for RemoveSpecialCharacters
public static string RemoveSpecialCharacters(string str)
{
return Regex.Replace(str, "[^a-zA-Z0-9_.]+", "", RegexOptions.Compiled);
}
Any help plz.....
|
|
|
|
|
Are you using the Grid functions to export the content of the grid or are you exporting the underlying collection. If it is the grid then you should get the grid to reformat the date then export the data.
If you are exporting the underlying collection then it is just a matter of formatting the underlying DateTime data object. The most unambiguous format I have found to bd dd/MMMM/yyyy.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
|
I'm currently revisiting C# and oop after a few years programming PLCs. I'm looking at delegates and events. I was wondering what is the difference between a non-generic event handler and a generic one. Why would you use the generic one over the non-generic one. I've searched on the internet and can't find a satisfactory explanation.
Thanks in advance
|
|
|
|
|
|
My application is for Leave Module. now in that i used, employee can apply leave normally Seek Leave, Casual Leave and Paid leave. but Now i have to put condition like if total leave days(Count) is less than or equal to 2 then it will automatically goes in CL n PL will be invisible in drop down list. so what can i do for that?
|
|
|
|
|
Filter the underlying collection based on the number of days asked/available. To do this you trap the change event on the requesting control and then filter the collection accordingly.
More specific help will require more detail on the UI you are using.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Ok. I can understood. now i have change event on no of days calculation button. but what can i put a condition for that. can u help me in coding.
|
|
|
|