Home All Groups Group Topic Archive Search About

Dataset for crystal report

Author
28 Feb 2005 9:49 AM
Hemang Shah

I have form1 which has the dsDataset  which is instance of
dsDataSetClass.xsd

I have a button called "report", which opens up another form, which has the
Crystal Report Viewer.

The datasource of the report is "current connection" dsDataSetClass

But whenever I run the report, it shows up the "Database Login" screen.

Even if I enter the details it doesn't work.

Firstly 1)  Why isn't it working?
secondly 2)  How can I save that setting ? so that it works smoothly for the
clients.

There isn't much I could find on the net on it.

Thanks

HS
Author
28 Feb 2005 10:33 AM
Kamal Vaghjiani
Hemang

Is the database connection established in Crystal Reports ?
Are you trying to do this via code ?

Example 1 c#
ReportTest rep = new ReportTest ();
rep.SetDatabaseLogon("USERNAME","PASSWORD");

I hope this helps...

Regards

KV


Show quoteHide quote
"Hemang Shah" <hem***@hemang.net> wrote in message
news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>I have form1 which has the dsDataset  which is instance of
>dsDataSetClass.xsd
>
> I have a button called "report", which opens up another form, which has
> the Crystal Report Viewer.
>
> The datasource of the report is "current connection" dsDataSetClass
>
> But whenever I run the report, it shows up the "Database Login" screen.
>
> Even if I enter the details it doesn't work.
>
> Firstly 1)  Why isn't it working?
> secondly 2)  How can I save that setting ? so that it works smoothly for
> the clients.
>
> There isn't much I could find on the net on it.
>
> Thanks
>
> HS
>
Are all your drivers up to date? click for free checkup

Author
28 Feb 2005 10:44 PM
Hemang Shah
Thanks Kamal

I think I have to set the rep.setdatasource(datasetname)

But my dataset is current in the parent form, how do I reference that?

Thanks.


Show quoteHide quote
"Kamal Vaghjiani" <ka***@mortgageuk.com> wrote in message
news:OnQREEYHFHA.2132@TK2MSFTNGP14.phx.gbl...
> Hemang
>
> Is the database connection established in Crystal Reports ?
> Are you trying to do this via code ?
>
> Example 1 c#
> ReportTest rep = new ReportTest ();
> rep.SetDatabaseLogon("USERNAME","PASSWORD");
>
> I hope this helps...
>
> Regards
>
> KV
>
>
> "Hemang Shah" <hem***@hemang.net> wrote in message
> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>I have form1 which has the dsDataset  which is instance of
>>dsDataSetClass.xsd
>>
>> I have a button called "report", which opens up another form, which has
>> the Crystal Report Viewer.
>>
>> The datasource of the report is "current connection" dsDataSetClass
>>
>> But whenever I run the report, it shows up the "Database Login" screen.
>>
>> Even if I enter the details it doesn't work.
>>
>> Firstly 1)  Why isn't it working?
>> secondly 2)  How can I save that setting ? so that it works smoothly for
>> the clients.
>>
>> There isn't much I could find on the net on it.
>>
>> Thanks
>>
>> HS
>>
>
>
Author
28 Feb 2005 4:02 PM
Sahil Malik
How have you generated the various available fields for the report? If you
generated it as a result of a query or stored proc, then you'll probably see
that logon. Use the XSD instead.

- Sahil Malik
http://codebetter.com/blogs/sahil.malik/



Show quoteHide quote
"Hemang Shah" <hem***@hemang.net> wrote in message
news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
> I have form1 which has the dsDataset  which is instance of
> dsDataSetClass.xsd
>
> I have a button called "report", which opens up another form, which has
the
> Crystal Report Viewer.
>
> The datasource of the report is "current connection" dsDataSetClass
>
> But whenever I run the report, it shows up the "Database Login" screen.
>
> Even if I enter the details it doesn't work.
>
> Firstly 1)  Why isn't it working?
> secondly 2)  How can I save that setting ? so that it works smoothly for
the
> clients.
>
> There isn't much I could find on the net on it.
>
> Thanks
>
> HS
>
>
Author
28 Feb 2005 10:45 PM
Hemang Shah
Hello Sahil

I used the xsd..

but then I need to fill in the .setdatasource property right ?

The report expert doesn't do that for you.

but my dataset is in the parent form, how do I access that ?

Thanks


Show quoteHide quote
"Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
> How have you generated the various available fields for the report? If you
> generated it as a result of a query or stored proc, then you'll probably
> see
> that logon. Use the XSD instead.
>
> - Sahil Malik
> http://codebetter.com/blogs/sahil.malik/
>
>
>
> "Hemang Shah" <hem***@hemang.net> wrote in message
> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>> I have form1 which has the dsDataset  which is instance of
>> dsDataSetClass.xsd
>>
>> I have a button called "report", which opens up another form, which has
> the
>> Crystal Report Viewer.
>>
>> The datasource of the report is "current connection" dsDataSetClass
>>
>> But whenever I run the report, it shows up the "Database Login" screen.
>>
>> Even if I enter the details it doesn't work.
>>
>> Firstly 1)  Why isn't it working?
>> secondly 2)  How can I save that setting ? so that it works smoothly for
> the
>> clients.
>>
>> There isn't much I could find on the net on it.
>>
>> Thanks
>>
>> HS
>>
>>
>
>
Author
1 Mar 2005 3:54 AM
Sahil Malik
Hemang, you need to set the datafields per the xsd at "DESIGN TIME" not run
time.
Is that what you did?

