|
What is exactly is your problem? You described what you were doing, but didn't really say what the problem is, thus can't really help you until you give better detail to the problem.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
just give the logic or code for the dynamic connection with crystal report
Nikesh Kr. Yadav
CSS Infotech
Sec- 31
Gurgaon,
Haryana(India)
|
|
|
|
|
Er nikesh yadav wrote: just give the logic or code for the dynamic connection with crystal report
Nope. I don't work like that. The code I develop costs a substantial amount money and I only offer advise, not code.
Here is advice for the dynamic connection, assuming you have a connection string already setup, you can change them at runtime. I don't see any really descriptive problem here.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
sorry i forgot the please but i rally thank ful to you if u can explain some more i already tried your suggestion it doen't work please help me
Nikesh Kr. Yadav
CSS Infotech
Sec- 31
Gurgaon,
Haryana(India)
|
|
|
|
|
Er nikesh yadav wrote: sorry i forgot the please
Don't worry about it, bro. I am just getting tired and cranky
But do look up readings on Crystal Reports, even visit their site, they may have white papers to help you.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
thanks
Nikesh Kr. Yadav
CSS Infotech
Sec- 31
Gurgaon,
Haryana(India)
|
|
|
|
|
I suggest you read up on how to ask questions. I can guarentee you that the advice you've been given, works. So, if you can't work out how to do it, try posting code and explaining what is going wrong, so we can help you to follow the advice you've been given.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
On a kinder note, I recommend you find some good literature on Crystal Reports since it seems you are asking alot of questions about it lately.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Looking at your message history, you post every question you have to at least three forums. Please don't do that, it's rude and annoying. Pick the right forum and ask there.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Christian Graus wrote: it's rude and annoying
I've already scolded a little bit on leckey's behalf
He's sounds like he's demanding just give the logic or code for the dynamic connection with crystal report, well, no real quick and easy answer, and he forgot to say please :->
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
How can I caputre the content in the IE Address bar ofthe current IE Window?
If there is a different way maybe a ie hook? Ref: http://www.codeproject.com/shell/iesaveas.asp[^]
All sugestions are welcome.
My code retrives the handle of the active window but i need to strip information from specific a object within a window. Like the IE Address bar. Here is the code I have.
Declare Function GetForegroundWindow Lib "user32" Alias "GetForegroundWindow" () As Integer
Declare Function GetWindowTextLength Lib "user32.dll" Alias "GetWindowTextLengthA" (ByVal hwnd As Integer) As Integer
Declare Function GetWindowText Lib "user32" Alias "GetWindowTextA" (ByVal hwnd As Integer, ByVal lpString As String, ByVal cch As Integer) As Integer
Declare Function GetWindowThreadProcessId Lib "user32" (ByVal hwnd As Integer, ByRef lpdwProcessId As Integer) As Integer
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
' Get the window's handle.
Dim fg_hwnd As Long = GetForegroundWindow()
Dim pid As Integer = 3528 ' "2940" '
GetWindowThreadProcessId(fg_hwnd, pid)
Debug.WriteLine("HWN= " & fg_hwnd & " " & "PID= " & pid)
End Sub
Thank you in advance
-- modified at 15:44 Thursday 26th July, 2007
|
|
|
|
|
I'm populating the 2 combobox columns with data. The first selection on the first column will affect the 2nd column on the same row, only on the same row. I mean that the combobox collection on the 2nd column is populated with data based on the selection on the combobox of the 1st column. Each row is independent with each other.
Can anyone tell me how to code this all, please? Thank You Very Much.
Ryan
|
|
|
|
|
|
What I want to do is, i have datatable that is populated by MySQL Table. I want to be able to bind the col to specifice text boxes. There is only going to be one row that is going to be use.
Idea i would like to do it that way. if not i can make datagrid and bind that way, i dont know the correct systex to make it work. i was looking on this website and i found an example but i does not work..Im using VB.net 2005 Express or i can do it in VB.net 2003..
I need to know to do this in code.. please
Thank you
Shane
|
|
|
|
|
The only way to do this, is to get your row, and set each textboxes text to be the contents of the columns you want them to be.
What do you mean you found an example, but it doesn't work ? If you posted the code, and what goes wrong, we'd probably be able to help a little more.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
I got it to work. I used a datagrid and hide it and use this code to put into the text put into the text boxes.. this data is only for read only does not need to be use again after the program opens. its only query on speficet piece of data for that day they open the program.
dgview.rows(0).colums(0).value.tostring or something like that..
Thanks for u try to help me..
sorry, i should have post the code that i was talking about...
im very new to ask for help like this on message bords...
Thank you
Shane
|
|
|
|
|
I have two questions regarding updating an Access Database using the Update command for an OleDbDataAdapter.
1. A DataTable that has been filled using the DataAdapter Fill() command is bound to a DataGridView through the DataSource and DataMember commands of the DataGridView. After changing some values in the DataGridView, I use the DataAdapter.Update() command to record the changes in the grid in the Access Database. If I make a change to a cell and then move the cursor to another row, the change is recorded; however, if the cursor is not moved to another row, then changes made to the row in which is selection remains are not reflected in the Access Database after the Update() command. I have tried using the DataGridView commands EndEdit(), RefreshEdit(), and Refresh() and none of those commands cause changes in the most recently selected row to be reflected in the updated Access Database. Any suggestions?
2. A DataTable is filled using the DataAdapter Fill() command. Rows containing data are then added to the DataTable. After adding the rows, the DataTable is bound to a DataGridView through the DataSource and DataMember commands and then the DataAdapter.Update() is used to update the Access Database. This generates an error "Update requires a valid InsertCommand when passed DataRow collection with new rows." I cannot figure out how to use the InsertCommand(). The difficulty is likely because I don't understand how to use the CommandBuilder. Any suggestions?
Rich Feldman
|
|
|
|
|
Do you have an insert query for the InsertCommand?
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
No. I do not know how to construct an insert query. To use the Fill command, I copied the following from a book without much understanding:
da = New OleDb.OleDbDataAdapter("Select * From MyTable", cn)
cb = New OldDb.OleDbCommandBuilder(da)
da.Fill(myDataSet, "myName")
where da, cn, and cb are appropriately defined variables.
The Update Command worked without needing to build any command. Any help on the InsertCommand would be greatly appreciated.
Rich Feldman
|
|
|
|
|
RichFeldman wrote: I copied the following from a book without much understanding
Ah, there is the root of the problem.
Some reading material on the insert command.
INSERT INTO W3Schools[^]
Or
Insert MSDN[^]
With respect, I must disagree. A quick look at middle management in just about any corporation shows that the dodo not only survived, it's reproducing in record numbers. Christopher Duncan
|
|
|
|
|
The SQL Statements are not the problem but the use of the DataAdapter and the CommandBuilder. Can you recommend some reading regarding those?
Rich Feldman
|
|
|
|
|
Do While lcp_objReader.Peek() <> -1
str_lcp_Tmp = lcp_objReader.ReadLine()
str_lcp_data(a) = str_lcp_Tmp.Split(lcp_delimiter, StringSplitOptions.RemoveEmptyEntries)
If str_lcp_data(a).Length > 0 Then
For index As Integer = 0 To str_lcp_data(a).Length - 1
Console.Write(str_lcp_data(a)(index) + "|")
Next
Console.Write(vbCrLf)
a += 1
End If
Loop
i would like to print out the row 120, so i put
Console.Write(str_lcp_data(120)(index) + "|")
After debug, it gave the message "object reference not set to an instance of an object". How come it become like this?
If i want to print the rows after row 120 (from 121 until end of the file), should i initialise a to 120 before do while loop?
|
|
|
|
|
this usualy accurs when you forget the initialize the object (the new keyword)
for example:
<br />
Dim ll As List(Of String)<br />
ll.Add("test")
--> will give you're error
<br />
Dim ll As new List(Of String)<br />
ll.Add("test")
--> will not give the error
so in you're case I think you forgot to initialize the str_lcp_data object
|
|
|
|
|
i got initialise str_lcp_data object
dim str_lcp_data (1000)() as string
|
|
|
|
|
that is not initialized (I think correct me if I'm wrong)
that is declared
to initialize the variable you need to enter data
try this (just to see if this is the problem)
str_lcp_data(120)="test"
and then run and see if you still get the error if not you've found the cause wich is that there was no data to display
if you still get the error then I don't really know what is going on
|
|
|
|