|
hi friend
Thanks for respose
i am using this code in installer class . and when my setup run then it say msi not found Please Help me.
Code:-
Private Sub Installer1_AfterInstall(ByVal sender As Object, ByVal e As System.Configuration.Install.InstallEventArgs) Handles Me.AfterInstall
Dim p As System.Diagnostics.Process
p = System.Diagnostics.Process.Start(Application.StartupPath + "\UccApiSdk.msi")
p.WaitForExit()
End Sub
Piyush Vardhan Singh
p_vardhan14@rediffmail.com
http://holyschoolofvaranasi.blogspot.com
http://holytravelsofvaranasi.blogspot.com
|
|
|
|
|
We are implemenmting the MicroSoft Indexing search in our site.our client asked to give provision to search the main folders only, not for SubFolders. So we decided to use the SHALLOW TRAVERSAL OF. But still now we didnt get the correct syntax.
My code:
System.Data.OleDb.OleDbConnection odbSearch = new System.Data.OleDb.OleDbConnection("Provider=\"MSIDXS\";Data Source=\"Agaram\";");
System.Data.OleDb.OleDbCommand cmdSearch = new System.Data.OleDb.OleDbCommand();
cmdSearch.Connection = odbSearch;
odbSearch.Open();
cmdSearch.CommandText = "select Vpath, path, FileName, size, write, attrib, Characterization, DocTitle, rank from scope('' SHALLOW TRAVERSAL OF ("/Software")'') where FREETEXT(contents,'" + searchText + "') order by rank desc ";
System.Data.OleDb.OleDbDataAdapter SqlDa = new System.Data.OleDb.OleDbDataAdapter(cmdSearch);
DataSet Ds = new DataSet();
SqlDa.Fill(Ds);
odbSearch.Close();
/Software is the main folder in my project
The Error is at the Select Query.
Error Details:
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS1002: ; expected
Source Error:
Line 34: cmdSearch.CommandText = "select Vpath, path, FileName, size, write, attrib, Characterization, DocTitle, rank from scope('' SHALLOW TRAVERSAL OF ("/Software")'') where FREETEXT(contents,'" + searchText + "') order by rank desc ";
|
|
|
|
|
If
Moghan wrote: ("/Software")'') where FREETEXT(contents,'" + searchText + "') order by rank desc ";
is a new line of code then you need to put a + in the line before at the end so that it knows its the end of that line of code
|
|
|
|
|
Thanks for ur reply. Harini's answer working fine.
|
|
|
|
|
Hi
You need to split the string "\Software" as "\"" for each double quotes with escape character:
See below:
cmdSearch.CommandText = "SELECT Vpath, path, FileName, size, write, attrib, Characterization, DocTitle, rank FROM SCOPE('shallow traversal of " + "\"" + "/Software" + "\"" + "') where FREETEXT(contents,'" + searchText + "') order by rank desc ";
Let me know if that works.
Harini
|
|
|
|
|
Hi Harini,
Its working fine now. Thank u vary much. From morning onwards i tried a lot.
|
|
|
|
|
Ok ... That is good!!
Harini
|
|
|
|
|
Hi,
One more thing, replace the variable searchText as parameter to avoid security (SQL Injection).
Harini N K wrote: cmdSearch.CommandText = "SELECT Vpath, path, FileName, size, write, attrib, Characterization, DocTitle, rank FROM SCOPE('shallow traversal of " + "\"" + "/Software" + "\"" + "') where FREETEXT(contents,'" + searchText + "') order by rank desc ";
This is a good coding practice in any langauge.
Harini
|
|
|
|
|
ok.Thanks for ur suggestion
|
|
|
|
|
i write this code:
javascript:window.open('a.html') i want open a.html with small size how can i set the size of my form in my code?
|
|
|
|
|
use something like this:
window.open (this.href, 'popupwindow','width=1000,height=800');return false;"
|
|
|
|
|
thanks for ur help, thats right i write this for:
javascript:window.open('../a.html','_blank','height=200,width=300,menubar=yes');
and thats right but return an object, do u know where should i write return false?
when i write javascript:window.open('../a.html','_blank','height=200,width=300,menubar=yes');return false;
it give an error "return statement outside of function"
|
|
|
|
|
That should work, where is the code, is it in the c#?
|
|
|
|
|
yes its in c#.
exactly its this form:
cell8.Controls.Add(new LiteralControl("<A HREF=" + "javascript:window.open('../a.html','_blank','height=200,width=300,menubar=yes');return false;" + " <span style=" + "font-size:9pt;" + "></span>??? ????? ???</A>"));
and thast error is :return statement outside of function
|
|
|
|
|
|
hey any one can help me in making a list box control as muliple columns.
with this code its looking nasty.
UserList.Items.Add(pcon.dr1(0) & "|" & pcon.dr1(1) & "|" & pcon.dr1(2))
|
|
|
|
|
I was told before I think on this forum that you can't put two columns in a listbox control, I think you can join two different listboxes together but you cant use two columns in one
|
|
|
|
|
www.codeproject.com/KB/webforms/MCEnhancedListBoxControl.aspx
hey in above exapmle i want to assign a datareader to get list box items.
and when transfering like in above page can i transfer datavaluefield ? there i can transfer only selected text only. i want to transfer datavaluefield also can any one suggest.
|
|
|
|
|
I thought it was already taken the datavalue field because it is using lstBox.SelectedItem.Value.ToString();
|
|
|
|
|
hi
i am using rich text format in our project
and want to store data in html format
hi every body
but at storing time its taking some spical charcter
<p>hi</p><p><font color="#ff0000"><strong>every boby</strong> </font></p>
if any one know plz help me
thanks
krishna veer singh
|
|
|
|
|
I don’t know your exact requirement. May be you are looking for the Server.HtmlDecode function.
|
|
|
|
|
acctully i wamt to store data in html format
becoz when i retrive this data it will shown in formated way
krishna veer singh
|
|
|
|
|
hai
my code:
Response.Clear();
Response.AppendHeader("Content-Disposition","attachment; filename=" + filename);
Response.AppendHeader("Content-Length", filename.Length.ToString());
Response.ContentType = "text/plain"; //if pdf file "application/pdf"
string strMapPath = Server.MapPath("~FolderName/filename);
FileStream fs = new FileStream(strMapPath, FileMode.Open,FileAccess.Read, FileShare.ReadWrite);
long bytesToGo;
int bytesRead;
Byte[] buffer = new byte[1048576];
bytesToGo = fs.Length;
while (bytesToGo > 0)
{
bytesRead = fs.Read(buffer, 0, 1048576);
Response.OutputStream.Write(buffer, 0, bytesRead);
Response.Flush();
bytesToGo -= bytesRead;
}
fs.Close();
Response.End();
my problem is downloaded file .sql file[size:4mb], which was not fully downloaded, it partially downloaded.i.e the download file doesn't show the full content it shows only 10 or 15 lines.
if anyone known about this,help me
Thanks in Advance
Known is a drop , Unknown is an Ocean
|
|
|
|
|
Can you explain a bit more your problem, what do you mean by
ganeshMohan wrote: my problem is downloaded file .sql file[size:4mb], which was not fully downloaded, it partially downloaded.i.e the download file doesn't show the full content it shows only 10 or 15 lines.
Whats the code above for, is it from the downloaded file?
Where are you downloading the file from?
|
|
|
|
|
Try Response.WriteFile or Response.TransmitFile .
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
A pessimist sees only the dark side of the clouds, and mopes; a philosopher sees both sides, and shrugs; an optimist doesn't see the clouds at all - he's walking on them. --Leonard Louis Levinson
|
|
|
|