- Sahil Malik
http://codebetter.com/blogs/sahil.malik/



Show quoteHide quote
"Hemang Shah" <hem***@hemang.net> wrote in message
news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
> Hello Sahil
>
> I used the xsd..
>
> but then I need to fill in the .setdatasource property right ?
>
> The report expert doesn't do that for you.
>
> but my dataset is in the parent form, how do I access that ?
>
> Thanks
>
>
> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>> How have you generated the various available fields for the report? If
>> you
>> generated it as a result of a query or stored proc, then you'll probably
>> see
>> that logon. Use the XSD instead.
>>
>> - Sahil Malik
>> http://codebetter.com/blogs/sahil.malik/
>>
>>
>>
>> "Hemang Shah" <hem***@hemang.net> wrote in message
>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>> I have form1 which has the dsDataset  which is instance of
>>> dsDataSetClass.xsd
>>>
>>> I have a button called "report", which opens up another form, which has
>> the
>>> Crystal Report Viewer.
>>>
>>> The datasource of the report is "current connection" dsDataSetClass
>>>
>>> But whenever I run the report, it shows up the "Database Login" screen.
>>>
>>> Even if I enter the details it doesn't work.
>>>
>>> Firstly 1)  Why isn't it working?
>>> secondly 2)  How can I save that setting ? so that it works smoothly for
>> the
>>> clients.
>>>
>>> There isn't much I could find on the net on it.
>>>
>>> Thanks
>>>
>>> HS
>>>
>>>
>>
>>
>
>
Author
1 Mar 2005 5:32 AM
news.microsoft.com
Yes Sahil, I set it at design time.

But during runtime, the report needs to see the dataset right ? the dataset
is not running on the form that has the crystal report viewer, the datset is
on the form that is calling another form which has the crystal report viewer
in it.

I can create another dataset and all, in the form that has the crv, but all
data is ther on the parent form, i just want to refer that.

Thanks

HS

Show quoteHide quote
"Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
> Hemang, you need to set the datafields per the xsd at "DESIGN TIME" not
> run time.
> Is that what you did?
>
> - Sahil Malik
> http://codebetter.com/blogs/sahil.malik/
>
>
>
> "Hemang Shah" <hem***@hemang.net> wrote in message
> news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>> Hello Sahil
>>
>> I used the xsd..
>>
>> but then I need to fill in the .setdatasource property right ?
>>
>> The report expert doesn't do that for you.
>>
>> but my dataset is in the parent form, how do I access that ?
>>
>> Thanks
>>
>>
>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>>> How have you generated the various available fields for the report? If
>>> you
>>> generated it as a result of a query or stored proc, then you'll probably
>>> see
>>> that logon. Use the XSD instead.
>>>
>>> - Sahil Malik
>>> http://codebetter.com/blogs/sahil.malik/
>>>
>>>
>>>
>>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>>> I have form1 which has the dsDataset  which is instance of
>>>> dsDataSetClass.xsd
>>>>
>>>> I have a button called "report", which opens up another form, which has
>>> the
>>>> Crystal Report Viewer.
>>>>
>>>> The datasource of the report is "current connection" dsDataSetClass
>>>>
>>>> But whenever I run the report, it shows up the "Database Login" screen.
>>>>
>>>> Even if I enter the details it doesn't work.
>>>>
>>>> Firstly 1)  Why isn't it working?
>>>> secondly 2)  How can I save that setting ? so that it works smoothly
>>>> for
>>> the
>>>> clients.
>>>>
>>>> There isn't much I could find on the net on it.
>>>>
>>>> Thanks
>>>>
>>>> HS
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Author
1 Mar 2005 10:07 PM
Sahil Malik
Hemang,

It doesn't matter where the dataset instance exists, as long as you can get
a reference to it.
Once you do that, just set the report datasource = datasource and databind.
That should be enough.

- Sahil Malik
http://codebetter.com/blogs/sahil.malik/



