|
Try to clear the dataset and load the new searched records and after your work completed load all the records.
3. user enters search criteria on search.vb and cliks on the "find" button.
Your task itself has answer for the problem2:
Include the search code in the button(find) click event of search.vb
Hope i answered the question
Ahamed Azeem
software Programmer
|
|
|
|
|
see, if i work on a single page then the searched records get loaded on to the same dataset and i can easily navigate b/w them. to ghat i code on this button, doeso bak to the original dataset, i hav to press a VIEW ALL button.
but the problem is dat wen im using a seperate page to search records and even if i code on the FIND button, then the query that i code on this button, does not get returned to the "form1.vb" page.
This is wat i hav already tried:
1. i declare a string on SEARCH.vb page :
Line1:- Public srch_query As String
2. then i phrase the query according to the parameters defined by the user:
Line2:- srch_query="select * from emp where ......."
3. now to check whether a criteria has been searched, i do the following:
Line3:- Dim Query As String = Search.srch_query
Line4:- cmd=new sqlcommand(query,cn)
followed by rest of the code.
But the problem is that whenever Search.srch_query is called in Line3, it only checks the value from Line1 ie declaration part, and does not even go to the Line2, and so throughout the session, the value of query = " ".
what i mean to ask dat wat should i do so that the value of the query is returned and not the initial declaration where srch_query = " ".
after this, the query string is treated as a blank and the records do not get searched.
|
|
|
|
|
Create an object for the form1 in form 2 and call the same dataset from form2 to load the record onto the same dataset
dim frm as new form1
da.fill(frm.ds)
I have tried and working fine in single dataset
Ahamed Azeem
software Programmer
|
|
|
|
|
We have a Windows Service developed in VB.NET and using .Net 2.0 framework running on Windows server 2003 sp2.
Basically, our service uses serial port objects, some IO logging to text file and of course database calls. We also have a ping logic that pings like about 50 machines in a loop
within a timer. The timer that I use is of System.Timers.Timer type.
This service crashes about once a day. We get the following description for ".Net 2.0 Runtime error,event ID 1000" on the Event Viewer:
Faulting application readerservice.exe, version 1.0.0.0, stamp 49de72c5, faulting module msvcr80.dll, version 8.0.50727.1433, stamp 471eb5ae, debug? 0, fault address 0x000150d8.
We logged the unhandled exception and this is what we found just before the application crashed.
System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading._TimerCallback.PerformTimerCallback(Object state)
Any help on this would be deeply appreciated.
|
|
|
|
|
I forgot to mention that our servive is running on VM Ware on Windows server 2003 sp2.I am not sure that this is of importance but wanted to mention.
|
|
|
|
|
Hi,
looks like your timer's Elapsed handler is throwing an exception which you did not catch.
I would:
- add one overall try-catch catching the Exception and showing all of its information (ToString!)
- run the debug version of it
- shorten the interval to get it sooner and/or more frequently
then watch the line numbers mentioned in the exception.
Most likely cause is something is failing because you don't have the necessary privileges, and/or some service is temporarily out of order and your code isn't coping with that.
|
|
|
|
|
I want to get the field of HTML into the database
i am using a script which checks the active url in the current IE window and out of that i can praise the one i want to my database.
after a search i am able to do the following and got the active url from the internet explorer using the below script
Dim shellWins As SHDocVw.ShellWindows
Dim explorer As SHDocVw.InternetExplorer
shellWins = New SHDocVw.ShellWindows
For Each explorer In shellWins
Debug.Print(explorer.LocationName)
Debug.Print(explorer.LocationURL)
Me.Label1.Text = explorer.LocationName
Me.Label2.Text = explorer.LocationURL
MsgBox(Me.Label1.Text & "-" & Me.Label2.Text)
If Me.Label1.Text = "Services Network" Then
Me.Label1.Text = explorer.LocationName
Me.Label2.Text = explorer.LocationURL
MsgBox(Me.Label1.Text & "-" & Me.Label2.Text)
' Now here i want to extract the url source code and then search for various content in that
just like parsing the HTML
End If
Next
shellWins = Nothing
explorer = Nothing
kindly if any example available for getting content from HTML
|
|
|
|
|
After a more research i am now able to get the html page but the issue is now how to get the element i want to have table element to store in the database.
see the code below
Dim req As System.Net.WebRequest = System.Net.WebRequest.Create(Me.Label2.Text)
Dim resp As System.Net.WebResponse = req.GetResponse()
Dim strm As System.IO.Stream = resp.GetResponseStream()
Dim sr As System.IO.StreamReader = New System.IO.StreamReader(strm)
Me.TextBox1.Text = sr.ReadToEnd()
|
|
|
|
|
I have a MDI form that contains only maximized child forms. I need to size the MDI parent in the way that the client area of the active MDI child has a certain size (imagine that the child form renders a picture, and we don't want to have margin around the picture). What's the best way to calculate the size of the MDI parent based on the desired size of the MDI child? Thanks.
|
|
|
|
|
Problem:
I need write app which will be placed at top of desktop and will lay all time when user works at pc,
other Apps should not repaint my app, user have to see data at my form,
or say it using other words,
other apps shoud forget about location which is used by my app,
so when my app is running and for example notepad.exe is running
and I pressed maximize for notepad,
it should be miximized at height == (Desktop.Height - myApp.Height)
and location of notepad will be set to Point(0, myApp.Height)
I set topmost to true and hide captions\title and other controll button but of course
it does not allow.
So question: how to implement it?
|
|
|
|
|
imho, I found solution:
find here:
http://www.codeproject.com/KB/shell/csdoesshell3.aspx
question is closed,
ps:
just create right google question =)
|
|
|
|
|
Hi all,
i developed one windows application which contains crystal reports.
i want to do some design changes according to the report size or number of records
etc... without changing the exe , it means i don't want to perform changes to the application and create a new exe, iwant to do it for existing exe reports.
i added the crystal reports through add file while deploying and i tried by made changes to reports but it is not effect to the exe while running exe.
plese suggest me or give procedure how to add crystal reports to the exe when deploying and how to make changes to them.
thank you
pavan kumar m
|
|
|
|
|
Please help me! I need a code to display long time(Hours, minutes, seconds) on my Windos Form beside my calendar I set up.
|
|
|
|
|
Please do not post the same question in more than one forum, it is considered rude.
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.”
|
|
|
|
|
Especially so when it already got answered...
|
|
|
|
|
Ok sorry i'm still new to this didn't know I posted anywhere else.
|
|
|
|
|
txmxax25 wrote: didn't know I posted anywhere else
Alzheimer proof (only 12 minutes before the above post).
|
|
|
|
|
Luc Pattyn wrote: Alzheimer proof
That is very mild prognosis[^]
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Wow - you're even more stupid than I thought. Retard.
Christian Graus
Driven to the arms of OSX by Vista.
"I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )
|
|
|
|
|
Oh really? The proof[^] is written every where.
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
hi,
how to get ascii value for f1 to f12 ?
i am using one simple application software.
when ever i pres f1 key, window will show front of application.
how get this one???
please help me
KaNNaN
"Success is When Ur Signature Becomes An Autograph"
foreverkans@gmail.com
|
|
|
|
|
ASCII is a list of printable characters. Function-keys are not printable characters. You can catch the KeyDown event, and ask what key the user pressed;
switch (e.KeyCode)
{
case Keys.F1:
openHelpFile();
break;
case Keys.F3:
searchFiles();
break;
case Keys.F11:
break;
}
Hope this helps
I are troll
|
|
|
|
|
Hi, Try this code.
if ( e.Alt && e.KeyCode == Keys.S)
{//Pressed Alt+S}
else if (e.Alt && e.KeyCode == Keys.A)
{//Pressed Alt+A}
else if (e.Control && e.KeyCode == Keys.Y)
{//Pressed Ctrl+Y}
else if (e.Control && e.KeyCode == Keys.R)
{//Pressed Ctrl+R}
else if (e.Control && e.KeyCode == Keys.E)
{//Pressed Ctrl+E}
Hope this one can help you.
Thanks
|
|
|
|
|
Here:
F1: 112
F2: 113
F3: 114
F4: 115
F5: 116
F6: 117
F7: 118
F8: 119
F9: 120
F10: 121
F11: 122
F12: 123
Standard ASCII mapping ...
|
|
|
|
|
I need to execute code before windows XP starts (in order to copy protected files). Does somebody know how it can be done ?
if not, how can I change the NTLDR (since it is protected) ?
|
|
|
|