Click here to Skip to main content
15,913,773 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRefactoring my code now Pin
David Mujica26-Jul-13 8:03
David Mujica26-Jul-13 8:03 
QuestionCreate Dynamic Label with Drag and Drop Function Pin
Val Gerald Dela Cruz24-Jul-13 14:53
Val Gerald Dela Cruz24-Jul-13 14:53 
AnswerRe: Create Dynamic Label with Drag and Drop Function Pin
Dave Kreskowiak24-Jul-13 17:07
mveDave Kreskowiak24-Jul-13 17:07 
QuestionThree column autocomplete Combobox in form and datagridview Pin
Biplob Singha Shee23-Jul-13 19:44
Biplob Singha Shee23-Jul-13 19:44 
AnswerRe: Three column autocomplete Combobox in form and datagridview Pin
Eddy Vluggen31-Jul-13 8:59
professionalEddy Vluggen31-Jul-13 8:59 
GeneralRe: Three column autocomplete Combobox in form and datagridview Pin
Biplob Singha Shee1-Aug-13 21:34
Biplob Singha Shee1-Aug-13 21:34 
QuestionHow to pass parameter in reportviewer which is calling .RDLC report Pin
Member 381516522-Jul-13 18:43
Member 381516522-Jul-13 18:43 
AnswerRe: How to pass parameter in reportviewer which is calling .RDLC report Pin
Mycroft Holmes22-Jul-13 19:12
professionalMycroft Holmes22-Jul-13 19:12 
When using an RDLC we get the data first and pass that to the report viewer along with the report. This is the code from an old winforms sample passing in the datatable and the name of the report file

C#
public partial class frmViewer : Form
{
    public frmViewer(string sReportFile, DataSet dsData)
    {
        InitializeComponent();
        ReportFile = sReportFile;
        ReportDataSet = dsData;
    }

    private string ReportFile { get; set; }
    private DataSet ReportDataSet { get; set; }

    private void Form1_Load(object sender, EventArgs e)
    {
        string sPath = Path.GetDirectoryName(Application.ExecutablePath) + "\\Reports";
        ReportDataSet.Tables[0].TableName = "dtReport";
        ReportDataSet.DataSetName = "ReportData";
        string RepResource = Path.Combine("D:\\Bin10\\Reports\\Reports\\Reports", ReportFile + ".rdlc");

        repViewer.Reset();
        repViewer.LocalReport.ReportEmbeddedResource = RepResource;
        repViewer.LocalReport.DataSources.Add(new ReportDataSource("ReportData", ReportDataSet.Tables[0]));
        //repViewer.LocalReport.DataSources.Add(new ReportDataSource(RepResource, oDS.Tables[0]));

        this.repViewer.RefreshReport();
    }
}


Note that you need to name the table the same as the datasource used when designing the report.

[edit] sorry the sample is in c# but I no longer use VB [/edit]
Never underestimate the power of human stupidity
RAH

GeneralRe: How to pass parameter in reportviewer which is calling .RDLC report Pin
Member 381516523-Jul-13 7:01
Member 381516523-Jul-13 7:01 
AnswerRe: How to pass parameter in reportviewer which is calling .RDLC report Pin
TnTinMn23-Jul-13 7:34
TnTinMn23-Jul-13 7:34 
QuestionVB6 output Access 2000 report to pdf Pin
Member 981947022-Jul-13 9:53
Member 981947022-Jul-13 9:53 
AnswerRe: VB6 output Access 2000 report to pdf Pin
Mycroft Holmes22-Jul-13 12:48
professionalMycroft Holmes22-Jul-13 12:48 
AnswerRe: VB6 output Access 2000 report to pdf Pin
Dave Kreskowiak22-Jul-13 13:55
mveDave Kreskowiak22-Jul-13 13:55 
Questionvbaproject.bin read Pin
JR21220-Jul-13 3:35
JR21220-Jul-13 3:35 
AnswerRe: vbaproject.bin read Pin
Dave Kreskowiak20-Jul-13 7:08
mveDave Kreskowiak20-Jul-13 7:08 
AnswerRe: vbaproject.bin read Pin
TnTinMn20-Jul-13 11:52
TnTinMn20-Jul-13 11:52 
QuestionHow to find mysql table field is empty ? Pin
Biplob Singha Shee19-Jul-13 22:42
Biplob Singha Shee19-Jul-13 22:42 
AnswerRe: How to find mysql table field is empty ? Pin
Biplob Singha Shee20-Jul-13 0:32
Biplob Singha Shee20-Jul-13 0:32 
QuestionERROR When I Show Openfiledialog.ShowDialog() Pin
Sang Nguyen Minh19-Jul-13 8:44
Sang Nguyen Minh19-Jul-13 8:44 
SuggestionRe: ERROR When I Show Openfiledialog.ShowDialog() Pin
Richard Deeming19-Jul-13 8:59
mveRichard Deeming19-Jul-13 8:59 
AnswerRe: ERROR When I Show Openfiledialog.ShowDialog() Pin
Richard MacCutchan19-Jul-13 22:19
mveRichard MacCutchan19-Jul-13 22:19 
AnswerRe: ERROR When I Show Openfiledialog.ShowDialog() Pin
Dave Kreskowiak20-Jul-13 2:57
mveDave Kreskowiak20-Jul-13 2:57 
GeneralRe: ERROR When I Show Openfiledialog.ShowDialog() Pin
Sang Nguyen Minh20-Jul-13 6:21
Sang Nguyen Minh20-Jul-13 6:21 
QuestionEncryption AES256 Trouble.. Pin
markapk18-Jul-13 7:56
markapk18-Jul-13 7:56 
AnswerRe: Encryption AES256 Trouble.. Pin
Kenneth Haugland18-Jul-13 20:09
mvaKenneth Haugland18-Jul-13 20:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.