Show quoteHide quote
"news.microsoft.com" <v-hs***@microsoft.com> wrote in message
news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
> Yes Sahil, I set it at design time.
>
> But during runtime, the report needs to see the dataset right ? the
dataset
> is not running on the form that has the crystal report viewer, the datset
is
> on the form that is calling another form which has the crystal report
viewer
> in it.
>
> I can create another dataset and all, in the form that has the crv, but
all
> data is ther on the parent form, i just want to refer that.
>
> Thanks
>
> HS
>
> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME" not
> > run time.
> > Is that what you did?
> >
> > - Sahil Malik
> > http://codebetter.com/blogs/sahil.malik/
> >
> >
> >
> > "Hemang Shah" <hem***@hemang.net> wrote in message
> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
> >> Hello Sahil
> >>
> >> I used the xsd..
> >>
> >> but then I need to fill in the .setdatasource property right ?
> >>
> >> The report expert doesn't do that for you.
> >>
> >> but my dataset is in the parent form, how do I access that ?
> >>
> >> Thanks
> >>
> >>
> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
> >>> How have you generated the various available fields for the report? If
> >>> you
> >>> generated it as a result of a query or stored proc, then you'll
probably
> >>> see
> >>> that logon. Use the XSD instead.
> >>>
> >>> - Sahil Malik
> >>> http://codebetter.com/blogs/sahil.malik/
> >>>
> >>>
> >>>
> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
> >>>> I have form1 which has the dsDataset  which is instance of
> >>>> dsDataSetClass.xsd
> >>>>
> >>>> I have a button called "report", which opens up another form, which
has
> >>> the
> >>>> Crystal Report Viewer.
> >>>>
> >>>> The datasource of the report is "current connection" dsDataSetClass
> >>>>
> >>>> But whenever I run the report, it shows up the "Database Login"
screen.
> >>>>
> >>>> Even if I enter the details it doesn't work.
> >>>>
> >>>> Firstly 1)  Why isn't it working?
> >>>> secondly 2)  How can I save that setting ? so that it works smoothly
> >>>> for
> >>> the
> >>>> clients.
> >>>>
> >>>> There isn't much I could find on the net on it.
> >>>>
> >>>> Thanks
> >>>>
> >>>> HS
> >>>>
> >>>>
> >>>
> >>>
> >>
> >>
> >
> >
>
>
Author
1 Mar 2005 11:44 PM
Hemang Shah
That is my problem, how can I reference a dataset which is on the parent
form, from the child form ?

It seems I have to define my dataset initially as static ?...  That seems to
mess things up..


Show quoteHide quote
"Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
news:u8bSFsqHFHA.3588@TK2MSFTNGP14.phx.gbl...
> Hemang,
>
> It doesn't matter where the dataset instance exists, as long as you can
> get
> a reference to it.
> Once you do that, just set the report datasource = datasource and
> databind.
> That should be enough.
>
> - Sahil Malik
> http://codebetter.com/blogs/sahil.malik/
>
>
>
> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
> news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
>> Yes Sahil, I set it at design time.
>>
>> But during runtime, the report needs to see the dataset right ? the
> dataset
>> is not running on the form that has the crystal report viewer, the datset
> is
>> on the form that is calling another form which has the crystal report
> viewer
>> in it.
>>
>> I can create another dataset and all, in the form that has the crv, but
> all
>> data is ther on the parent form, i just want to refer that.
>>
>> Thanks
>>
>> HS
>>
>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
>> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME" not
>> > run time.
>> > Is that what you did?
>> >
>> > - Sahil Malik
>> > http://codebetter.com/blogs/sahil.malik/
>> >
>> >
>> >
>> > "Hemang Shah" <hem***@hemang.net> wrote in message
>> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>> >> Hello Sahil
>> >>
>> >> I used the xsd..
>> >>
>> >> but then I need to fill in the .setdatasource property right ?
>> >>
>> >> The report expert doesn't do that for you.
>> >>
>> >> but my dataset is in the parent form, how do I access that ?
>> >>
>> >> Thanks
>> >>
>> >>
>> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>> >>> How have you generated the various available fields for the report?
>> >>> If
>> >>> you
>> >>> generated it as a result of a query or stored proc, then you'll
> probably
>> >>> see
>> >>> that logon. Use the XSD instead.
>> >>>
>> >>> - Sahil Malik
>> >>> http://codebetter.com/blogs/sahil.malik/
>> >>>
>> >>>
>> >>>
>> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
>> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>> >>>> I have form1 which has the dsDataset  which is instance of
>> >>>> dsDataSetClass.xsd
>> >>>>
>> >>>> I have a button called "report", which opens up another form, which
> has
>> >>> the
>> >>>> Crystal Report Viewer.
>> >>>>
>> >>>> The datasource of the report is "current connection" dsDataSetClass
>> >>>>
>> >>>> But whenever I run the report, it shows up the "Database Login"
> screen.
>> >>>>
>> >>>> Even if I enter the details it doesn't work.
>> >>>>
>> >>>> Firstly 1)  Why isn't it working?
>> >>>> secondly 2)  How can I save that setting ? so that it works smoothly
>> >>>> for
>> >>> the
>> >>>> clients.
>> >>>>
>> >>>> There isn't much I could find on the net on it.
>> >>>>
>> >>>> Thanks
>> >>>>
>> >>>> HS
>> >>>>
>> >>>>
>> >>>
>> >>>
>> >>
>> >>
>> >
>> >
>>
>>
>
>
Author
2 Mar 2005 4:38 AM
Sahil Malik
Not necessarily, the two forms exist as instances of the forms. You can
easily create a public property of the parent form. (It's just a class
right?)
Or it could be passed in as a constructor parameter to the child form.

