|
Could you be so king and take a closer look to This?[^]
it looks very satisfying, but I dont know, how to import my PDF? Trough a OpenFileDialog? And if yes, how do i manage it, to get it into these functions?
Thank you anyway!
|
|
|
|
|
The source you linked could probably work, looks a bit like a quick & dirty solution though.
You would have to create an instance of the pdf2txt class with the filename of the pdf-file as parameter (which you could get through an OpenFileDialog) and then call GetText() on it.
|
|
|
|
|
You should read the documentation for OpenFileDialog ; all it offers is a method for getting the filename from the user. Reading files is a different issue and requires the use of one of the stream classes. I am not sure what that code is supposed to be doing, I suggest you try it and see if it helps you.
|
|
|
|
|
I have Records which are supposed to be assigned Position/Be Ranked e.g
RegNo Marks Position
1 300
3 301
4 403
5 345
My Problem is How to rank/give position according to marks attained such that the results will be displayed as:
RegNo Marks Position
1 300 4
3 301 3
4 403 1
5 345 2
using VB.NET MYSQL
...KINDLY ASSIST
|
|
|
|
|
Please do not repost the same question in multiple forums, and try to use the correct forum in the first place. This is a database question, which I already answered in that forum, nothing to do with the .NET framework.
|
|
|
|
|
I have a datagridview with the columns Totalscore,MARK1,MARK2,MARK3,..MARK10. my problem is how i can check if less than 7 cells in a row are filled with values then update TotalScore as -1 otherwise if 7 or more have values then find the total of the cells.
i had tried with this but could not succeed
Try
For i As Integer = 9 To Me.DataGridView1.Rows.Count - 1
With Me.DataGridView1.Rows(i)
If IsDBNull(.Cells(9).Value()) OrElse .Cells(9).Value() Is Nothing OrElse .Cells(9).Value().ToString().Trim() = "" Then
ttScore = "-1"
avg = "-1"
points = "-1"
pos = "-1"
.Cells(2).Value() = ttScore
.Cells(3).Value() = avg
.Cells(4).Value() = pos
.Cells(5).Value() = points
Else
ttScore = "1"
avg = "1"
points = "1"
pos = "1"
.Cells(2).Value() = ttScore
.Cells(3).Value() = avg
.Cells(4).Value() = pos
.Cells(5).Value() = points
End If
End With
Next
Catch ex As Exception
MsgBox(ex.Message)
End Try
|
|
|
|
|
KipkoechE wrote:
For i As Integer = 9 To Me.DataGridView1.Rows.Count - 1
With Me.DataGridView1.Rows(i)
That means "for row 9 to amount-1". Is it the intention to ignore the first nine rows?
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
yea...it is suppose to ignore the first nine rows
|
|
|
|
|
Are you sure there are more thsn 9 rows in the grid? And why are you storing strings for numbers? And why all those redundant interim variables, why not just:
.Cells(2).Value() = -1
And most importantly, what do you mean by "i had tried with this but could not succeed"; what do you expect to happen, and what does actually happen?
|
|
|
|
|
Am very sure...i have 20 rows
|
|
|
|
|
i changed it to :
Try
For i As Integer = 0 To Me.DataGridView1.Rows.Count - 1
With Me.DataGridView1.Rows(i)
If IsDBNull(.Cells(9).Value()) OrElse .Cells(9).Value() Is Nothing OrElse .Cells(9).Value().ToString().Trim() = "" Then
.Cells(6).Value() = -1
.Cells(7).Value() = -1
.Cells(8).Value() = -1
.Cells(9).Value() = -1
Else
.Cells(6).Value() = 1
.Cells(7).Value() = 1
.Cells(8).Value() = 1
.Cells(9).Value() = 1
End If
End With
Next
Catch ex As Exception
MsgBox(ex.Message)
End Try
and it worked very well
My problem now is adding the rows data...
Thanks for the guidance
-- modified 11-Feb-15 4:21am.
|
|
|
|
|
I have three tables in the school database: students,exams,subjects. my Problem is how i can take the take the subjects records and admission no from students and use them to create a table call marks at the click of a button. Note: the no of records are unpredictable.
Student Table contains fields: admno,name,form
exam contains fields: ExamName
subjects: SubjectName,SubjectID
The Marks table final result should be
admno,name,form,ExamName,subject1,subject2,...subjectn(Based on the no of subjects in the subject table)
. Am using vb.net with mysql. Kindly assist. it has given me headache for weeks
|
|
|
|
|
This question belongs in the Database forum, it is not a .NET issue.
|
|
|
|
|
i have copied it to the database...kindly assist me to answer from there
|
|
|
|
|
<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="frmSMS.aspx.cs" Inherits="frmSMS" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<asp:updatepanel id="UpdatePanel1" runat="server" updatemode="Conditional"
ChildrenAsTriggers="False">
<Triggers>
<asp:AsyncPostBackTrigger ControlID="Button1" EventName="Click" />
</Triggers>
<contenttemplate>
<center>
<div>
<asp:Button ID="Button1" runat="server" Text="Button" onclick="Button1_Click" />
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
</div>
</center>
</contenttemplate>
</asp:updatepanel>
<asp:updateprogress id="UpdateProgress1" runat="server" associatedupdatepanelid="UpdatePanel1" displayafter="2000" dynamiclayout="true">
<progresstemplate>
<center>
<asp:Image ID="Image1" src="~/images/loading.gif" runat="server" />
</center>
</progresstemplate>
</asp:updateprogress>
</asp:Content>
|
|
|
|
|
OK, so what? Did you read the error message? It's telling you exactly what you have to do to fix the problem.
|
|
|
|
|
The control with ID 'UpdatePanel1' requires a ScriptManager on the page. The ScriptManager must appear before any controls that need it.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: The control with ID 'UpdatePanel1' requires a ScriptManager on the page. The ScriptManager must appear before any controls that need it.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[InvalidOperationException: The control with ID 'UpdatePanel1' requires a ScriptManager on the page. The ScriptManager must appear before any controls that need it.]
System.Web.UI.UpdatePanel.get_ScriptManager() +474740
System.Web.UI.UpdatePanel.RegisterPanel() +2515953
System.Web.UI.UpdatePanel.OnInit(EventArgs e) +19
System.Web.UI.Control.InitRecursive(Control namingContainer) +140
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +480
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1
|
|
|
|
|
Ok. That still doesn't change my answer. You very simply need to drop a ScriptManager on the page, just like the error message says.
|
|
|
|
|
Thank you dave kreskowiak.
I use toolkit script manager. plz help
|
|
|
|
|
Are you kidding me? Help with what? All you had to do was drag a ScriptManager from the ToolBox to your form! What's so hard about that?
|
|
|
|
|
when i add scriptmanager following error show. I already user tool kit script manager in master file.
Only one instance of a ScriptManager can be added to the page.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: Only one instance of a ScriptManager can be added to the page.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[InvalidOperationException: Only one instance of a ScriptManager can be added to the page.]
System.Web.UI.ScriptManager.OnInit(EventArgs e) +2515087
AjaxControlToolkit.ToolkitScriptManager.OnInit(EventArgs e) in f:\TeamCity\buildAgent\work\80acd78aa4c25314\Server\AjaxControlToolkit\ToolkitScriptManager\ToolkitScriptManager.cs:195
System.Web.UI.Control.InitRecursive(Control namingContainer) +140
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Control.InitRecursive(Control namingContainer) +311
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +480
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1
|
|
|
|
|
Information like this would have been handy in your first post. Take the script manager off of the page that isn't the Master page.
You NEVER said you were using a Master page and Child pages. This kind of information is CRUCIAL to the problem!
You need a ScriptManager on the Master page and ScriptManagerProxy controls on the Child pages if any of those children are using scripts.
|
|
|
|
|
How To Show Dll code in asp.net thanks in advance
|
|
|
|
|
You'll need to add more detail than that I'm afraid. What DLL code? Where does it reside? Is this decompiled code or source you already own?
|
|
|
|
|