|
how to do ?
|
|
|
|
|
All,
I am in a task of creating a custom reporting tool. For that i want to use a tool like create view tool in sql server. In the create view option, we will be able to select tables & fields. Is there any API available to integrate this view generator tool of sql to my desktop application. Or can you give me any clue about any alternate ways to generate sql query dynamic.!!!
Thanks in advance
Sebastian
modified on Friday, June 13, 2008 4:41 AM
|
|
|
|
|
Its easy enough to write yourself and generate a create view statement, but be careful of joins - you may end up with cartesian joins or joins where there are no indexes causing large tables scans. You can soon bring a database to a standstill if your are unaware of the structure and are inexperienced with sql.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Thanks for your reply...here user selects the table & fields. so it changes everytime, i want to generate sql dynamic, as user selects the table & fields
Thanks
Sebastian
|
|
|
|
|
Sebastian T Xavier wrote: i want to generate sql dynamic
So you don't want to create views, just dynamic sql. All you need to do then is create and run a sql select via the SQLCommand and populate either a datareader or dataset etc. Where is the problem?
Also, keep in mind my comments about performance if they are big tables - table scans can be costly.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
I want to update the windows clock via a serial port. I use VB6. How is this done?
|
|
|
|
|
hi,
i have little confusion here..
i'm working on vb.net using VS2008 on windows application..
my problem is i have two or three listbox and i want to using vscrollbar that can control all three listbox..
but i'm only know this..
private sub vscrollbar......handle..
listbox1.selectedindex = vsrollbar.value
it didnt work properly.. error out of range come out..
what can i do to make the scrollbar have same value in listbox..
plz..
|
|
|
|
|
shee_dee86 wrote: it didnt work properly.. error out of range come out..
I guess you didn't bother to make the scrollbar have a range equal to the number of items in the listbox ? Do all three boxes have the same number of items ? I don't think that selecting will scroll anyhow, unless you call the method to make sure an item is visible
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hello,
i have an exe that calls other dlls that has forms in them. the exe is acting like a menu and when a menu item is clicked, it creates an instance of a form in one of my dlls. because the exe and forms are on the main thread, a dialog form locks up the main thread effecting every dll and exe.
is there a good way to handle the issue?
i thought about playing with appdomains attempting to minimize what is effected but I store a bunch of stuff in memory and not sure how to spread that accross domains as well as sync them up.
i tried to mimic the behavior of the "showdiaglog" command by setting up events on the calling form and when it was activated set focus on the "modal" form. works well but when I need wait for a response/answer from the "modal" form, I don't know how to make the calling form wait without locking up the main thread until the "modal" is closed.
any help would be greatly appreciated...
nathan
'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous
'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous
|
|
|
|
|
I am working wiht VB.Net 2005 and I am looking at an Access 2003 database. I can run a Delte query in Access and it works fine. But when I try to run the same query from my program it doesn't delete anything. Can someone tell me what I doing wrong? Thanks so much for your help with this....
Cursor = System.Windows.Forms.Cursors.WaitCursor
'Build SQL to delete this department
Dim TempDepartNum As String = Me.txtDepartNum.Text
Dim Sql As String = String.Empty
'initialize database connection
Dim Connection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Databases\Converted to 2003\C022008.mdb")
'set up SQL command to delete records
'DELETE SHACT.ActAcct, *FROM(SHACT) WHERE (((SHACT.ActAcct) Like '100*'));
Sql = "DELETE * FROM SHACT WHERE (((SHACT.ActAcct) Like '100*'));"
Try
'connect to the database and delete the records
Connection.Open()
Dim Command As New OleDbCommand(Sql, Connection)
Command.ExecuteNonQuery()
MessageBox.Show("Delete Department function completed successfully.", "Delete", MessageBoxButtons.OK)
|
|
|
|
|
Try changing the wild card * in your LIKE statement to a % see if that works.
IE: Like '100*')); changes to Like '100%'));
|
|
|
|
|
Thanks, that is exactly what I needed!
|
|
|
|
|
i have a progam that i want to start and run as long an window is running
i try winservice but is giving me " some services start and stop if the have no work to do for example the performance logs and alerts service
if there any easy way to create this project without using winservice
i mean a window project
|
|
|
|
|
You can put the shortcut in the startup folder, or in the run key in the registry. You can't stop a user stopping your program, it won't restart, but you can make it run initially
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I have a web service (VB.NET) that calls a VB6 dll both of which I have the source code. I'm trying to step through the VB6 dll to debug an issue, but it seems that the web service barfs everytime I debug the VB6 code. Can someone give me a clue on how to debug it?
The VB.NET calls the VB6 dll by late binding using CreateObject().
Thanks.
|
|
|
|
|
You'd need the VB6 IDE and attach it to the process, if it allows that. VB6 and VB.NET are two different languages, so you can't jsut step into it.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hmm.. I was hoping I can just have the VB6 IDE running in debug and pick up the process in there...
|
|
|
|
|
I think that's what I just said. You need to attach to the process in VB6. But, you don't run in debug, you just attach.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hello,
I am reading an rss feed that has an xml tag <link> with a specified http inside it </link>. I am reading this rss feed and writing it into an xml file for my php application to process it.
What I exactly need is writing into an XML file, the content that i get from the link tag when i open it in a browser into the description tag in my xml file.
Eg. <link>http:blablabla</link> if i open the http link in a browser I will get in the browser: more bla bla bla
So what i want is to have the content (more bla bla bla) read from the link tag and be written into my XML file that i am generating.
This is the code for reading the link tag, please advise how can I get out a functional code for my problem.
<pre>
Dim doc As New XmlDocument()
doc.Load("http://www.kse.com.kw/PORTAL/A/RSS/")
Dim nodes As XmlNodeList = doc.SelectNodes("rss/channel/item/link")
For Each node As XmlNode In nodes
Dim http As String = node.InnerText
Dim xml As String = New WebClient().DownloadString(http).ToString
Next
</pre>
|
|
|
|
|
Dear friends,
How to get the sql instance name running on the computer in window form in vb.net
Thanx
Taher
|
|
|
|
|
|
Hi I am Lenu Thomas from INDIA,
There is Deferent Language in India; I am making Library Books Software, I am using “Vb.Net Visual Basic Datagrid” Deferent Language books Name Display in Datagrid. How to Change Font?
I show this Model
No., Book Name, Language, Price, Year, Authors, Publish
1., The Pathos, English, 150, 2000, Colin Warner, OM Publsh
2., thZ]pkvXI Dt, Malayalam, 70 1900, Charles John, OM Publsh
3., n§Ä¡v F´p t, Hindi, 300, 2005, Abd-Ul - %.., ISPCK Publsh
Number 2 Display Malayalam Name, Number 3 Display Hindi Name, How to change in Datagrid Cell
I am using to Deferent Font this is not work. Please help send Sample code from VB.Net Visual Basic
My E-Mail lenuthomas@hotmail.com
|
|
|
|
|
Wtf is a “Vb.Net Visual Basic Datagrid” Deferent Language books Name Display?
"I love deadlines. I like the whooshing sound they make as they fly by." (DNA)
|
|
|
|
|
Hi I am Lenu Thomas from INDIA,
There is Deferent Language in India; I am making Library Books Software, I am using “Vb.Net Visual Basic Datagrid” Deferent Language books Name Display in Datagrid. How to Change Font?
I show this Model
No. Book Name Language Price Year Authors Publish
1. The Pathos English 150 2000 Colin Warner OM Publsh
2. thZ]pkvXI Dt Malayalam 70 1900 Charles John OM Publsh
3. n§Ä¡v F´p t Hindi 300 2005 Abd-Ul - %.. ISPCK
Number 2 Display Malayalam Name, Number 3 Display Hindi Name, How to change in Datagrid Cell
I am using to Deferent Font this is not work. Please help send Sample code from VB.Net Visual Basic
My E-Mail lenuthomas@hotmail.com
|
|
|
|
|
Hi
I have written query like:
dim str as string="true"
Dim cmd As New OleDb.OleDbCommand("Select max(Invoice_No) from Invoice where flag= '" & str & "'", cn)
cn.Open
If IsDBNull(cmd.ExecuteScalar()) = True Then
This statment fires exception:"No value given for one or more required parameters."
when i fire this query directly from access,it runs successfully
what is actual problem,i don't understand
Thanks
monika
|
|
|
|