- Sahil Malik
http://codebetter.com/blogs/sahil.malik/


Show quoteHide quote
"Hemang Shah" <hem***@hemang.net> wrote in message
news:nZidnStNpqsmmLjfRVn-ig@rogers.com...
> That is my problem, how can I reference a dataset which is on the parent
> form, from the child form ?
>
> It seems I have to define my dataset initially as static ?...  That seems
> to mess things up..
>
>
> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
> news:u8bSFsqHFHA.3588@TK2MSFTNGP14.phx.gbl...
>> Hemang,
>>
>> It doesn't matter where the dataset instance exists, as long as you can
>> get
>> a reference to it.
>> Once you do that, just set the report datasource = datasource and
>> databind.
>> That should be enough.
>>
>> - Sahil Malik
>> http://codebetter.com/blogs/sahil.malik/
>>
>>
>>
>> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
>> news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
>>> Yes Sahil, I set it at design time.
>>>
>>> But during runtime, the report needs to see the dataset right ? the
>> dataset
>>> is not running on the form that has the crystal report viewer, the
>>> datset
>> is
>>> on the form that is calling another form which has the crystal report
>> viewer
>>> in it.
>>>
>>> I can create another dataset and all, in the form that has the crv, but
>> all
>>> data is ther on the parent form, i just want to refer that.
>>>
>>> Thanks
>>>
>>> HS
>>>
>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
>>> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME"
>>> > not
>>> > run time.
>>> > Is that what you did?
>>> >
>>> > - Sahil Malik
>>> > http://codebetter.com/blogs/sahil.malik/
>>> >
>>> >
>>> >
>>> > "Hemang Shah" <hem***@hemang.net> wrote in message
>>> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>>> >> Hello Sahil
>>> >>
>>> >> I used the xsd..
>>> >>
>>> >> but then I need to fill in the .setdatasource property right ?
>>> >>
>>> >> The report expert doesn't do that for you.
>>> >>
>>> >> but my dataset is in the parent form, how do I access that ?
>>> >>
>>> >> Thanks
>>> >>
>>> >>
>>> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>>> >>> How have you generated the various available fields for the report?
>>> >>> If
>>> >>> you
>>> >>> generated it as a result of a query or stored proc, then you'll
>> probably
>>> >>> see
>>> >>> that logon. Use the XSD instead.
>>> >>>
>>> >>> - Sahil Malik
>>> >>> http://codebetter.com/blogs/sahil.malik/
>>> >>>
>>> >>>
>>> >>>
>>> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>> >>>> I have form1 which has the dsDataset  which is instance of
>>> >>>> dsDataSetClass.xsd
>>> >>>>
>>> >>>> I have a button called "report", which opens up another form, which
>> has
>>> >>> the
>>> >>>> Crystal Report Viewer.
>>> >>>>
>>> >>>> The datasource of the report is "current connection" dsDataSetClass
>>> >>>>
>>> >>>> But whenever I run the report, it shows up the "Database Login"
>> screen.
>>> >>>>
>>> >>>> Even if I enter the details it doesn't work.
>>> >>>>
>>> >>>> Firstly 1)  Why isn't it working?
>>> >>>> secondly 2)  How can I save that setting ? so that it works
>>> >>>> smoothly
>>> >>>> for
>>> >>> the
>>> >>>> clients.
>>> >>>>
>>> >>>> There isn't much I could find on the net on it.
>>> >>>>
>>> >>>> Thanks
>>> >>>>
>>> >>>> HS
>>> >>>>
>>> >>>>
>>> >>>
>>> >>>
>>> >>
>>> >>
>>> >
>>> >
>>>
>>>
>>
>>
>
>
Author
2 Mar 2005 10:27 AM
news.microsoft.com
Would it be too much to ask for examples ? :$


Show quoteHide quote
"Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
news:%23ldOrGuHFHA.2700@TK2MSFTNGP09.phx.gbl...
> Not necessarily, the two forms exist as instances of the forms. You can
> easily create a public property of the parent form. (It's just a class
> right?)
> Or it could be passed in as a constructor parameter to the child form.
>
> - Sahil Malik
> http://codebetter.com/blogs/sahil.malik/
>
>
> "Hemang Shah" <hem***@hemang.net> wrote in message
> news:nZidnStNpqsmmLjfRVn-ig@rogers.com...
>> That is my problem, how can I reference a dataset which is on the parent
>> form, from the child form ?
>>
>> It seems I have to define my dataset initially as static ?...  That seems
>> to mess things up..
>>
>>
>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>> news:u8bSFsqHFHA.3588@TK2MSFTNGP14.phx.gbl...
>>> Hemang,
>>>
>>> It doesn't matter where the dataset instance exists, as long as you can
>>> get
>>> a reference to it.
>>> Once you do that, just set the report datasource = datasource and
>>> databind.
>>> That should be enough.
>>>
>>> - Sahil Malik
>>> http://codebetter.com/blogs/sahil.malik/
>>>
>>>
>>>
>>> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
>>> news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
>>>> Yes Sahil, I set it at design time.
>>>>
>>>> But during runtime, the report needs to see the dataset right ? the
>>> dataset
>>>> is not running on the form that has the crystal report viewer, the
>>>> datset
>>> is
>>>> on the form that is calling another form which has the crystal report
>>> viewer
>>>> in it.
>>>>
>>>> I can create another dataset and all, in the form that has the crv, but
>>> all
>>>> data is ther on the parent form, i just want to refer that.
>>>>
>>>> Thanks
>>>>
>>>> HS
>>>>
>>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
>>>> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME"
>>>> > not
>>>> > run time.
>>>> > Is that what you did?
>>>> >
>>>> > - Sahil Malik
>>>> > http://codebetter.com/blogs/sahil.malik/
>>>> >
>>>> >
>>>> >
>>>> > "Hemang Shah" <hem***@hemang.net> wrote in message
>>>> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>>>> >> Hello Sahil
>>>> >>
>>>> >> I used the xsd..
>>>> >>
>>>> >> but then I need to fill in the .setdatasource property right ?
>>>> >>
>>>> >> The report expert doesn't do that for you.
>>>> >>
>>>> >> but my dataset is in the parent form, how do I access that ?
>>>> >>
>>>> >> Thanks
>>>> >>
>>>> >>
>>>> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>>>> >>> How have you generated the various available fields for the report?
>>>> >>> If
>>>> >>> you
>>>> >>> generated it as a result of a query or stored proc, then you'll
>>> probably
>>>> >>> see
>>>> >>> that logon. Use the XSD instead.
>>>> >>>
>>>> >>> - Sahil Malik
>>>> >>> http://codebetter.com/blogs/sahil.malik/
>>>> >>>
>>>> >>>
>>>> >>>
>>>> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>>> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>>> >>>> I have form1 which has the dsDataset  which is instance of
>>>> >>>> dsDataSetClass.xsd
>>>> >>>>
>>>> >>>> I have a button called "report", which opens up another form,
>>>> >>>> which
>>> has
>>>> >>> the
>>>> >>>> Crystal Report Viewer.
>>>> >>>>
>>>> >>>> The datasource of the report is "current connection"
>>>> >>>> dsDataSetClass
>>>> >>>>
>>>> >>>> But whenever I run the report, it shows up the "Database Login"
>>> screen.
>>>> >>>>
>>>> >>>> Even if I enter the details it doesn't work.
>>>> >>>>
>>>> >>>> Firstly 1)  Why isn't it working?
>>>> >>>> secondly 2)  How can I save that setting ? so that it works
>>>> >>>> smoothly
>>>> >>>> for
>>>> >>> the
>>>> >>>> clients.
>>>> >>>>
>>>> >>>> There isn't much I could find on the net on it.
>>>> >>>>
>>>> >>>> Thanks
>>>> >>>>
>>>> >>>> HS
>>>> >>>>
>>>> >>>>
>>>> >>>
>>>> >>>
>>>> >>
>>>> >>
>>>> >
>>>> >
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Author
2 Mar 2005 2:30 PM
Sahil Malik
No it wouldn't be, but do know that last night I slept at 5, and this
morning I woke up at 8 - been that busy really !! But send me an email
instead because I can't post such big attachments to the newsgroup.

- Sahil Malik
http://codebetter.com/blogs/sahil.malik/


Show quoteHide quote
"news.microsoft.com" <v-hs***@microsoft.com> wrote in message
news:eQVwpJxHFHA.2456@TK2MSFTNGP09.phx.gbl...
> Would it be too much to ask for examples ? :$
>
>
> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
> news:%23ldOrGuHFHA.2700@TK2MSFTNGP09.phx.gbl...
>> Not necessarily, the two forms exist as instances of the forms. You can
>> easily create a public property of the parent form. (It's just a class
>> right?)
>> Or it could be passed in as a constructor parameter to the child form.
>>
>> - Sahil Malik
>> http://codebetter.com/blogs/sahil.malik/
>>
>>
>> "Hemang Shah" <hem***@hemang.net> wrote in message
>> news:nZidnStNpqsmmLjfRVn-ig@rogers.com...
>>> That is my problem, how can I reference a dataset which is on the parent
>>> form, from the child form ?
>>>
>>> It seems I have to define my dataset initially as static ?...  That
>>> seems to mess things up..
>>>
>>>
>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>> news:u8bSFsqHFHA.3588@TK2MSFTNGP14.phx.gbl...
>>>> Hemang,
>>>>
>>>> It doesn't matter where the dataset instance exists, as long as you can
>>>> get
>>>> a reference to it.
>>>> Once you do that, just set the report datasource = datasource and
>>>> databind.
>>>> That should be enough.
>>>>
>>>> - Sahil Malik
>>>> http://codebetter.com/blogs/sahil.malik/
>>>>
>>>>
>>>>
>>>> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
>>>> news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
>>>>> Yes Sahil, I set it at design time.
>>>>>
>>>>> But during runtime, the report needs to see the dataset right ? the
>>>> dataset
>>>>> is not running on the form that has the crystal report viewer, the
>>>>> datset
>>>> is
>>>>> on the form that is calling another form which has the crystal report
>>>> viewer
>>>>> in it.
>>>>>
>>>>> I can create another dataset and all, in the form that has the crv,
>>>>> but
>>>> all
>>>>> data is ther on the parent form, i just want to refer that.
>>>>>
>>>>> Thanks
>>>>>
>>>>> HS
>>>>>
>>>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>>> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
>>>>> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME"
>>>>> > not
>>>>> > run time.
>>>>> > Is that what you did?
>>>>> >
>>>>> > - Sahil Malik
>>>>> > http://codebetter.com/blogs/sahil.malik/
>>>>> >
>>>>> >
>>>>> >
>>>>> > "Hemang Shah" <hem***@hemang.net> wrote in message
>>>>> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>>>>> >> Hello Sahil
>>>>> >>
>>>>> >> I used the xsd..
>>>>> >>
>>>>> >> but then I need to fill in the .setdatasource property right ?
>>>>> >>
>>>>> >> The report expert doesn't do that for you.
>>>>> >>
>>>>> >> but my dataset is in the parent form, how do I access that ?
>>>>> >>
>>>>> >> Thanks
>>>>> >>
>>>>> >>
>>>>> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>>> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>>>>> >>> How have you generated the various available fields for the
>>>>> >>> report? If
>>>>> >>> you
>>>>> >>> generated it as a result of a query or stored proc, then you'll
>>>> probably
>>>>> >>> see
>>>>> >>> that logon. Use the XSD instead.
>>>>> >>>
>>>>> >>> - Sahil Malik
>>>>> >>> http://codebetter.com/blogs/sahil.malik/
>>>>> >>>
>>>>> >>>
>>>>> >>>
>>>>> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>>>> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>>>> >>>> I have form1 which has the dsDataset  which is instance of
>>>>> >>>> dsDataSetClass.xsd
>>>>> >>>>
>>>>> >>>> I have a button called "report", which opens up another form,
>>>>> >>>> which
>>>> has
>>>>> >>> the
>>>>> >>>> Crystal Report Viewer.
>>>>> >>>>
>>>>> >>>> The datasource of the report is "current connection"
>>>>> >>>> dsDataSetClass
>>>>> >>>>
>>>>> >>>> But whenever I run the report, it shows up the "Database Login"
>>>> screen.
>>>>> >>>>
>>>>> >>>> Even if I enter the details it doesn't work.
>>>>> >>>>
>>>>> >>>> Firstly 1)  Why isn't it working?
>>>>> >>>> secondly 2)  How can I save that setting ? so that it works
>>>>> >>>> smoothly
>>>>> >>>> for
>>>>> >>> the
>>>>> >>>> clients.
>>>>> >>>>
>>>>> >>>> There isn't much I could find on the net on it.
>>>>> >>>>
>>>>> >>>> Thanks
>>>>> >>>>
>>>>> >>>> HS
>>>>> >>>>
>>>>> >>>>
>>>>> >>>
>>>>> >>>
>>>>> >>
>>>>> >>
>>>>> >
>>>>> >
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Author
2 Mar 2005 2:31 PM
Sahil Malik
And maybe you could invite me for a chai party after I do send the example?
Maybe maybe? :)


Show quoteHide quote
"news.microsoft.com" <v-hs***@microsoft.com> wrote in message
news:eQVwpJxHFHA.2456@TK2MSFTNGP09.phx.gbl...
> Would it be too much to ask for examples ? :$
>
>
> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
> news:%23ldOrGuHFHA.2700@TK2MSFTNGP09.phx.gbl...
>> Not necessarily, the two forms exist as instances of the forms. You can
>> easily create a public property of the parent form. (It's just a class
>> right?)
>> Or it could be passed in as a constructor parameter to the child form.
>>
>> - Sahil Malik
>> http://codebetter.com/blogs/sahil.malik/
>>
>>
>> "Hemang Shah" <hem***@hemang.net> wrote in message
>> news:nZidnStNpqsmmLjfRVn-ig@rogers.com...
>>> That is my problem, how can I reference a dataset which is on the parent
>>> form, from the child form ?
>>>
>>> It seems I have to define my dataset initially as static ?...  That
>>> seems to mess things up..
>>>
>>>
>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>> news:u8bSFsqHFHA.3588@TK2MSFTNGP14.phx.gbl...
>>>> Hemang,
>>>>
>>>> It doesn't matter where the dataset instance exists, as long as you can
>>>> get
>>>> a reference to it.
>>>> Once you do that, just set the report datasource = datasource and
>>>> databind.
>>>> That should be enough.
>>>>
>>>> - Sahil Malik
>>>> http://codebetter.com/blogs/sahil.malik/
>>>>
>>>>
>>>>
>>>> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
>>>> news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
>>>>> Yes Sahil, I set it at design time.
>>>>>
>>>>> But during runtime, the report needs to see the dataset right ? the
>>>> dataset
>>>>> is not running on the form that has the crystal report viewer, the
>>>>> datset
>>>> is
>>>>> on the form that is calling another form which has the crystal report
>>>> viewer
>>>>> in it.
>>>>>
>>>>> I can create another dataset and all, in the form that has the crv,
>>>>> but
>>>> all
>>>>> data is ther on the parent form, i just want to refer that.
>>>>>
>>>>> Thanks
>>>>>
>>>>> HS
>>>>>
>>>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>>> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
>>>>> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME"
>>>>> > not
>>>>> > run time.
>>>>> > Is that what you did?
>>>>> >
>>>>> > - Sahil Malik
>>>>> > http://codebetter.com/blogs/sahil.malik/
>>>>> >
>>>>> >
>>>>> >
>>>>> > "Hemang Shah" <hem***@hemang.net> wrote in message
>>>>> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>>>>> >> Hello Sahil
>>>>> >>
>>>>> >> I used the xsd..
>>>>> >>
>>>>> >> but then I need to fill in the .setdatasource property right ?
>>>>> >>
>>>>> >> The report expert doesn't do that for you.
>>>>> >>
>>>>> >> but my dataset is in the parent form, how do I access that ?
>>>>> >>
>>>>> >> Thanks
>>>>> >>
>>>>> >>
>>>>> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>>> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>>>>> >>> How have you generated the various available fields for the
>>>>> >>> report? If
>>>>> >>> you
>>>>> >>> generated it as a result of a query or stored proc, then you'll
>>>> probably
>>>>> >>> see
>>>>> >>> that logon. Use the XSD instead.
>>>>> >>>
>>>>> >>> - Sahil Malik
>>>>> >>> http://codebetter.com/blogs/sahil.malik/
>>>>> >>>
>>>>> >>>
>>>>> >>>
>>>>> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>>>> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>>>> >>>> I have form1 which has the dsDataset  which is instance of
>>>>> >>>> dsDataSetClass.xsd
>>>>> >>>>
>>>>> >>>> I have a button called "report", which opens up another form,
>>>>> >>>> which
>>>> has
>>>>> >>> the
>>>>> >>>> Crystal Report Viewer.
>>>>> >>>>
>>>>> >>>> The datasource of the report is "current connection"
>>>>> >>>> dsDataSetClass
>>>>> >>>>
>>>>> >>>> But whenever I run the report, it shows up the "Database Login"
>>>> screen.
>>>>> >>>>
>>>>> >>>> Even if I enter the details it doesn't work.
>>>>> >>>>
>>>>> >>>> Firstly 1)  Why isn't it working?
>>>>> >>>> secondly 2)  How can I save that setting ? so that it works
>>>>> >>>> smoothly
>>>>> >>>> for
>>>>> >>> the
>>>>> >>>> clients.
>>>>> >>>>
>>>>> >>>> There isn't much I could find on the net on it.
>>>>> >>>>
>>>>> >>>> Thanks
>>>>> >>>>
>>>>> >>>> HS
>>>>> >>>>
>>>>> >>>>
>>>>> >>>
>>>>> >>>
>>>>> >>
>>>>> >>
>>>>> >
>>>>> >
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>
Author
3 Mar 2005 1:44 PM
Hemang Shah
would love to :)


Show quoteHide quote
"Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
news:uLpX9h5HFHA.1172@TK2MSFTNGP12.phx.gbl...
> And maybe you could invite me for a chai party after I do send the
> example? Maybe maybe? :)
>
>
> --
>
> - Sahil Malik
> http://codebetter.com/blogs/sahil.malik/
>
>
> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
> news:eQVwpJxHFHA.2456@TK2MSFTNGP09.phx.gbl...
>> Would it be too much to ask for examples ? :$
>>
>>
>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>> news:%23ldOrGuHFHA.2700@TK2MSFTNGP09.phx.gbl...
>>> Not necessarily, the two forms exist as instances of the forms. You can
>>> easily create a public property of the parent form. (It's just a class
>>> right?)
>>> Or it could be passed in as a constructor parameter to the child form.
>>>
>>> - Sahil Malik
>>> http://codebetter.com/blogs/sahil.malik/
>>>
>>>
>>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>> news:nZidnStNpqsmmLjfRVn-ig@rogers.com...
>>>> That is my problem, how can I reference a dataset which is on the
>>>> parent form, from the child form ?
>>>>
>>>> It seems I have to define my dataset initially as static ?...  That
>>>> seems to mess things up..
>>>>
>>>>
>>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>> news:u8bSFsqHFHA.3588@TK2MSFTNGP14.phx.gbl...
>>>>> Hemang,
>>>>>
>>>>> It doesn't matter where the dataset instance exists, as long as you
>>>>> can get
>>>>> a reference to it.
>>>>> Once you do that, just set the report datasource = datasource and
>>>>> databind.
>>>>> That should be enough.
>>>>>
>>>>> - Sahil Malik
>>>>> http://codebetter.com/blogs/sahil.malik/
>>>>>
>>>>>
>>>>>
>>>>> "news.microsoft.com" <v-hs***@microsoft.com> wrote in message
>>>>> news:eVGSWAiHFHA.2476@TK2MSFTNGP12.phx.gbl...
>>>>>> Yes Sahil, I set it at design time.
>>>>>>
>>>>>> But during runtime, the report needs to see the dataset right ? the
>>>>> dataset
>>>>>> is not running on the form that has the crystal report viewer, the
>>>>>> datset
>>>>> is
>>>>>> on the form that is calling another form which has the crystal report
>>>>> viewer
>>>>>> in it.
>>>>>>
>>>>>> I can create another dataset and all, in the form that has the crv,
>>>>>> but
>>>>> all
>>>>>> data is ther on the parent form, i just want to refer that.
>>>>>>
>>>>>> Thanks
>>>>>>
>>>>>> HS
>>>>>>
>>>>>> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>>>> news:OnKzyJhHFHA.2648@TK2MSFTNGP14.phx.gbl...
>>>>>> > Hemang, you need to set the datafields per the xsd at "DESIGN TIME"
>>>>>> > not
>>>>>> > run time.
>>>>>> > Is that what you did?
>>>>>> >
>>>>>> > - Sahil Malik
>>>>>> > http://codebetter.com/blogs/sahil.malik/
>>>>>> >
>>>>>> >
>>>>>> >
>>>>>> > "Hemang Shah" <hem***@hemang.net> wrote in message
>>>>>> > news:FdmdnTw1rNVkA77fRVn-vg@rogers.com...
>>>>>> >> Hello Sahil
>>>>>> >>
>>>>>> >> I used the xsd..
>>>>>> >>
>>>>>> >> but then I need to fill in the .setdatasource property right ?
>>>>>> >>
>>>>>> >> The report expert doesn't do that for you.
>>>>>> >>
>>>>>> >> but my dataset is in the parent form, how do I access that ?
>>>>>> >>
>>>>>> >> Thanks
>>>>>> >>
>>>>>> >>
>>>>>> >> "Sahil Malik" <contactmethrumyblog@nospam.com> wrote in message
>>>>>> >> news:%23meyl7aHFHA.896@TK2MSFTNGP10.phx.gbl...
>>>>>> >>> How have you generated the various available fields for the
>>>>>> >>> report? If
>>>>>> >>> you
>>>>>> >>> generated it as a result of a query or stored proc, then you'll
>>>>> probably
>>>>>> >>> see
>>>>>> >>> that logon. Use the XSD instead.
>>>>>> >>>
>>>>>> >>> - Sahil Malik
>>>>>> >>> http://codebetter.com/blogs/sahil.malik/
>>>>>> >>>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>> "Hemang Shah" <hem***@hemang.net> wrote in message
>>>>>> >>> news:9OWdnQf8mtKJdL_fRVn-sQ@rogers.com...
>>>>>> >>>> I have form1 which has the dsDataset  which is instance of
>>>>>> >>>> dsDataSetClass.xsd
>>>>>> >>>>
>>>>>> >>>> I have a button called "report", which opens up another form,
>>>>>> >>>> which
>>>>> has
>>>>>> >>> the
>>>>>> >>>> Crystal Report Viewer.
>>>>>> >>>>
>>>>>> >>>> The datasource of the report is "current connection"
>>>>>> >>>> dsDataSetClass
>>>>>> >>>>
>>>>>> >>>> But whenever I run the report, it shows up the "Database Login"
>>>>> screen.
>>>>>> >>>>
>>>>>> >>>> Even if I enter the details it doesn't work.
>>>>>> >>>>
>>>>>> >>>> Firstly 1)  Why isn't it working?
>>>>>> >>>> secondly 2)  How can I save that setting ? so that it works
>>>>>> >>>> smoothly
>>>>>> >>>> for
>>>>>> >>> the
>>>>>> >>>> clients.
>>>>>> >>>>
>>>>>> >>>> There isn't much I could find on the net on it.
>>>>>> >>>>
>>>>>> >>>> Thanks
>>>>>> >>>>
>>>>>> >>>> HS
>>>>>> >>>>
>>>>>> >>>>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>
>>>>>> >>
>>>>>> >
>>>>>> >
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>

Bookmark and Share